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

Side by Side Diff: src/mips/assembler-mips-inl.h

Issue 967323002: Refactor BreakLocationIterator. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: static_cast instead Created 5 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/mips/assembler-mips.cc ('k') | src/mips/debug-mips.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 1
2 // Copyright (c) 1994-2006 Sun Microsystems Inc. 2 // Copyright (c) 1994-2006 Sun Microsystems Inc.
3 // All Rights Reserved. 3 // All Rights Reserved.
4 // 4 //
5 // Redistribution and use in source and binary forms, with or without 5 // Redistribution and use in source and binary forms, with or without
6 // modification, are permitted provided that the following conditions are 6 // modification, are permitted provided that the following conditions are
7 // met: 7 // met:
8 // 8 //
9 // - Redistributions of source code must retain the above copyright notice, 9 // - Redistributions of source code must retain the above copyright notice,
10 // this list of conditions and the following disclaimer. 10 // this list of conditions and the following disclaimer.
(...skipping 289 matching lines...) Expand 10 before | Expand all | Expand 10 after
300 Assembler::set_target_address_at(pc_ + Assembler::kInstrSize, 300 Assembler::set_target_address_at(pc_ + Assembler::kInstrSize,
301 host_, 301 host_,
302 stub->instruction_start()); 302 stub->instruction_start());
303 } 303 }
304 304
305 305
306 Address RelocInfo::call_address() { 306 Address RelocInfo::call_address() {
307 DCHECK((IsJSReturn(rmode()) && IsPatchedReturnSequence()) || 307 DCHECK((IsJSReturn(rmode()) && IsPatchedReturnSequence()) ||
308 (IsDebugBreakSlot(rmode()) && IsPatchedDebugBreakSlotSequence())); 308 (IsDebugBreakSlot(rmode()) && IsPatchedDebugBreakSlotSequence()));
309 // The pc_ offset of 0 assumes mips patched return sequence per 309 // The pc_ offset of 0 assumes mips patched return sequence per
310 // debug-mips.cc BreakLocationIterator::SetDebugBreakAtReturn(), or 310 // debug-mips.cc BreakLocation::SetDebugBreakAtReturn(), or
311 // debug break slot per BreakLocationIterator::SetDebugBreakAtSlot(). 311 // debug break slot per BreakLocation::SetDebugBreakAtSlot().
312 return Assembler::target_address_at(pc_, host_); 312 return Assembler::target_address_at(pc_, host_);
313 } 313 }
314 314
315 315
316 void RelocInfo::set_call_address(Address target) { 316 void RelocInfo::set_call_address(Address target) {
317 DCHECK((IsJSReturn(rmode()) && IsPatchedReturnSequence()) || 317 DCHECK((IsJSReturn(rmode()) && IsPatchedReturnSequence()) ||
318 (IsDebugBreakSlot(rmode()) && IsPatchedDebugBreakSlotSequence())); 318 (IsDebugBreakSlot(rmode()) && IsPatchedDebugBreakSlotSequence()));
319 // The pc_ offset of 0 assumes mips patched return sequence per 319 // The pc_ offset of 0 assumes mips patched return sequence per
320 // debug-mips.cc BreakLocationIterator::SetDebugBreakAtReturn(), or 320 // debug-mips.cc BreakLocation::SetDebugBreakAtReturn(), or
321 // debug break slot per BreakLocationIterator::SetDebugBreakAtSlot(). 321 // debug break slot per BreakLocation::SetDebugBreakAtSlot().
322 Assembler::set_target_address_at(pc_, host_, target); 322 Assembler::set_target_address_at(pc_, host_, target);
323 if (host() != NULL) { 323 if (host() != NULL) {
324 Object* target_code = Code::GetCodeFromTargetAddress(target); 324 Object* target_code = Code::GetCodeFromTargetAddress(target);
325 host()->GetHeap()->incremental_marking()->RecordWriteIntoCode( 325 host()->GetHeap()->incremental_marking()->RecordWriteIntoCode(
326 host(), this, HeapObject::cast(target_code)); 326 host(), this, HeapObject::cast(target_code));
327 } 327 }
328 } 328 }
329 329
330 330
331 Object* RelocInfo::call_object() { 331 Object* RelocInfo::call_object() {
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
446 } 446 }
447 *reinterpret_cast<Instr*>(pc_) = x; 447 *reinterpret_cast<Instr*>(pc_) = x;
448 pc_ += kInstrSize; 448 pc_ += kInstrSize;
449 CheckTrampolinePoolQuick(); 449 CheckTrampolinePoolQuick();
450 } 450 }
451 451
452 452
453 } } // namespace v8::internal 453 } } // namespace v8::internal
454 454
455 #endif // V8_MIPS_ASSEMBLER_MIPS_INL_H_ 455 #endif // V8_MIPS_ASSEMBLER_MIPS_INL_H_
OLDNEW
« no previous file with comments | « src/mips/assembler-mips.cc ('k') | src/mips/debug-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698