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 2810653002: Add a host parameter to ObjectVisitor methods. (Closed)
Patch Set: rebase Created 3 years, 8 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/ia32/assembler-ia32-inl.h ('k') | src/mips64/assembler-mips64-inl.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 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 339 matching lines...) Expand 10 before | Expand all | Expand 10 after
350 Assembler::set_target_internal_reference_encoded_at(pc_, nullptr); 350 Assembler::set_target_internal_reference_encoded_at(pc_, nullptr);
351 } else { 351 } else {
352 Assembler::set_target_address_at(isolate, pc_, host_, NULL); 352 Assembler::set_target_address_at(isolate, pc_, host_, NULL);
353 } 353 }
354 } 354 }
355 355
356 template <typename ObjectVisitor> 356 template <typename ObjectVisitor>
357 void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) { 357 void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) {
358 RelocInfo::Mode mode = rmode(); 358 RelocInfo::Mode mode = rmode();
359 if (mode == RelocInfo::EMBEDDED_OBJECT) { 359 if (mode == RelocInfo::EMBEDDED_OBJECT) {
360 visitor->VisitEmbeddedPointer(this); 360 visitor->VisitEmbeddedPointer(host(), this);
361 } else if (RelocInfo::IsCodeTarget(mode)) { 361 } else if (RelocInfo::IsCodeTarget(mode)) {
362 visitor->VisitCodeTarget(this); 362 visitor->VisitCodeTarget(host(), this);
363 } else if (mode == RelocInfo::CELL) { 363 } else if (mode == RelocInfo::CELL) {
364 visitor->VisitCell(this); 364 visitor->VisitCellPointer(host(), this);
365 } else if (mode == RelocInfo::EXTERNAL_REFERENCE) { 365 } else if (mode == RelocInfo::EXTERNAL_REFERENCE) {
366 visitor->VisitExternalReference(this); 366 visitor->VisitExternalReference(host(), this);
367 } else if (mode == RelocInfo::INTERNAL_REFERENCE || 367 } else if (mode == RelocInfo::INTERNAL_REFERENCE ||
368 mode == RelocInfo::INTERNAL_REFERENCE_ENCODED) { 368 mode == RelocInfo::INTERNAL_REFERENCE_ENCODED) {
369 visitor->VisitInternalReference(this); 369 visitor->VisitInternalReference(host(), this);
370 } else if (RelocInfo::IsCodeAgeSequence(mode)) { 370 } else if (RelocInfo::IsCodeAgeSequence(mode)) {
371 visitor->VisitCodeAgeSequence(this); 371 visitor->VisitCodeAgeSequence(host(), this);
372 } else if (RelocInfo::IsDebugBreakSlot(mode) && 372 } else if (RelocInfo::IsDebugBreakSlot(mode) &&
373 IsPatchedDebugBreakSlotSequence()) { 373 IsPatchedDebugBreakSlotSequence()) {
374 visitor->VisitDebugTarget(this); 374 visitor->VisitDebugTarget(host(), this);
375 } else if (RelocInfo::IsRuntimeEntry(mode)) { 375 } else if (RelocInfo::IsRuntimeEntry(mode)) {
376 visitor->VisitRuntimeEntry(this); 376 visitor->VisitRuntimeEntry(host(), this);
377 } 377 }
378 } 378 }
379 379
380 380
381 template<typename StaticVisitor> 381 template<typename StaticVisitor>
382 void RelocInfo::Visit(Heap* heap) { 382 void RelocInfo::Visit(Heap* heap) {
383 RelocInfo::Mode mode = rmode(); 383 RelocInfo::Mode mode = rmode();
384 if (mode == RelocInfo::EMBEDDED_OBJECT) { 384 if (mode == RelocInfo::EMBEDDED_OBJECT) {
385 StaticVisitor::VisitEmbeddedPointer(heap, this); 385 StaticVisitor::VisitEmbeddedPointer(heap, this);
386 } else if (RelocInfo::IsCodeTarget(mode)) { 386 } else if (RelocInfo::IsCodeTarget(mode)) {
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
478 CheckBuffer(); 478 CheckBuffer();
479 } 479 }
480 EmitHelper(x, is_compact_branch); 480 EmitHelper(x, is_compact_branch);
481 } 481 }
482 482
483 483
484 } // namespace internal 484 } // namespace internal
485 } // namespace v8 485 } // namespace v8
486 486
487 #endif // V8_MIPS_ASSEMBLER_MIPS_INL_H_ 487 #endif // V8_MIPS_ASSEMBLER_MIPS_INL_H_
OLDNEW
« no previous file with comments | « src/ia32/assembler-ia32-inl.h ('k') | src/mips64/assembler-mips64-inl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698