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

Side by Side Diff: src/arm/deoptimizer-arm.cc

Issue 2732273003: Disentangle assembler from isolate. (Closed)
Patch Set: Address feedback. Created 3 years, 9 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/arm/codegen-arm.cc ('k') | src/arm/macro-assembler-arm.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/assembler-inl.h" 5 #include "src/assembler-inl.h"
6 #include "src/codegen.h" 6 #include "src/codegen.h"
7 #include "src/deoptimizer.h" 7 #include "src/deoptimizer.h"
8 #include "src/full-codegen/full-codegen.h" 8 #include "src/full-codegen/full-codegen.h"
9 #include "src/objects-inl.h" 9 #include "src/objects-inl.h"
10 #include "src/register-configuration.h" 10 #include "src/register-configuration.h"
(...skipping 24 matching lines...) Expand all
35 code->InvalidateRelocation(); 35 code->InvalidateRelocation();
36 36
37 if (FLAG_zap_code_space) { 37 if (FLAG_zap_code_space) {
38 // Fail hard and early if we enter this code object again. 38 // Fail hard and early if we enter this code object again.
39 byte* pointer = code->FindCodeAgeSequence(); 39 byte* pointer = code->FindCodeAgeSequence();
40 if (pointer != NULL) { 40 if (pointer != NULL) {
41 pointer += kNoCodeAgeSequenceLength; 41 pointer += kNoCodeAgeSequenceLength;
42 } else { 42 } else {
43 pointer = code->instruction_start(); 43 pointer = code->instruction_start();
44 } 44 }
45 CodePatcher patcher(isolate, pointer, 1); 45
46 patcher.masm()->bkpt(0); 46 {
47 PatchingAssembler patcher(Assembler::IsolateData(isolate), pointer, 1);
48 patcher.bkpt(0);
49 patcher.FlushICache(isolate);
50 }
47 51
48 DeoptimizationInputData* data = 52 DeoptimizationInputData* data =
49 DeoptimizationInputData::cast(code->deoptimization_data()); 53 DeoptimizationInputData::cast(code->deoptimization_data());
50 int osr_offset = data->OsrPcOffset()->value(); 54 int osr_offset = data->OsrPcOffset()->value();
51 if (osr_offset > 0) { 55 if (osr_offset > 0) {
52 CodePatcher osr_patcher(isolate, code->instruction_start() + osr_offset, 56 PatchingAssembler patcher(Assembler::IsolateData(isolate),
53 1); 57 code->instruction_start() + osr_offset, 1);
54 osr_patcher.masm()->bkpt(0); 58 patcher.bkpt(0);
59 patcher.FlushICache(isolate);
55 } 60 }
56 } 61 }
57 62
58 DeoptimizationInputData* deopt_data = 63 DeoptimizationInputData* deopt_data =
59 DeoptimizationInputData::cast(code->deoptimization_data()); 64 DeoptimizationInputData::cast(code->deoptimization_data());
60 #ifdef DEBUG 65 #ifdef DEBUG
61 Address prev_call_address = NULL; 66 Address prev_call_address = NULL;
62 #endif 67 #endif
63 // For each LLazyBailout instruction insert a call to the corresponding 68 // For each LLazyBailout instruction insert a call to the corresponding
64 // deoptimization entry. 69 // deoptimization entry.
(...skipping 304 matching lines...) Expand 10 before | Expand all | Expand 10 after
369 void FrameDescription::SetCallerConstantPool(unsigned offset, intptr_t value) { 374 void FrameDescription::SetCallerConstantPool(unsigned offset, intptr_t value) {
370 DCHECK(FLAG_enable_embedded_constant_pool); 375 DCHECK(FLAG_enable_embedded_constant_pool);
371 SetFrameSlot(offset, value); 376 SetFrameSlot(offset, value);
372 } 377 }
373 378
374 379
375 #undef __ 380 #undef __
376 381
377 } // namespace internal 382 } // namespace internal
378 } // namespace v8 383 } // namespace v8
OLDNEW
« no previous file with comments | « src/arm/codegen-arm.cc ('k') | src/arm/macro-assembler-arm.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698