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

Side by Side Diff: src/mips64/assembler-mips64.cc

Issue 2045263002: [heap] Avoid the use of cells to point from code to new-space objects. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: The IsSmi check in mov(HeapObject) lets some tests fail. Created 4 years, 6 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/macro-assembler-mips.cc ('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 // Copyright (c) 1994-2006 Sun Microsystems Inc. 1 // Copyright (c) 1994-2006 Sun Microsystems Inc.
2 // All Rights Reserved. 2 // All Rights Reserved.
3 // 3 //
4 // Redistribution and use in source and binary forms, with or without 4 // Redistribution and use in source and binary forms, with or without
5 // modification, are permitted provided that the following conditions are 5 // modification, are permitted provided that the following conditions are
6 // met: 6 // met:
7 // 7 //
8 // - Redistributions of source code must retain the above copyright notice, 8 // - Redistributions of source code must retain the above copyright notice,
9 // this list of conditions and the following disclaimer. 9 // this list of conditions and the following disclaimer.
10 // 10 //
(...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after
197 // ----------------------------------------------------------------------------- 197 // -----------------------------------------------------------------------------
198 // Implementation of Operand and MemOperand. 198 // Implementation of Operand and MemOperand.
199 // See assembler-mips-inl.h for inlined constructors. 199 // See assembler-mips-inl.h for inlined constructors.
200 200
201 Operand::Operand(Handle<Object> handle) { 201 Operand::Operand(Handle<Object> handle) {
202 AllowDeferredHandleDereference using_raw_address; 202 AllowDeferredHandleDereference using_raw_address;
203 rm_ = no_reg; 203 rm_ = no_reg;
204 // Verify all Objects referred by code are NOT in new space. 204 // Verify all Objects referred by code are NOT in new space.
205 Object* obj = *handle; 205 Object* obj = *handle;
206 if (obj->IsHeapObject()) { 206 if (obj->IsHeapObject()) {
207 DCHECK(!HeapObject::cast(obj)->GetHeap()->InNewSpace(obj));
208 imm64_ = reinterpret_cast<intptr_t>(handle.location()); 207 imm64_ = reinterpret_cast<intptr_t>(handle.location());
209 rmode_ = RelocInfo::EMBEDDED_OBJECT; 208 rmode_ = RelocInfo::EMBEDDED_OBJECT;
210 } else { 209 } else {
211 // No relocation needed. 210 // No relocation needed.
212 imm64_ = reinterpret_cast<intptr_t>(obj); 211 imm64_ = reinterpret_cast<intptr_t>(obj);
213 rmode_ = RelocInfo::NONE64; 212 rmode_ = RelocInfo::NONE64;
214 } 213 }
215 } 214 }
216 215
217 216
(...skipping 3203 matching lines...) Expand 10 before | Expand all | Expand 10 after
3421 if (icache_flush_mode != SKIP_ICACHE_FLUSH) { 3420 if (icache_flush_mode != SKIP_ICACHE_FLUSH) {
3422 Assembler::FlushICache(isolate, pc, 4 * Assembler::kInstrSize); 3421 Assembler::FlushICache(isolate, pc, 4 * Assembler::kInstrSize);
3423 } 3422 }
3424 } 3423 }
3425 3424
3426 3425
3427 } // namespace internal 3426 } // namespace internal
3428 } // namespace v8 3427 } // namespace v8
3429 3428
3430 #endif // V8_TARGET_ARCH_MIPS64 3429 #endif // V8_TARGET_ARCH_MIPS64
OLDNEW
« no previous file with comments | « src/mips/macro-assembler-mips.cc ('k') | src/mips64/assembler-mips64-inl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698