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

Unified Diff: src/compiler/js-generic-lowering.cc

Issue 1295433002: [runtime] Remove useless IN builtin. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: REBASE again. Remove unused ReplaceWithBuiltinCall. Created 5 years, 3 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/js-generic-lowering.h ('k') | src/compiler/js-intrinsic-lowering.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/js-generic-lowering.cc
diff --git a/src/compiler/js-generic-lowering.cc b/src/compiler/js-generic-lowering.cc
index d51ee9d1bdee781d6e43e1ba48cf6cc830f436f9..2a9e6daface417016d17d2c13d727e411dc57ed3 100644
--- a/src/compiler/js-generic-lowering.cc
+++ b/src/compiler/js-generic-lowering.cc
@@ -223,38 +223,6 @@ void JSGenericLowering::ReplaceWithStubCall(Node* node, Callable callable,
}
-void JSGenericLowering::ReplaceWithBuiltinCall(Node* node, int context_index,
- int nargs) {
- Node* context_input = NodeProperties::GetContextInput(node);
- Node* effect_input = NodeProperties::GetEffectInput(node);
-
- CallDescriptor::Flags flags = AdjustFrameStatesForCall(node);
- Operator::Properties properties = node->op()->properties();
- Callable callable =
- CodeFactory::CallFunction(isolate(), nargs - 1, NO_CALL_FUNCTION_FLAGS);
- CallDescriptor* desc = Linkage::GetStubCallDescriptor(
- isolate(), zone(), callable.descriptor(), nargs, flags, properties);
- Node* global_object =
- graph()->NewNode(machine()->Load(kMachAnyTagged), context_input,
- jsgraph()->IntPtrConstant(
- Context::SlotOffset(Context::GLOBAL_OBJECT_INDEX)),
- effect_input, graph()->start());
- Node* native_context =
- graph()->NewNode(machine()->Load(kMachAnyTagged), global_object,
- jsgraph()->IntPtrConstant(
- GlobalObject::kNativeContextOffset - kHeapObjectTag),
- effect_input, graph()->start());
- Node* function = graph()->NewNode(
- machine()->Load(kMachAnyTagged), native_context,
- jsgraph()->IntPtrConstant(Context::SlotOffset(context_index)),
- effect_input, graph()->start());
- Node* stub_code = jsgraph()->HeapConstant(callable.code());
- node->InsertInput(zone(), 0, stub_code);
- node->InsertInput(zone(), 1, function);
- node->set_op(common()->Call(desc));
-}
-
-
void JSGenericLowering::ReplaceWithRuntimeCall(Node* node,
Runtime::FunctionId f,
int nargs_override) {
@@ -447,7 +415,7 @@ void JSGenericLowering::LowerJSDeleteProperty(Node* node) {
void JSGenericLowering::LowerJSHasProperty(Node* node) {
- ReplaceWithBuiltinCall(node, Context::IN_BUILTIN_INDEX, 2);
+ ReplaceWithRuntimeCall(node, Runtime::kHasProperty);
}
« no previous file with comments | « src/compiler/js-generic-lowering.h ('k') | src/compiler/js-intrinsic-lowering.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698