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

Side by Side Diff: src/mips64/full-codegen-mips64.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: Properly freeze interface at the end of ParseModule 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
« no previous file with comments | « src/mips/full-codegen-mips.cc ('k') | src/parser.h » ('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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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_MIPS64 7 #if V8_TARGET_ARCH_MIPS64
8 8
9 // Note on Mips implementation: 9 // Note on Mips implementation:
10 // 10 //
(...skipping 929 matching lines...) Expand 10 before | Expand all | Expand 10 after
940 VisitForStackValue(declaration->fun()); 940 VisitForStackValue(declaration->fun());
941 __ CallRuntime(Runtime::kDeclareLookupSlot, 4); 941 __ CallRuntime(Runtime::kDeclareLookupSlot, 4);
942 break; 942 break;
943 } 943 }
944 } 944 }
945 } 945 }
946 946
947 947
948 void FullCodeGenerator::VisitModuleDeclaration(ModuleDeclaration* declaration) { 948 void FullCodeGenerator::VisitModuleDeclaration(ModuleDeclaration* declaration) {
949 Variable* variable = declaration->proxy()->var(); 949 Variable* variable = declaration->proxy()->var();
950 Interface* interface = declaration->module()->interface();
950 DCHECK(variable->location() == Variable::CONTEXT); 951 DCHECK(variable->location() == Variable::CONTEXT);
951 DCHECK(variable->interface()->IsFrozen()); 952 DCHECK(interface->IsFrozen());
952 Comment cmnt(masm_, "[ ModuleDeclaration"); 953 Comment cmnt(masm_, "[ ModuleDeclaration");
953 EmitDebugCheckDeclarationContext(variable); 954 EmitDebugCheckDeclarationContext(variable);
954 955
955 // Load instance object. 956 // Load instance object.
956 __ LoadContext(a1, scope_->ContextChainLength(scope_->ScriptScope())); 957 __ LoadContext(a1, scope_->ContextChainLength(scope_->ScriptScope()));
957 __ ld(a1, ContextOperand(a1, variable->interface()->Index())); 958 __ ld(a1, ContextOperand(a1, interface->Index()));
958 __ ld(a1, ContextOperand(a1, Context::EXTENSION_INDEX)); 959 __ ld(a1, ContextOperand(a1, Context::EXTENSION_INDEX));
959 960
960 // Assign it. 961 // Assign it.
961 __ sd(a1, ContextOperand(cp, variable->index())); 962 __ sd(a1, ContextOperand(cp, variable->index()));
962 // We know that we have written a module, which is not a smi. 963 // We know that we have written a module, which is not a smi.
963 __ RecordWriteContextSlot(cp, 964 __ RecordWriteContextSlot(cp,
964 Context::SlotOffset(variable->index()), 965 Context::SlotOffset(variable->index()),
965 a1, 966 a1,
966 a3, 967 a3,
967 kRAHasBeenSaved, 968 kRAHasBeenSaved,
(...skipping 4480 matching lines...) Expand 10 before | Expand all | Expand 10 after
5448 Assembler::target_address_at(pc_immediate_load_address)) == 5449 Assembler::target_address_at(pc_immediate_load_address)) ==
5449 reinterpret_cast<uint64_t>( 5450 reinterpret_cast<uint64_t>(
5450 isolate->builtins()->OsrAfterStackCheck()->entry())); 5451 isolate->builtins()->OsrAfterStackCheck()->entry()));
5451 return OSR_AFTER_STACK_CHECK; 5452 return OSR_AFTER_STACK_CHECK;
5452 } 5453 }
5453 5454
5454 5455
5455 } } // namespace v8::internal 5456 } } // namespace v8::internal
5456 5457
5457 #endif // V8_TARGET_ARCH_MIPS64 5458 #endif // V8_TARGET_ARCH_MIPS64
OLDNEW
« no previous file with comments | « src/mips/full-codegen-mips.cc ('k') | src/parser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698