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/arm64/full-codegen-arm64.cc

Issue 918373002: Strip Interface class of most of its logic, make it all about Module exports (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Merged to trunk Created 5 years, 10 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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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/v8.h" 5 #include "src/v8.h"
6 6
7 #if V8_TARGET_ARCH_ARM64 7 #if V8_TARGET_ARCH_ARM64
8 8
9 #include "src/code-factory.h" 9 #include "src/code-factory.h"
10 #include "src/code-stubs.h" 10 #include "src/code-stubs.h"
(...skipping 917 matching lines...) Expand 10 before | Expand all | Expand 10 after
928 VisitForStackValue(declaration->fun()); 928 VisitForStackValue(declaration->fun());
929 __ CallRuntime(Runtime::kDeclareLookupSlot, 4); 929 __ CallRuntime(Runtime::kDeclareLookupSlot, 4);
930 break; 930 break;
931 } 931 }
932 } 932 }
933 } 933 }
934 934
935 935
936 void FullCodeGenerator::VisitModuleDeclaration(ModuleDeclaration* declaration) { 936 void FullCodeGenerator::VisitModuleDeclaration(ModuleDeclaration* declaration) {
937 Variable* variable = declaration->proxy()->var(); 937 Variable* variable = declaration->proxy()->var();
938 Interface* interface = declaration->module()->interface();
938 DCHECK(variable->location() == Variable::CONTEXT); 939 DCHECK(variable->location() == Variable::CONTEXT);
939 DCHECK(variable->interface()->IsFrozen()); 940 DCHECK(interface->IsFrozen());
940 941
941 Comment cmnt(masm_, "[ ModuleDeclaration"); 942 Comment cmnt(masm_, "[ ModuleDeclaration");
942 EmitDebugCheckDeclarationContext(variable); 943 EmitDebugCheckDeclarationContext(variable);
943 944
944 // Load instance object. 945 // Load instance object.
945 __ LoadContext(x1, scope_->ContextChainLength(scope_->ScriptScope())); 946 __ LoadContext(x1, scope_->ContextChainLength(scope_->ScriptScope()));
946 __ Ldr(x1, ContextMemOperand(x1, variable->interface()->Index())); 947 __ Ldr(x1, ContextMemOperand(x1, interface->Index()));
947 __ Ldr(x1, ContextMemOperand(x1, Context::EXTENSION_INDEX)); 948 __ Ldr(x1, ContextMemOperand(x1, Context::EXTENSION_INDEX));
948 949
949 // Assign it. 950 // Assign it.
950 __ Str(x1, ContextMemOperand(cp, variable->index())); 951 __ Str(x1, ContextMemOperand(cp, variable->index()));
951 // We know that we have written a module, which is not a smi. 952 // We know that we have written a module, which is not a smi.
952 __ RecordWriteContextSlot(cp, 953 __ RecordWriteContextSlot(cp,
953 Context::SlotOffset(variable->index()), 954 Context::SlotOffset(variable->index()),
954 x1, 955 x1,
955 x3, 956 x3,
956 kLRHasBeenSaved, 957 kLRHasBeenSaved,
(...skipping 4504 matching lines...) Expand 10 before | Expand all | Expand 10 after
5461 return previous_; 5462 return previous_;
5462 } 5463 }
5463 5464
5464 5465
5465 #undef __ 5466 #undef __
5466 5467
5467 5468
5468 } } // namespace v8::internal 5469 } } // namespace v8::internal
5469 5470
5470 #endif // V8_TARGET_ARCH_ARM64 5471 #endif // V8_TARGET_ARCH_ARM64
OLDNEW
« no previous file with comments | « src/arm/full-codegen-arm.cc ('k') | src/ast.h » ('j') | src/globals.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698