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

Side by Side Diff: src/compiler/change-lowering.cc

Issue 899803003: Removed most of the bogus CompilationInfo constructor calls. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 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 unified diff | Download patch
« no previous file with comments | « src/compiler/change-lowering.h ('k') | src/compiler/js-context-specialization.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/compiler/change-lowering.h" 5 #include "src/compiler/change-lowering.h"
6 6
7 #include "src/code-factory.h" 7 #include "src/code-factory.h"
8 #include "src/compiler/diamond.h" 8 #include "src/compiler/diamond.h"
9 #include "src/compiler/js-graph.h" 9 #include "src/compiler/js-graph.h"
10 #include "src/compiler/linkage.h" 10 #include "src/compiler/linkage.h"
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 const int smi_shift_size = machine()->Is32() ? SmiTagging<4>::SmiShiftSize() 66 const int smi_shift_size = machine()->Is32() ? SmiTagging<4>::SmiShiftSize()
67 : SmiTagging<8>::SmiShiftSize(); 67 : SmiTagging<8>::SmiShiftSize();
68 return jsgraph()->IntPtrConstant(smi_shift_size + kSmiTagSize); 68 return jsgraph()->IntPtrConstant(smi_shift_size + kSmiTagSize);
69 } 69 }
70 70
71 71
72 Node* ChangeLowering::AllocateHeapNumberWithValue(Node* value, Node* control) { 72 Node* ChangeLowering::AllocateHeapNumberWithValue(Node* value, Node* control) {
73 // The AllocateHeapNumberStub does not use the context, so we can safely pass 73 // The AllocateHeapNumberStub does not use the context, so we can safely pass
74 // in Smi zero here. 74 // in Smi zero here.
75 Callable callable = CodeFactory::AllocateHeapNumber(isolate()); 75 Callable callable = CodeFactory::AllocateHeapNumber(isolate());
76 CallDescriptor* descriptor = linkage()->GetStubCallDescriptor( 76 CallDescriptor* descriptor = Linkage::GetStubCallDescriptor(
77 callable.descriptor(), 0, CallDescriptor::kNoFlags); 77 isolate(), jsgraph()->zone(), callable.descriptor(), 0,
78 CallDescriptor::kNoFlags);
78 Node* target = jsgraph()->HeapConstant(callable.code()); 79 Node* target = jsgraph()->HeapConstant(callable.code());
79 Node* context = jsgraph()->NoContextConstant(); 80 Node* context = jsgraph()->NoContextConstant();
80 Node* effect = graph()->NewNode(common()->ValueEffect(1), value); 81 Node* effect = graph()->NewNode(common()->ValueEffect(1), value);
81 Node* heap_number = graph()->NewNode(common()->Call(descriptor), target, 82 Node* heap_number = graph()->NewNode(common()->Call(descriptor), target,
82 context, effect, control); 83 context, effect, control);
83 Node* store = graph()->NewNode( 84 Node* store = graph()->NewNode(
84 machine()->Store(StoreRepresentation(kMachFloat64, kNoWriteBarrier)), 85 machine()->Store(StoreRepresentation(kMachFloat64, kNoWriteBarrier)),
85 heap_number, HeapNumberValueIndexConstant(), value, heap_number, control); 86 heap_number, HeapNumberValueIndexConstant(), value, heap_number, control);
86 return graph()->NewNode(common()->Finish(1), heap_number, store); 87 return graph()->NewNode(common()->Finish(1), heap_number, store);
87 } 88 }
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after
280 } 281 }
281 282
282 283
283 MachineOperatorBuilder* ChangeLowering::machine() const { 284 MachineOperatorBuilder* ChangeLowering::machine() const {
284 return jsgraph()->machine(); 285 return jsgraph()->machine();
285 } 286 }
286 287
287 } // namespace compiler 288 } // namespace compiler
288 } // namespace internal 289 } // namespace internal
289 } // namespace v8 290 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/change-lowering.h ('k') | src/compiler/js-context-specialization.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698