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

Side by Side Diff: test/cctest/interpreter/test-bytecode-generator.cc

Issue 2347143002: [interpreter] Add fast path for dynamic global lookups (Closed)
Patch Set: Fix comments and some inlining of methods Created 4 years, 3 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
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 <fstream> 5 #include <fstream>
6 6
7 #include "src/v8.h" 7 #include "src/v8.h"
8 8
9 #include "src/interpreter/bytecode-array-iterator.h" 9 #include "src/interpreter/bytecode-array-iterator.h"
10 #include "src/interpreter/bytecode-generator.h" 10 #include "src/interpreter/bytecode-generator.h"
(...skipping 1796 matching lines...) Expand 10 before | Expand all | Expand 10 after
1807 1807
1808 "eval('var x = 10;'); return typeof x;\n", 1808 "eval('var x = 10;'); return typeof x;\n",
1809 1809
1810 "x = 20; return eval('');\n", 1810 "x = 20; return eval('');\n",
1811 1811
1812 "var x = 20;\n" 1812 "var x = 20;\n"
1813 "f = function(){\n" 1813 "f = function(){\n"
1814 " eval('var x = 10');\n" 1814 " eval('var x = 10');\n"
1815 " return x;\n" 1815 " return x;\n"
1816 "}\n" 1816 "}\n"
1817 "f();\n",
1818
1819 "x = 20;\n"
1820 "f = function(){\n"
1821 " eval('var x = 10');\n"
1822 " return x;\n"
1823 "}\n"
1817 "f();\n" 1824 "f();\n"
1818 }; 1825 };
1819 // clang-format on 1826 // clang-format on
1820 1827
1821 CHECK(CompareTexts(BuildActual(printer, snippets), 1828 CHECK(CompareTexts(BuildActual(printer, snippets),
1822 LoadGolden("LookupSlot.golden"))); 1829 LoadGolden("LookupSlot.golden")));
1823 } 1830 }
1824 1831
1825 TEST(CallLookupSlot) { 1832 TEST(CallLookupSlot) {
1826 InitializedIgnitionHandleScope scope; 1833 InitializedIgnitionHandleScope scope;
(...skipping 367 matching lines...) Expand 10 before | Expand all | Expand 10 after
2194 "f();\n", 2201 "f();\n",
2195 }; 2202 };
2196 2203
2197 CHECK(CompareTexts(BuildActual(printer, snippets), 2204 CHECK(CompareTexts(BuildActual(printer, snippets),
2198 LoadGolden("Generators.golden"))); 2205 LoadGolden("Generators.golden")));
2199 } 2206 }
2200 2207
2201 } // namespace interpreter 2208 } // namespace interpreter
2202 } // namespace internal 2209 } // namespace internal
2203 } // namespace v8 2210 } // namespace v8
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698