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

Side by Side Diff: src/compiler/js-inlining-heuristic.cc

Issue 2493173002: [turbofan] Fix more -Wsign-compare warnings. (Closed)
Patch Set: rebase Created 4 years, 1 month 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/effect-control-linearizer.cc ('k') | src/compiler/pipeline.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 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 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/js-inlining-heuristic.h" 5 #include "src/compiler/js-inlining-heuristic.h"
6 6
7 #include "src/compilation-info.h" 7 #include "src/compilation-info.h"
8 #include "src/compiler/common-operator.h" 8 #include "src/compiler/common-operator.h"
9 #include "src/compiler/node-matchers.h" 9 #include "src/compiler/node-matchers.h"
10 #include "src/compiler/simplified-operator.h" 10 #include "src/compiler/simplified-operator.h"
11 #include "src/objects-inl.h" 11 #include "src/objects-inl.h"
12 12
13 namespace v8 { 13 namespace v8 {
14 namespace internal { 14 namespace internal {
15 namespace compiler { 15 namespace compiler {
16 16
17 #define TRACE(...) \ 17 #define TRACE(...) \
18 do { \ 18 do { \
19 if (FLAG_trace_turbo_inlining) PrintF(__VA_ARGS__); \ 19 if (FLAG_trace_turbo_inlining) PrintF(__VA_ARGS__); \
20 } while (false) 20 } while (false)
21 21
22 namespace { 22 namespace {
23 23
24 int CollectFunctions(Node* node, Handle<JSFunction>* functions, 24 int CollectFunctions(Node* node, Handle<JSFunction>* functions,
25 int functions_size) { 25 int functions_size) {
26 DCHECK_NE(0u, functions_size); 26 DCHECK_NE(0, functions_size);
27 HeapObjectMatcher m(node); 27 HeapObjectMatcher m(node);
28 if (m.HasValue() && m.Value()->IsJSFunction()) { 28 if (m.HasValue() && m.Value()->IsJSFunction()) {
29 functions[0] = Handle<JSFunction>::cast(m.Value()); 29 functions[0] = Handle<JSFunction>::cast(m.Value());
30 return 1; 30 return 1;
31 } 31 }
32 if (m.IsPhi()) { 32 if (m.IsPhi()) {
33 int const value_input_count = m.node()->op()->ValueInputCount(); 33 int const value_input_count = m.node()->op()->ValueInputCount();
34 if (value_input_count > functions_size) return 0; 34 if (value_input_count > functions_size) return 0;
35 for (int n = 0; n < value_input_count; ++n) { 35 for (int n = 0; n < value_input_count; ++n) {
36 HeapObjectMatcher m(node->InputAt(n)); 36 HeapObjectMatcher m(node->InputAt(n));
(...skipping 257 matching lines...) Expand 10 before | Expand all | Expand 10 after
294 return jsgraph()->common(); 294 return jsgraph()->common();
295 } 295 }
296 296
297 SimplifiedOperatorBuilder* JSInliningHeuristic::simplified() const { 297 SimplifiedOperatorBuilder* JSInliningHeuristic::simplified() const {
298 return jsgraph()->simplified(); 298 return jsgraph()->simplified();
299 } 299 }
300 300
301 } // namespace compiler 301 } // namespace compiler
302 } // namespace internal 302 } // namespace internal
303 } // namespace v8 303 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/effect-control-linearizer.cc ('k') | src/compiler/pipeline.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698