Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(104)

Unified Diff: src/compiler/node.cc

Issue 2620293004: [turbofan] Relax limitation for using BaseWithIndexAndDisplacement for load/stores (Closed)
Patch Set: Avoid changing simple addressing to complex addressing when the address has multiple uses Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/compiler/node.h ('k') | src/compiler/node-matchers.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/node.cc
diff --git a/src/compiler/node.cc b/src/compiler/node.cc
index 758be07d40d6529b6316b1ea31f1a28b4e9b9559..05c1d9e1eabc15a0f243af5ddf1b890e6f5070e1 100644
--- a/src/compiler/node.cc
+++ b/src/compiler/node.cc
@@ -296,6 +296,18 @@ bool Node::OwnedBy(Node const* owner1, Node const* owner2) const {
return mask == 3;
}
+bool Node::OwnedByAddressingOperand() const {
+ for (Use* use = first_use_; use; use = use->next) {
+ Node* from = use->from();
+ if (from->opcode() != IrOpcode::kLoad &&
+ from->opcode() != IrOpcode::kStore &&
danno 2017/02/21 16:11:01 Careful here, don't you have to make sure that the
shiyu.zhang 2017/02/23 01:20:48 OwnedByAddressingOperand is only used by left oper
danno 2017/02/23 08:49:34 Well, this builds in a pretty explicit and fragile
+ from->opcode() != IrOpcode::kInt32Add &&
+ from->opcode() != IrOpcode::kInt64Add) {
+ return false;
+ }
+ }
+ return true;
+}
void Node::Print() const {
OFStream os(stdout);
« no previous file with comments | « src/compiler/node.h ('k') | src/compiler/node-matchers.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698