| 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/v8.h" | 5 #include "src/v8.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 1186 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1197 young_sequence_.length() / Assembler::kInstrSize, | 1197 young_sequence_.length() / Assembler::kInstrSize, |
| 1198 CodePatcher::DONT_FLUSH)); | 1198 CodePatcher::DONT_FLUSH)); |
| 1199 PredictableCodeSizeScope scope(patcher->masm(), young_sequence_.length()); | 1199 PredictableCodeSizeScope scope(patcher->masm(), young_sequence_.length()); |
| 1200 patcher->masm()->Push(ra, fp, cp, a1); | 1200 patcher->masm()->Push(ra, fp, cp, a1); |
| 1201 patcher->masm()->nop(Assembler::CODE_AGE_SEQUENCE_NOP); | 1201 patcher->masm()->nop(Assembler::CODE_AGE_SEQUENCE_NOP); |
| 1202 patcher->masm()->Addu( | 1202 patcher->masm()->Addu( |
| 1203 fp, sp, Operand(StandardFrameConstants::kFixedFrameSizeFromFp)); | 1203 fp, sp, Operand(StandardFrameConstants::kFixedFrameSizeFromFp)); |
| 1204 } | 1204 } |
| 1205 | 1205 |
| 1206 | 1206 |
| 1207 #ifdef DEBUG | 1207 #if DCHECK_IS_ON |
| 1208 bool CodeAgingHelper::IsOld(byte* candidate) const { | 1208 bool CodeAgingHelper::IsOld(byte* candidate) const { |
| 1209 return Memory::uint32_at(candidate) == kCodeAgePatchFirstInstruction; | 1209 return Memory::uint32_at(candidate) == kCodeAgePatchFirstInstruction; |
| 1210 } | 1210 } |
| 1211 #endif | 1211 #endif |
| 1212 | 1212 |
| 1213 | 1213 |
| 1214 bool Code::IsYoungSequence(Isolate* isolate, byte* sequence) { | 1214 bool Code::IsYoungSequence(Isolate* isolate, byte* sequence) { |
| 1215 bool result = isolate->code_aging_helper()->IsYoung(sequence); | 1215 bool result = isolate->code_aging_helper()->IsYoung(sequence); |
| 1216 DCHECK(result || isolate->code_aging_helper()->IsOld(sequence)); | 1216 DCHECK(result || isolate->code_aging_helper()->IsOld(sequence)); |
| 1217 return result; | 1217 return result; |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1257 patcher.masm()->nop(); // Pad the empty space. | 1257 patcher.masm()->nop(); // Pad the empty space. |
| 1258 } | 1258 } |
| 1259 } | 1259 } |
| 1260 | 1260 |
| 1261 | 1261 |
| 1262 #undef __ | 1262 #undef __ |
| 1263 | 1263 |
| 1264 } } // namespace v8::internal | 1264 } } // namespace v8::internal |
| 1265 | 1265 |
| 1266 #endif // V8_TARGET_ARCH_MIPS | 1266 #endif // V8_TARGET_ARCH_MIPS |
| OLD | NEW |