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

Side by Side Diff: src/builtins/x64/builtins-x64.cc

Issue 2534763003: [Interpreter] Add bytecode aging and use it enable CompilationCache for bytecode (Closed)
Patch Set: Rebase Created 4 years 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/builtins/s390/builtins-s390.cc ('k') | src/builtins/x87/builtins-x87.cc » ('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 #if V8_TARGET_ARCH_X64 5 #if V8_TARGET_ARCH_X64
6 6
7 #include "src/code-factory.h" 7 #include "src/code-factory.h"
8 #include "src/codegen.h" 8 #include "src/codegen.h"
9 #include "src/deoptimizer.h" 9 #include "src/deoptimizer.h"
10 #include "src/full-codegen/full-codegen.h" 10 #include "src/full-codegen/full-codegen.h"
(...skipping 625 matching lines...) Expand 10 before | Expand all | Expand 10 after
636 Smi::FromInt(1)); 636 Smi::FromInt(1));
637 637
638 // Check function data field is actually a BytecodeArray object. 638 // Check function data field is actually a BytecodeArray object.
639 if (FLAG_debug_code) { 639 if (FLAG_debug_code) {
640 __ AssertNotSmi(kInterpreterBytecodeArrayRegister); 640 __ AssertNotSmi(kInterpreterBytecodeArrayRegister);
641 __ CmpObjectType(kInterpreterBytecodeArrayRegister, BYTECODE_ARRAY_TYPE, 641 __ CmpObjectType(kInterpreterBytecodeArrayRegister, BYTECODE_ARRAY_TYPE,
642 rax); 642 rax);
643 __ Assert(equal, kFunctionDataShouldBeBytecodeArrayOnInterpreterEntry); 643 __ Assert(equal, kFunctionDataShouldBeBytecodeArrayOnInterpreterEntry);
644 } 644 }
645 645
646 // Reset code age.
647 __ movb(FieldOperand(kInterpreterBytecodeArrayRegister,
648 BytecodeArray::kBytecodeAgeOffset),
649 Immediate(BytecodeArray::kNoAgeBytecodeAge));
650
646 // Load initial bytecode offset. 651 // Load initial bytecode offset.
647 __ movp(kInterpreterBytecodeOffsetRegister, 652 __ movp(kInterpreterBytecodeOffsetRegister,
648 Immediate(BytecodeArray::kHeaderSize - kHeapObjectTag)); 653 Immediate(BytecodeArray::kHeaderSize - kHeapObjectTag));
649 654
650 // Push bytecode array and Smi tagged bytecode offset. 655 // Push bytecode array and Smi tagged bytecode offset.
651 __ Push(kInterpreterBytecodeArrayRegister); 656 __ Push(kInterpreterBytecodeArrayRegister);
652 __ Integer32ToSmi(rcx, kInterpreterBytecodeOffsetRegister); 657 __ Integer32ToSmi(rcx, kInterpreterBytecodeOffsetRegister);
653 __ Push(rcx); 658 __ Push(rcx);
654 659
655 // Allocate the local and temporary register file on the stack. 660 // Allocate the local and temporary register file on the stack.
(...skipping 2394 matching lines...) Expand 10 before | Expand all | Expand 10 after
3050 void Builtins::Generate_InterpreterOnStackReplacement(MacroAssembler* masm) { 3055 void Builtins::Generate_InterpreterOnStackReplacement(MacroAssembler* masm) {
3051 Generate_OnStackReplacementHelper(masm, true); 3056 Generate_OnStackReplacementHelper(masm, true);
3052 } 3057 }
3053 3058
3054 #undef __ 3059 #undef __
3055 3060
3056 } // namespace internal 3061 } // namespace internal
3057 } // namespace v8 3062 } // namespace v8
3058 3063
3059 #endif // V8_TARGET_ARCH_X64 3064 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/builtins/s390/builtins-s390.cc ('k') | src/builtins/x87/builtins-x87.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698