Chromium Code Reviews| Index: src/compiler/js-generic-lowering.cc |
| diff --git a/src/compiler/js-generic-lowering.cc b/src/compiler/js-generic-lowering.cc |
| index e3e4cddd8a3697723d31b376527f2b876153ca56..48f5da6d5713c0615888114a443fd63f61f2cfc4 100644 |
| --- a/src/compiler/js-generic-lowering.cc |
| +++ b/src/compiler/js-generic-lowering.cc |
| @@ -338,10 +338,10 @@ void JSGenericLowering::LowerJSLoadGlobal(Node* node) { |
| if (p.slot_index() >= 0) { |
| Callable callable = CodeFactory::LoadGlobalViaContext(isolate(), 0); |
| Node* script_context = node->InputAt(0); |
| - node->ReplaceInput(0, jsgraph()->SmiConstant(0)); |
| - node->ReplaceInput(1, jsgraph()->SmiConstant(p.slot_index())); |
| - node->ReplaceInput(2, jsgraph()->HeapConstant(p.name())); |
| - node->ReplaceInput(3, script_context); // Replace old context. |
| + node->ReplaceInput(0, jsgraph()->Int32Constant(p.slot_index())); |
| + node->ReplaceInput(1, jsgraph()->HeapConstant(p.name())); |
| + node->ReplaceInput(2, script_context); // Replace old context. |
|
Igor Sheludko
2015/07/18 20:52:43
// Set new context ...
Benedikt Meurer
2015/07/24 05:18:29
Done.
|
| + node->RemoveInput(3); |
|
Igor Sheludko
2015/07/18 20:52:43
// ... instead of old one.
Benedikt Meurer
2015/07/24 05:18:29
Done.
|
| ReplaceWithStubCall(node, callable, flags); |
| } else { |
| @@ -397,11 +397,11 @@ void JSGenericLowering::LowerJSStoreGlobal(Node* node) { |
| CodeFactory::StoreGlobalViaContext(isolate(), 0, p.language_mode()); |
| Node* script_context = node->InputAt(0); |
| Node* value = node->InputAt(2); |
| - node->ReplaceInput(0, jsgraph()->SmiConstant(0)); |
| - node->ReplaceInput(1, jsgraph()->SmiConstant(p.slot_index())); |
| - node->ReplaceInput(2, jsgraph()->HeapConstant(p.name())); |
| - node->ReplaceInput(3, value); |
| - node->ReplaceInput(4, script_context); // Replace old context. |
| + node->ReplaceInput(0, jsgraph()->Int32Constant(p.slot_index())); |
| + node->ReplaceInput(1, jsgraph()->HeapConstant(p.name())); |
| + node->ReplaceInput(2, value); |
| + node->ReplaceInput(3, script_context); // Replace old context. |
|
Igor Sheludko
2015/07/18 20:52:43
// Set new context ...
Benedikt Meurer
2015/07/24 05:18:29
Done.
|
| + node->RemoveInput(4); |
|
Igor Sheludko
2015/07/18 20:52:43
// ... instead of old one.
Benedikt Meurer
2015/07/24 05:18:29
Done.
|
| ReplaceWithStubCall(node, callable, flags); |
| } else { |