OLD | NEW |
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/mips/codegen-mips.h" | 5 #include "src/mips/codegen-mips.h" |
6 | 6 |
7 #if V8_TARGET_ARCH_MIPS | 7 #if V8_TARGET_ARCH_MIPS |
8 | 8 |
9 #include "src/codegen.h" | 9 #include "src/codegen.h" |
10 #include "src/macro-assembler.h" | 10 #include "src/macro-assembler.h" |
(...skipping 1170 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1181 | 1181 |
1182 __ bind(&done); | 1182 __ bind(&done); |
1183 } | 1183 } |
1184 | 1184 |
1185 #ifdef DEBUG | 1185 #ifdef DEBUG |
1186 // nop(CODE_AGE_MARKER_NOP) | 1186 // nop(CODE_AGE_MARKER_NOP) |
1187 static const uint32_t kCodeAgePatchFirstInstruction = 0x00010180; | 1187 static const uint32_t kCodeAgePatchFirstInstruction = 0x00010180; |
1188 #endif | 1188 #endif |
1189 | 1189 |
1190 | 1190 |
1191 CodeAgingHelper::CodeAgingHelper() { | 1191 CodeAgingHelper::CodeAgingHelper(Isolate* isolate) { |
| 1192 USE(isolate); |
1192 DCHECK(young_sequence_.length() == kNoCodeAgeSequenceLength); | 1193 DCHECK(young_sequence_.length() == kNoCodeAgeSequenceLength); |
1193 // Since patcher is a large object, allocate it dynamically when needed, | 1194 // Since patcher is a large object, allocate it dynamically when needed, |
1194 // to avoid overloading the stack in stress conditions. | 1195 // to avoid overloading the stack in stress conditions. |
1195 // DONT_FLUSH is used because the CodeAgingHelper is initialized early in | 1196 // DONT_FLUSH is used because the CodeAgingHelper is initialized early in |
1196 // the process, before MIPS simulator ICache is setup. | 1197 // the process, before MIPS simulator ICache is setup. |
1197 base::SmartPointer<CodePatcher> patcher(new CodePatcher( | 1198 base::SmartPointer<CodePatcher> patcher(new CodePatcher( |
1198 young_sequence_.start(), young_sequence_.length() / Assembler::kInstrSize, | 1199 young_sequence_.start(), young_sequence_.length() / Assembler::kInstrSize, |
1199 CodePatcher::DONT_FLUSH)); | 1200 CodePatcher::DONT_FLUSH)); |
1200 PredictableCodeSizeScope scope(patcher->masm(), young_sequence_.length()); | 1201 PredictableCodeSizeScope scope(patcher->masm(), young_sequence_.length()); |
1201 patcher->masm()->Push(ra, fp, cp, a1); | 1202 patcher->masm()->Push(ra, fp, cp, a1); |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1259 } | 1260 } |
1260 } | 1261 } |
1261 | 1262 |
1262 | 1263 |
1263 #undef __ | 1264 #undef __ |
1264 | 1265 |
1265 } // namespace internal | 1266 } // namespace internal |
1266 } // namespace v8 | 1267 } // namespace v8 |
1267 | 1268 |
1268 #endif // V8_TARGET_ARCH_MIPS | 1269 #endif // V8_TARGET_ARCH_MIPS |
OLD | NEW |