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

Side by Side Diff: src/x64/macro-assembler-x64.cc

Issue 1844283002: [heap] Remove store buffer top from roots (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 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/snapshot/startup-serializer.cc ('k') | tools/gyp/v8.gyp » ('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 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 #if V8_TARGET_ARCH_X64 5 #if V8_TARGET_ARCH_X64
6 6
7 #include "src/base/bits.h" 7 #include "src/base/bits.h"
8 #include "src/base/division-by-constant.h" 8 #include "src/base/division-by-constant.h"
9 #include "src/bootstrapper.h" 9 #include "src/bootstrapper.h"
10 #include "src/codegen.h" 10 #include "src/codegen.h"
(...skipping 197 matching lines...) Expand 10 before | Expand all | Expand 10 after
208 Register scratch, 208 Register scratch,
209 SaveFPRegsMode save_fp, 209 SaveFPRegsMode save_fp,
210 RememberedSetFinalAction and_then) { 210 RememberedSetFinalAction and_then) {
211 if (emit_debug_code()) { 211 if (emit_debug_code()) {
212 Label ok; 212 Label ok;
213 JumpIfNotInNewSpace(object, scratch, &ok, Label::kNear); 213 JumpIfNotInNewSpace(object, scratch, &ok, Label::kNear);
214 int3(); 214 int3();
215 bind(&ok); 215 bind(&ok);
216 } 216 }
217 // Load store buffer top. 217 // Load store buffer top.
218 LoadRoot(scratch, Heap::kStoreBufferTopRootIndex); 218 ExternalReference store_buffer =
219 ExternalReference::store_buffer_top(isolate());
220 movp(scratch, ExternalOperand(store_buffer));
219 // Store pointer to buffer. 221 // Store pointer to buffer.
220 movp(Operand(scratch, 0), addr); 222 movp(Operand(scratch, 0), addr);
221 // Increment buffer top. 223 // Increment buffer top.
222 addp(scratch, Immediate(kPointerSize)); 224 addp(scratch, Immediate(kPointerSize));
223 // Write back new top of buffer. 225 // Write back new top of buffer.
224 StoreRoot(scratch, Heap::kStoreBufferTopRootIndex); 226 movp(ExternalOperand(store_buffer), scratch);
225 // Call stub on end of buffer. 227 // Call stub on end of buffer.
226 Label done; 228 Label done;
227 // Check for end of buffer. 229 // Check for end of buffer.
228 testp(scratch, Immediate(StoreBuffer::kStoreBufferOverflowBit)); 230 testp(scratch, Immediate(StoreBuffer::kStoreBufferOverflowBit));
229 if (and_then == kReturnAtEnd) { 231 if (and_then == kReturnAtEnd) {
230 Label buffer_overflowed; 232 Label buffer_overflowed;
231 j(not_equal, &buffer_overflowed, Label::kNear); 233 j(not_equal, &buffer_overflowed, Label::kNear);
232 ret(0); 234 ret(0);
233 bind(&buffer_overflowed); 235 bind(&buffer_overflowed);
234 } else { 236 } else {
(...skipping 5446 matching lines...) Expand 10 before | Expand all | Expand 10 after
5681 movl(rax, dividend); 5683 movl(rax, dividend);
5682 shrl(rax, Immediate(31)); 5684 shrl(rax, Immediate(31));
5683 addl(rdx, rax); 5685 addl(rdx, rax);
5684 } 5686 }
5685 5687
5686 5688
5687 } // namespace internal 5689 } // namespace internal
5688 } // namespace v8 5690 } // namespace v8
5689 5691
5690 #endif // V8_TARGET_ARCH_X64 5692 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/snapshot/startup-serializer.cc ('k') | tools/gyp/v8.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698