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

Side by Side Diff: src/compiler/js-graph.cc

Issue 2259883002: [turbofan] Inline calls to CPP builtins (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@builtin-descriptors
Patch Set: Address comments Created 4 years, 4 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/js-graph.h ('k') | src/compiler/js-typed-lowering.cc » ('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/code-stubs.h" 5 #include "src/code-stubs.h"
6 #include "src/compiler/js-graph.h" 6 #include "src/compiler/js-graph.h"
7 #include "src/compiler/node-properties.h" 7 #include "src/compiler/node-properties.h"
8 #include "src/compiler/typer.h" 8 #include "src/compiler/typer.h"
9 9
10 namespace v8 { 10 namespace v8 {
(...skipping 11 matching lines...) Expand all
22 Node* JSGraph::AllocateInOldSpaceStubConstant() { 22 Node* JSGraph::AllocateInOldSpaceStubConstant() {
23 return CACHED(kAllocateInOldSpaceStubConstant, 23 return CACHED(kAllocateInOldSpaceStubConstant,
24 HeapConstant(isolate()->builtins()->AllocateInOldSpace())); 24 HeapConstant(isolate()->builtins()->AllocateInOldSpace()));
25 } 25 }
26 26
27 Node* JSGraph::ToNumberBuiltinConstant() { 27 Node* JSGraph::ToNumberBuiltinConstant() {
28 return CACHED(kToNumberBuiltinConstant, 28 return CACHED(kToNumberBuiltinConstant,
29 HeapConstant(isolate()->builtins()->ToNumber())); 29 HeapConstant(isolate()->builtins()->ToNumber()));
30 } 30 }
31 31
32 Node* JSGraph::CEntryStubConstant(int result_size) { 32 Node* JSGraph::CEntryStubConstant(int result_size, SaveFPRegsMode save_doubles,
33 if (result_size == 1) { 33 ArgvMode argv_mode, bool builtin_exit_frame) {
34 return CACHED(kCEntryStubConstant, 34 if (save_doubles == kDontSaveFPRegs && argv_mode == kArgvOnStack &&
35 HeapConstant(CEntryStub(isolate(), 1).GetCode())); 35 result_size == 1) {
36 CachedNode key = builtin_exit_frame
37 ? kCEntryStubWithBuiltinExitFrameConstant
38 : kCEntryStubConstant;
39 return CACHED(key,
40 HeapConstant(CEntryStub(isolate(), result_size, save_doubles,
41 argv_mode, builtin_exit_frame)
42 .GetCode()));
36 } 43 }
37 return HeapConstant(CEntryStub(isolate(), result_size).GetCode()); 44 CEntryStub stub(isolate(), result_size, save_doubles, argv_mode,
45 builtin_exit_frame);
46 return HeapConstant(stub.GetCode());
38 } 47 }
39 48
40
41 Node* JSGraph::EmptyFixedArrayConstant() { 49 Node* JSGraph::EmptyFixedArrayConstant() {
42 return CACHED(kEmptyFixedArrayConstant, 50 return CACHED(kEmptyFixedArrayConstant,
43 HeapConstant(factory()->empty_fixed_array())); 51 HeapConstant(factory()->empty_fixed_array()));
44 } 52 }
45 53
46 Node* JSGraph::EmptyLiteralsArrayConstant() { 54 Node* JSGraph::EmptyLiteralsArrayConstant() {
47 return CACHED(kEmptyLiteralsArrayConstant, 55 return CACHED(kEmptyLiteralsArrayConstant,
48 HeapConstant(factory()->empty_literals_array())); 56 HeapConstant(factory()->empty_literals_array()));
49 } 57 }
50 58
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after
262 for (size_t i = 0; i < arraysize(cached_nodes_); i++) { 270 for (size_t i = 0; i < arraysize(cached_nodes_); i++) {
263 if (Node* node = cached_nodes_[i]) { 271 if (Node* node = cached_nodes_[i]) {
264 if (!node->IsDead()) nodes->push_back(node); 272 if (!node->IsDead()) nodes->push_back(node);
265 } 273 }
266 } 274 }
267 } 275 }
268 276
269 } // namespace compiler 277 } // namespace compiler
270 } // namespace internal 278 } // namespace internal
271 } // namespace v8 279 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/js-graph.h ('k') | src/compiler/js-typed-lowering.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698