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

Unified Diff: test/cctest/interpreter/bytecode_expectations/Modules.golden

Issue 2465283004: [modules] Maintain array of cells for imports and local exports. (Closed)
Patch Set: Rename parameter also in header file. 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/runtime/runtime-module.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/interpreter/bytecode_expectations/Modules.golden
diff --git a/test/cctest/interpreter/bytecode_expectations/Modules.golden b/test/cctest/interpreter/bytecode_expectations/Modules.golden
index 65e1b674d8bd2f63b044e2210acbb8bbd84f09ec..4a0af44fa400ae97f7061cd05605a93132acff88 100644
--- a/test/cctest/interpreter/bytecode_expectations/Modules.golden
+++ b/test/cctest/interpreter/bytecode_expectations/Modules.golden
@@ -153,7 +153,7 @@ snippet: "
"
frame size: 9
parameter count: 2
-bytecode array length: 211
+bytecode array length: 205
bytecodes: [
B(Ldar), R(new_target),
B(JumpIfUndefined), U8(21),
@@ -208,36 +208,32 @@ bytecodes: [
B(Ldar), R(5),
/* 0 E> */ B(Throw),
/* 32 S> */ B(LdrUndefined), R(4),
- B(LdaConstant), U8(1),
+ B(LdaSmi), U8(-1),
B(Star), R(6),
- B(LdaZero),
- B(Star), R(7),
- /* 32 E> */ B(CallRuntime), U16(Runtime::kLoadModuleImport), R(6), U8(2),
+ /* 32 E> */ B(CallRuntime), U16(Runtime::kLoadModuleVariable), R(6), U8(1),
B(JumpIfNotHole), U8(11),
- B(LdaConstant), U8(2),
- B(Star), R(8),
- B(CallRuntime), U16(Runtime::kThrowReferenceError), R(8), U8(1),
+ B(LdaConstant), U8(1),
+ B(Star), R(7),
+ B(CallRuntime), U16(Runtime::kThrowReferenceError), R(7), U8(1),
B(Star), R(3),
B(LdaSmi), U8(42),
B(Star), R(5),
/* 32 E> */ B(Call), R(3), R(4), U8(2), U8(2),
B(Ldar), R(closure),
- B(CreateBlockContext), U8(3),
+ B(CreateBlockContext), U8(2),
B(PushContext), R(1),
B(LdaTheHole),
B(StaCurrentContextSlot), U8(4),
/* 47 S> */ B(LdaUndefined),
/* 47 E> */ B(StaCurrentContextSlot), U8(4),
/* 52 S> */ B(LdrUndefined), R(4),
- B(LdaConstant), U8(1),
+ B(LdaSmi), U8(-1),
B(Star), R(6),
- B(LdaZero),
- B(Star), R(7),
- /* 52 E> */ B(CallRuntime), U16(Runtime::kLoadModuleImport), R(6), U8(2),
+ /* 52 E> */ B(CallRuntime), U16(Runtime::kLoadModuleVariable), R(6), U8(1),
B(JumpIfNotHole), U8(11),
- B(LdaConstant), U8(2),
- B(Star), R(8),
- B(CallRuntime), U16(Runtime::kThrowReferenceError), R(8), U8(1),
+ B(LdaConstant), U8(1),
+ B(Star), R(7),
+ B(CallRuntime), U16(Runtime::kThrowReferenceError), R(7), U8(1),
B(Star), R(3),
B(LdaSmi), U8(42),
B(Star), R(5),
@@ -248,7 +244,6 @@ bytecodes: [
]
constant pool: [
FIXED_ARRAY_TYPE,
- ONE_BYTE_INTERNALIZED_STRING_TYPE ["foo"],
ONE_BYTE_INTERNALIZED_STRING_TYPE ["goo"],
FIXED_ARRAY_TYPE,
]
@@ -319,39 +314,38 @@ bytecodes: [
/* 0 E> */ B(Throw),
/* 17 S> */ B(LdaSmi), U8(42),
B(Star), R(4),
- B(LdaConstant), U8(1),
+ B(LdaSmi), U8(1),
B(Star), R(3),
- /* 17 E> */ B(CallRuntime), U16(Runtime::kStoreModuleExport), R(3), U8(2),
- /* 21 S> */ B(LdaConstant), U8(1),
+ /* 17 E> */ B(CallRuntime), U16(Runtime::kStoreModuleVariable), R(3), U8(2),
+ /* 21 S> */ B(LdaSmi), U8(1),
B(Star), R(3),
- B(CallRuntime), U16(Runtime::kLoadModuleExport), R(3), U8(1),
+ B(CallRuntime), U16(Runtime::kLoadModuleVariable), R(3), U8(1),
B(Inc), U8(2),
B(Star), R(4),
- B(LdaConstant), U8(1),
+ B(LdaSmi), U8(1),
B(Star), R(3),
- /* 24 E> */ B(CallRuntime), U16(Runtime::kStoreModuleExport), R(3), U8(2),
+ /* 24 E> */ B(CallRuntime), U16(Runtime::kStoreModuleVariable), R(3), U8(2),
B(Ldar), R(closure),
- B(CreateBlockContext), U8(2),
+ B(CreateBlockContext), U8(1),
B(PushContext), R(1),
B(LdaTheHole),
B(StaCurrentContextSlot), U8(4),
/* 34 S> */ B(LdaUndefined),
/* 34 E> */ B(StaCurrentContextSlot), U8(4),
- /* 39 S> */ B(LdaConstant), U8(1),
+ /* 39 S> */ B(LdaSmi), U8(1),
B(Star), R(3),
- B(CallRuntime), U16(Runtime::kLoadModuleExport), R(3), U8(1),
+ B(CallRuntime), U16(Runtime::kLoadModuleVariable), R(3), U8(1),
B(Inc), U8(3),
B(Star), R(4),
- B(LdaConstant), U8(1),
+ B(LdaSmi), U8(1),
B(Star), R(3),
- /* 42 E> */ B(CallRuntime), U16(Runtime::kStoreModuleExport), R(3), U8(2),
+ /* 42 E> */ B(CallRuntime), U16(Runtime::kStoreModuleVariable), R(3), U8(2),
B(PopContext), R(1),
B(LdaUndefined),
/* 49 S> */ B(Return),
]
constant pool: [
FIXED_ARRAY_TYPE,
- ONE_BYTE_INTERNALIZED_STRING_TYPE ["foo"],
FIXED_ARRAY_TYPE,
]
handlers: [
@@ -389,9 +383,9 @@ bytecodes: [
B(StaCurrentContextSlot), U8(4),
B(LdaTheHole),
B(Star), R(4),
- B(LdaConstant), U8(1),
+ B(LdaSmi), U8(1),
B(Star), R(3),
- B(CallRuntime), U16(Runtime::kStoreModuleExport), R(3), U8(2),
+ B(CallRuntime), U16(Runtime::kStoreModuleVariable), R(3), U8(2),
/* 0 E> */ B(StackCheck),
/* 0 E> */ B(LdrCurrentContextSlot), U8(4), R(4),
B(Ldar), R(4),
@@ -426,39 +420,38 @@ bytecodes: [
/* 0 E> */ B(Throw),
/* 17 S> */ B(LdaSmi), U8(42),
B(Star), R(4),
- B(LdaConstant), U8(1),
+ B(LdaSmi), U8(1),
B(Star), R(3),
- /* 17 E> */ B(CallRuntime), U16(Runtime::kStoreModuleExport), R(3), U8(2),
- /* 21 S> */ B(LdaConstant), U8(1),
+ /* 17 E> */ B(CallRuntime), U16(Runtime::kStoreModuleVariable), R(3), U8(2),
+ /* 21 S> */ B(LdaSmi), U8(1),
B(Star), R(3),
- B(CallRuntime), U16(Runtime::kLoadModuleExport), R(3), U8(1),
+ B(CallRuntime), U16(Runtime::kLoadModuleVariable), R(3), U8(1),
B(Inc), U8(2),
B(Star), R(4),
- B(LdaConstant), U8(1),
+ B(LdaSmi), U8(1),
B(Star), R(3),
- /* 24 E> */ B(CallRuntime), U16(Runtime::kStoreModuleExport), R(3), U8(2),
+ /* 24 E> */ B(CallRuntime), U16(Runtime::kStoreModuleVariable), R(3), U8(2),
B(Ldar), R(closure),
- B(CreateBlockContext), U8(2),
+ B(CreateBlockContext), U8(1),
B(PushContext), R(1),
B(LdaTheHole),
B(StaCurrentContextSlot), U8(4),
/* 34 S> */ B(LdaUndefined),
/* 34 E> */ B(StaCurrentContextSlot), U8(4),
- /* 39 S> */ B(LdaConstant), U8(1),
+ /* 39 S> */ B(LdaSmi), U8(1),
B(Star), R(3),
- B(CallRuntime), U16(Runtime::kLoadModuleExport), R(3), U8(1),
+ B(CallRuntime), U16(Runtime::kLoadModuleVariable), R(3), U8(1),
B(Inc), U8(3),
B(Star), R(4),
- B(LdaConstant), U8(1),
+ B(LdaSmi), U8(1),
B(Star), R(3),
- /* 42 E> */ B(CallRuntime), U16(Runtime::kStoreModuleExport), R(3), U8(2),
+ /* 42 E> */ B(CallRuntime), U16(Runtime::kStoreModuleVariable), R(3), U8(2),
B(PopContext), R(1),
B(LdaUndefined),
/* 49 S> */ B(Return),
]
constant pool: [
FIXED_ARRAY_TYPE,
- ONE_BYTE_INTERNALIZED_STRING_TYPE ["foo"],
FIXED_ARRAY_TYPE,
]
handlers: [
@@ -496,9 +489,9 @@ bytecodes: [
B(StaCurrentContextSlot), U8(4),
B(LdaTheHole),
B(Star), R(4),
- B(LdaConstant), U8(1),
+ B(LdaSmi), U8(1),
B(Star), R(3),
- B(CallRuntime), U16(Runtime::kStoreModuleExport), R(3), U8(2),
+ B(CallRuntime), U16(Runtime::kStoreModuleVariable), R(3), U8(2),
/* 0 E> */ B(StackCheck),
/* 0 E> */ B(LdrCurrentContextSlot), U8(4), R(4),
B(Ldar), R(4),
@@ -533,24 +526,24 @@ bytecodes: [
/* 0 E> */ B(Throw),
/* 19 S> */ B(LdaSmi), U8(42),
B(Star), R(4),
- B(LdaConstant), U8(1),
+ B(LdaSmi), U8(1),
B(Star), R(3),
- /* 19 E> */ B(CallRuntime), U16(Runtime::kStoreModuleExport), R(3), U8(2),
- /* 23 S> */ B(LdaConstant), U8(1),
+ /* 19 E> */ B(CallRuntime), U16(Runtime::kStoreModuleVariable), R(3), U8(2),
+ /* 23 S> */ B(LdaSmi), U8(1),
B(Star), R(3),
- B(CallRuntime), U16(Runtime::kLoadModuleExport), R(3), U8(1),
+ B(CallRuntime), U16(Runtime::kLoadModuleVariable), R(3), U8(1),
B(Inc), U8(2),
/* 26 E> */ B(CallRuntime), U16(Runtime::kThrowConstAssignError), R(0), U8(0),
B(Ldar), R(closure),
- B(CreateBlockContext), U8(2),
+ B(CreateBlockContext), U8(1),
B(PushContext), R(1),
B(LdaTheHole),
B(StaCurrentContextSlot), U8(4),
/* 36 S> */ B(LdaUndefined),
/* 36 E> */ B(StaCurrentContextSlot), U8(4),
- /* 41 S> */ B(LdaConstant), U8(1),
+ /* 41 S> */ B(LdaSmi), U8(1),
B(Star), R(3),
- B(CallRuntime), U16(Runtime::kLoadModuleExport), R(3), U8(1),
+ B(CallRuntime), U16(Runtime::kLoadModuleVariable), R(3), U8(1),
B(Inc), U8(3),
/* 44 E> */ B(CallRuntime), U16(Runtime::kThrowConstAssignError), R(0), U8(0),
B(PopContext), R(1),
@@ -559,7 +552,6 @@ bytecodes: [
]
constant pool: [
FIXED_ARRAY_TYPE,
- ONE_BYTE_INTERNALIZED_STRING_TYPE ["foo"],
FIXED_ARRAY_TYPE,
]
handlers: [
@@ -595,9 +587,9 @@ bytecodes: [
B(StaCurrentContextSlot), U8(4),
B(LdaTheHole),
B(Star), R(3),
- B(LdaConstant), U8(1),
+ B(LdaSmi), U8(1),
B(Star), R(2),
- B(CallRuntime), U16(Runtime::kStoreModuleExport), R(2), U8(2),
+ B(CallRuntime), U16(Runtime::kStoreModuleVariable), R(2), U8(2),
/* 0 E> */ B(StackCheck),
/* 0 E> */ B(LdrCurrentContextSlot), U8(4), R(3),
B(Ldar), R(3),
@@ -630,17 +622,16 @@ bytecodes: [
/* 32 S> */ B(Return),
B(Ldar), R(4),
/* 0 E> */ B(Throw),
- B(CreateClosure), U8(2), U8(0),
+ B(CreateClosure), U8(1), U8(0),
B(Star), R(3),
- B(LdaConstant), U8(1),
+ B(LdaSmi), U8(1),
B(Star), R(2),
- B(CallRuntime), U16(Runtime::kStoreModuleExport), R(2), U8(2),
+ B(CallRuntime), U16(Runtime::kStoreModuleVariable), R(2), U8(2),
B(LdaUndefined),
/* 32 S> */ B(Return),
]
constant pool: [
FIXED_ARRAY_TYPE,
- ONE_BYTE_INTERNALIZED_STRING_TYPE ["default"],
SHARED_FUNCTION_INFO_TYPE,
]
handlers: [
@@ -676,9 +667,9 @@ bytecodes: [
B(StaCurrentContextSlot), U8(4),
B(LdaTheHole),
B(Star), R(3),
- B(LdaConstant), U8(1),
+ B(LdaSmi), U8(1),
B(Star), R(2),
- B(CallRuntime), U16(Runtime::kStoreModuleExport), R(2), U8(2),
+ B(CallRuntime), U16(Runtime::kStoreModuleVariable), R(2), U8(2),
/* 0 E> */ B(StackCheck),
/* 0 E> */ B(LdrCurrentContextSlot), U8(4), R(3),
B(Ldar), R(3),
@@ -713,7 +704,7 @@ bytecodes: [
/* 0 E> */ B(Throw),
/* 16 S> */ B(LdaTheHole),
B(Star), R(2),
- B(CreateClosure), U8(2), U8(0),
+ B(CreateClosure), U8(1), U8(0),
B(Star), R(3),
B(LdaSmi), U8(16),
B(Star), R(4),
@@ -721,19 +712,18 @@ bytecodes: [
B(Star), R(5),
B(CallRuntime), U16(Runtime::kDefineClass), R(2), U8(4),
B(Star), R(2),
- B(LdrNamedProperty), R(2), U8(3), U8(2), R(3),
+ B(LdrNamedProperty), R(2), U8(2), U8(2), R(3),
B(CallRuntime), U16(Runtime::kToFastProperties), R(2), U8(1),
B(StaCurrentContextSlot), U8(6),
/* 16 E> */ B(LdrCurrentContextSlot), U8(6), R(3),
- B(LdaConstant), U8(1),
+ B(LdaSmi), U8(1),
B(Star), R(2),
- B(CallRuntime), U16(Runtime::kStoreModuleExport), R(2), U8(2),
+ B(CallRuntime), U16(Runtime::kStoreModuleVariable), R(2), U8(2),
B(LdaUndefined),
/* 26 S> */ B(Return),
]
constant pool: [
FIXED_ARRAY_TYPE,
- ONE_BYTE_INTERNALIZED_STRING_TYPE ["default"],
SHARED_FUNCTION_INFO_TYPE,
ONE_BYTE_INTERNALIZED_STRING_TYPE ["prototype"],
]
« no previous file with comments | « src/runtime/runtime-module.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698