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

Unified Diff: src/interpreter/interpreter-assembler.cc

Issue 2426923002: [stubs] Removes the BranchIf.*() methods from CodeAssembler, changes their uses to Branch(). (Closed)
Patch Set: Created 4 years, 2 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/interpreter/interpreter.cc ('k') | test/cctest/test-code-stub-assembler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/interpreter/interpreter-assembler.cc
diff --git a/src/interpreter/interpreter-assembler.cc b/src/interpreter/interpreter-assembler.cc
index b945b91379afa3867e11acd5b7468ebf5df303de..7be19e1b9cc1983b82122b24ed0de6571682219b 100644
--- a/src/interpreter/interpreter-assembler.cc
+++ b/src/interpreter/interpreter-assembler.cc
@@ -97,7 +97,7 @@ Node* InterpreterAssembler::GetContextAtDepth(Node* context, Node* depth) {
Label context_search(this, 2, context_search_loop_variables);
// Fast path if the depth is 0.
- BranchIfWord32Equal(depth, Int32Constant(0), &context_found, &context_search);
+ Branch(Word32Equal(depth, Int32Constant(0)), &context_found, &context_search);
// Loop until the depth is 0.
Bind(&context_search);
@@ -106,8 +106,8 @@ Node* InterpreterAssembler::GetContextAtDepth(Node* context, Node* depth) {
cur_context.Bind(
LoadContextSlot(cur_context.value(), Context::PREVIOUS_INDEX));
- BranchIfWord32Equal(cur_depth.value(), Int32Constant(0), &context_found,
- &context_search);
+ Branch(Word32Equal(cur_depth.value(), Int32Constant(0)), &context_found,
+ &context_search);
}
Bind(&context_found);
@@ -579,7 +579,7 @@ Node* InterpreterAssembler::CallJSWithFeedback(Node* function, Node* context,
Node* feedback_element = LoadFixedArrayElement(type_feedback_vector, slot_id);
Node* feedback_value = LoadWeakCellValue(feedback_element);
Node* is_monomorphic = WordEqual(function, feedback_value);
- BranchIf(is_monomorphic, &handle_monomorphic, &extra_checks);
+ Branch(is_monomorphic, &handle_monomorphic, &extra_checks);
Bind(&handle_monomorphic);
{
@@ -610,7 +610,7 @@ Node* InterpreterAssembler::CallJSWithFeedback(Node* function, Node* context,
Node* is_megamorphic = WordEqual(
feedback_element,
HeapConstant(TypeFeedbackVector::MegamorphicSentinel(isolate())));
- BranchIf(is_megamorphic, &call, &check_allocation_site);
+ Branch(is_megamorphic, &call, &check_allocation_site);
Bind(&check_allocation_site);
{
@@ -781,7 +781,7 @@ Node* InterpreterAssembler::CallConstruct(Node* constructor, Node* context,
Node* instance_type = LoadInstanceType(constructor);
Node* is_js_function =
WordEqual(instance_type, Int32Constant(JS_FUNCTION_TYPE));
- BranchIf(is_js_function, &js_function, &call_construct);
+ Branch(is_js_function, &js_function, &call_construct);
Bind(&js_function);
{
@@ -796,7 +796,7 @@ Node* InterpreterAssembler::CallConstruct(Node* constructor, Node* context,
LoadFixedArrayElement(type_feedback_vector, slot_id);
Node* feedback_value = LoadWeakCellValue(feedback_element);
Node* is_monomorphic = WordEqual(constructor, feedback_value);
- BranchIf(is_monomorphic, &call_construct_function, &extra_checks);
+ Branch(is_monomorphic, &call_construct_function, &extra_checks);
Bind(&extra_checks);
{
@@ -819,7 +819,7 @@ Node* InterpreterAssembler::CallConstruct(Node* constructor, Node* context,
// monomorphic.
Comment("check if weak cell is cleared");
Node* is_smi = TaggedIsSmi(feedback_value);
- BranchIf(is_smi, &initialize, &mark_megamorphic);
+ Branch(is_smi, &initialize, &mark_megamorphic);
}
Bind(&check_allocation_site);
@@ -835,8 +835,8 @@ Node* InterpreterAssembler::CallConstruct(Node* constructor, Node* context,
LoadFixedArrayElement(LoadNativeContext(context),
Int32Constant(Context::ARRAY_FUNCTION_INDEX));
Node* is_array_function = WordEqual(context_slot, constructor);
- BranchIf(is_array_function, &set_alloc_feedback_and_call,
- &mark_megamorphic);
+ Branch(is_array_function, &set_alloc_feedback_and_call,
+ &mark_megamorphic);
}
Bind(&set_alloc_feedback_and_call);
@@ -851,7 +851,7 @@ Node* InterpreterAssembler::CallConstruct(Node* constructor, Node* context,
Comment("check if uninitialized");
Node* is_uninitialized = WordEqual(
feedback_element, LoadRoot(Heap::kuninitialized_symbolRootIndex));
- BranchIf(is_uninitialized, &initialize, &mark_megamorphic);
+ Branch(is_uninitialized, &initialize, &mark_megamorphic);
}
Bind(&initialize);
@@ -863,7 +863,7 @@ Node* InterpreterAssembler::CallConstruct(Node* constructor, Node* context,
LoadFixedArrayElement(LoadNativeContext(context),
Int32Constant(Context::ARRAY_FUNCTION_INDEX));
Node* is_array_function = WordEqual(context_slot, constructor);
- BranchIf(is_array_function, &create_allocation_site, &create_weak_cell);
+ Branch(is_array_function, &create_allocation_site, &create_weak_cell);
Bind(&create_allocation_site);
{
@@ -1007,7 +1007,7 @@ Node* InterpreterAssembler::Jump(Node* delta) {
void InterpreterAssembler::JumpConditional(Node* condition, Node* delta) {
Label match(this), no_match(this);
- BranchIf(condition, &match, &no_match);
+ Branch(condition, &match, &no_match);
Bind(&match);
Jump(delta);
Bind(&no_match);
@@ -1040,7 +1040,7 @@ Node* InterpreterAssembler::StarDispatchLookahead(Node* target_bytecode) {
Node* star_bytecode = IntPtrConstant(static_cast<int>(Bytecode::kStar));
Node* is_star = WordEqual(target_bytecode, star_bytecode);
- BranchIf(is_star, &do_inline_star, &done);
+ Branch(is_star, &do_inline_star, &done);
Bind(&do_inline_star);
{
@@ -1241,7 +1241,7 @@ void InterpreterAssembler::Abort(BailoutReason bailout_reason) {
void InterpreterAssembler::AbortIfWordNotEqual(Node* lhs, Node* rhs,
BailoutReason bailout_reason) {
Label ok(this), abort(this, Label::kDeferred);
- BranchIfWordEqual(lhs, rhs, &ok, &abort);
+ Branch(WordEqual(lhs, rhs), &ok, &abort);
Bind(&abort);
Abort(bailout_reason);
@@ -1271,7 +1271,7 @@ void InterpreterAssembler::TraceBytecodeDispatch(Node* target_bytecode) {
Node* counter_reached_max = WordEqual(
old_counter, IntPtrConstant(std::numeric_limits<uintptr_t>::max()));
- BranchIf(counter_reached_max, &counter_saturated, &counter_ok);
+ Branch(counter_reached_max, &counter_saturated, &counter_ok);
Bind(&counter_ok);
{
« no previous file with comments | « src/interpreter/interpreter.cc ('k') | test/cctest/test-code-stub-assembler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698