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

Unified Diff: runtime/vm/flow_graph_compiler_arm64.cc

Issue 2748063003: Reland "VM: Simplify lowering of is-tests."" (Closed)
Patch Set: Created 3 years, 9 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 | « runtime/vm/flow_graph_compiler_arm.cc ('k') | runtime/vm/flow_graph_compiler_ia32.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/flow_graph_compiler_arm64.cc
diff --git a/runtime/vm/flow_graph_compiler_arm64.cc b/runtime/vm/flow_graph_compiler_arm64.cc
index d93adebc54470fd641b231203f3ec03be03981cb..9719aaa42753874459c7850e8c25714b1a44673c 100644
--- a/runtime/vm/flow_graph_compiler_arm64.cc
+++ b/runtime/vm/flow_graph_compiler_arm64.cc
@@ -549,7 +549,6 @@ RawSubtypeTestCache* FlowGraphCompiler::GenerateInlineInstanceof(
void FlowGraphCompiler::GenerateInstanceOf(TokenPosition token_pos,
intptr_t deopt_id,
const AbstractType& type,
- bool negate_result,
LocationSummary* locs) {
ASSERT(type.IsFinalized() && !type.IsMalformed() && !type.IsMalbounded());
ASSERT(!type.IsObjectType() && !type.IsDynamicType());
@@ -593,23 +592,15 @@ void FlowGraphCompiler::GenerateInstanceOf(TokenPosition token_pos,
// Pop the parameters supplied to the runtime entry. The result of the
// instanceof runtime call will be left as the result of the operation.
__ Drop(4);
- if (negate_result) {
- __ Pop(R1);
- __ LoadObject(R0, Bool::True());
- __ CompareRegisters(R1, R0);
- __ b(&done, NE);
- __ LoadObject(R0, Bool::False());
- } else {
- __ Pop(R0);
- }
+ __ Pop(R0);
__ b(&done);
}
__ Bind(&is_not_instance);
- __ LoadObject(R0, Bool::Get(negate_result));
+ __ LoadObject(R0, Bool::Get(false));
__ b(&done);
__ Bind(&is_instance);
- __ LoadObject(R0, Bool::Get(!negate_result));
+ __ LoadObject(R0, Bool::Get(true));
__ Bind(&done);
// Remove instantiator type arguments (R1).
__ Drop(1);
« no previous file with comments | « runtime/vm/flow_graph_compiler_arm.cc ('k') | runtime/vm/flow_graph_compiler_ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698