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

Unified Diff: src/code-stub-assembler.cc

Issue 2705163005: [csa] Add Unreachable() and use it after throw sites (Closed)
Patch Set: Rebase 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/builtins/builtins-typedarray.cc ('k') | src/compiler/code-assembler.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/code-stub-assembler.cc
diff --git a/src/code-stub-assembler.cc b/src/code-stub-assembler.cc
index de8669ba3837cd006a01749ecb6fcef13f8ee624..9e45a6daddc76fd5681f963f5dad7ebf8b69f6b7 100644
--- a/src/code-stub-assembler.cc
+++ b/src/code-stub-assembler.cc
@@ -2694,7 +2694,7 @@ Node* CodeStubAssembler::ToThisString(Node* context, Node* value,
CallRuntime(Runtime::kThrowCalledOnNullOrUndefined, context,
HeapConstant(factory()->NewStringFromAsciiChecked(
method_name, TENURED)));
- Goto(&if_valueisstring); // Never reached.
+ Unreachable();
}
}
}
@@ -2793,7 +2793,7 @@ Node* CodeStubAssembler::ToThisValue(Node* context, Node* value,
CallRuntime(Runtime::kThrowNotGeneric, context,
HeapConstant(factory()->NewStringFromAsciiChecked(method_name,
TENURED)));
- Goto(&done_loop); // Never reached.
+ Unreachable();
}
Bind(&done_loop);
@@ -2821,8 +2821,7 @@ Node* CodeStubAssembler::ThrowIfNotInstanceType(Node* context, Node* value,
Runtime::kThrowIncompatibleMethodReceiver, context,
HeapConstant(factory()->NewStringFromAsciiChecked(method_name, TENURED)),
value);
- var_value_map.Bind(UndefinedConstant());
- Goto(&out); // Never reached.
+ Unreachable();
Bind(&out);
return var_value_map.value();
@@ -7809,9 +7808,9 @@ Node* CodeStubAssembler::GetSuperConstructor(Node* active_function,
Bind(&is_not_constructor);
{
- result.Bind(CallRuntime(Runtime::kThrowNotSuperConstructor, context,
- prototype, active_function));
- Goto(&out);
+ CallRuntime(Runtime::kThrowNotSuperConstructor, context, prototype,
+ active_function);
+ Unreachable();
}
Bind(&out);
@@ -7880,18 +7879,14 @@ Node* CodeStubAssembler::InstanceOf(Node* object, Node* callable,
Bind(&if_notcallable);
{
- Node* result =
- CallRuntime(Runtime::kThrowNonCallableInInstanceOfCheck, context);
- var_result.Bind(result);
- Goto(&return_result);
+ CallRuntime(Runtime::kThrowNonCallableInInstanceOfCheck, context);
+ Unreachable();
}
Bind(&if_notreceiver);
{
- Node* result =
- CallRuntime(Runtime::kThrowNonObjectInInstanceOfCheck, context);
- var_result.Bind(result);
- Goto(&return_result);
+ CallRuntime(Runtime::kThrowNonObjectInInstanceOfCheck, context);
+ Unreachable();
}
Bind(&return_true);
« no previous file with comments | « src/builtins/builtins-typedarray.cc ('k') | src/compiler/code-assembler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698