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

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

Issue 2559083002: X87: Store OSR'd optimized code on the native context. (Closed)
Patch Set: 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 | « no previous file | no next file » | 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_X87 5 #if V8_TARGET_ARCH_X87
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 1038 matching lines...) Expand 10 before | Expand all | Expand 10 after
1049 1049
1050 __ bind(&loop_top); 1050 __ bind(&loop_top);
1051 Register temp = edi; 1051 Register temp = edi;
1052 1052
1053 // Does the native context match? 1053 // Does the native context match?
1054 __ mov(temp, FieldOperand(map, index, times_half_pointer_size, 1054 __ mov(temp, FieldOperand(map, index, times_half_pointer_size,
1055 SharedFunctionInfo::kOffsetToPreviousContext)); 1055 SharedFunctionInfo::kOffsetToPreviousContext));
1056 __ mov(temp, FieldOperand(temp, WeakCell::kValueOffset)); 1056 __ mov(temp, FieldOperand(temp, WeakCell::kValueOffset));
1057 __ cmp(temp, native_context); 1057 __ cmp(temp, native_context);
1058 __ j(not_equal, &loop_bottom); 1058 __ j(not_equal, &loop_bottom);
1059 // OSR id set to none?
1060 __ mov(temp, FieldOperand(map, index, times_half_pointer_size,
1061 SharedFunctionInfo::kOffsetToPreviousOsrAstId));
1062 const int bailout_id = BailoutId::None().ToInt();
1063 __ cmp(temp, Immediate(Smi::FromInt(bailout_id)));
1064 __ j(not_equal, &loop_bottom);
1065 // Literals available? 1059 // Literals available?
1066 __ mov(temp, FieldOperand(map, index, times_half_pointer_size, 1060 __ mov(temp, FieldOperand(map, index, times_half_pointer_size,
1067 SharedFunctionInfo::kOffsetToPreviousLiterals)); 1061 SharedFunctionInfo::kOffsetToPreviousLiterals));
1068 __ mov(temp, FieldOperand(temp, WeakCell::kValueOffset)); 1062 __ mov(temp, FieldOperand(temp, WeakCell::kValueOffset));
1069 __ JumpIfSmi(temp, &gotta_call_runtime); 1063 __ JumpIfSmi(temp, &gotta_call_runtime);
1070 1064
1071 // Save the literals in the closure. 1065 // Save the literals in the closure.
1072 __ mov(ecx, Operand(esp, 0)); 1066 __ mov(ecx, Operand(esp, 0));
1073 __ mov(FieldOperand(ecx, JSFunction::kLiteralsOffset), temp); 1067 __ mov(FieldOperand(ecx, JSFunction::kLiteralsOffset), temp);
1074 __ push(index); 1068 __ push(index);
(...skipping 2068 matching lines...) Expand 10 before | Expand all | Expand 10 after
3143 3137
3144 void Builtins::Generate_InterpreterOnStackReplacement(MacroAssembler* masm) { 3138 void Builtins::Generate_InterpreterOnStackReplacement(MacroAssembler* masm) {
3145 Generate_OnStackReplacementHelper(masm, true); 3139 Generate_OnStackReplacementHelper(masm, true);
3146 } 3140 }
3147 3141
3148 #undef __ 3142 #undef __
3149 } // namespace internal 3143 } // namespace internal
3150 } // namespace v8 3144 } // namespace v8
3151 3145
3152 #endif // V8_TARGET_ARCH_X87 3146 #endif // V8_TARGET_ARCH_X87
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698