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

Side by Side Diff: test/cctest/compiler/test-run-inlining.cc

Issue 1872333002: [turbofan] Remove support for --turbo-types. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 8 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 | « test/cctest/compiler/test-pipeline.cc ('k') | no next file » | 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/frames-inl.h" 5 #include "src/frames-inl.h"
6 #include "test/cctest/compiler/function-tester.h" 6 #include "test/cctest/compiler/function-tester.h"
7 7
8 namespace v8 { 8 namespace v8 {
9 namespace internal { 9 namespace internal {
10 namespace compiler { 10 namespace compiler {
(...skipping 29 matching lines...) Expand all
40 void InstallAssertInlineCountHelper(v8::Isolate* isolate) { 40 void InstallAssertInlineCountHelper(v8::Isolate* isolate) {
41 v8::Local<v8::Context> context = isolate->GetCurrentContext(); 41 v8::Local<v8::Context> context = isolate->GetCurrentContext();
42 v8::Local<v8::FunctionTemplate> t = 42 v8::Local<v8::FunctionTemplate> t =
43 v8::FunctionTemplate::New(isolate, AssertInlineCount); 43 v8::FunctionTemplate::New(isolate, AssertInlineCount);
44 CHECK(context->Global() 44 CHECK(context->Global()
45 ->Set(context, v8_str("AssertInlineCount"), 45 ->Set(context, v8_str("AssertInlineCount"),
46 t->GetFunction(context).ToLocalChecked()) 46 t->GetFunction(context).ToLocalChecked())
47 .FromJust()); 47 .FromJust());
48 } 48 }
49 49
50
51 const uint32_t kRestrictedInliningFlags = 50 const uint32_t kRestrictedInliningFlags =
52 CompilationInfo::kFunctionContextSpecializing | 51 CompilationInfo::kFunctionContextSpecializing;
53 CompilationInfo::kTypingEnabled;
54 52
55 const uint32_t kInlineFlags = CompilationInfo::kInliningEnabled | 53 const uint32_t kInlineFlags = CompilationInfo::kInliningEnabled |
56 CompilationInfo::kFunctionContextSpecializing | 54 CompilationInfo::kFunctionContextSpecializing;
57 CompilationInfo::kTypingEnabled;
58 55
59 } // namespace 56 } // namespace
60 57
61 58
62 TEST(SimpleInlining) { 59 TEST(SimpleInlining) {
63 FunctionTester T( 60 FunctionTester T(
64 "(function(){" 61 "(function(){"
65 " function foo(s) { AssertInlineCount(2); return s; };" 62 " function foo(s) { AssertInlineCount(2); return s; };"
66 " function bar(s, t) { return foo(s); };" 63 " function bar(s, t) { return foo(s); };"
67 " return bar;" 64 " return bar;"
(...skipping 504 matching lines...) Expand 10 before | Expand all | Expand 10 after
572 "})();", 569 "})();",
573 kInlineFlags); 570 kInlineFlags);
574 571
575 InstallAssertInlineCountHelper(CcTest::isolate()); 572 InstallAssertInlineCountHelper(CcTest::isolate());
576 T.CheckCall(T.Val(42), T.Val(1)); 573 T.CheckCall(T.Val(42), T.Val(1));
577 } 574 }
578 575
579 } // namespace compiler 576 } // namespace compiler
580 } // namespace internal 577 } // namespace internal
581 } // namespace v8 578 } // namespace v8
OLDNEW
« no previous file with comments | « test/cctest/compiler/test-pipeline.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698