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

Unified Diff: runtime/vm/assembler_x64.cc

Issue 2105383003: VM: Don't generate allocation stats code in product mode. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/assembler_mips.cc ('k') | runtime/vm/class_table.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/assembler_x64.cc
diff --git a/runtime/vm/assembler_x64.cc b/runtime/vm/assembler_x64.cc
index 67bc2379a7632291525a9f6c6f83d9d19b2a18f4..4df77b1e55b37920f1c627565275c8759d277443 100644
--- a/runtime/vm/assembler_x64.cc
+++ b/runtime/vm/assembler_x64.cc
@@ -3521,7 +3521,7 @@ void Assembler::TryAllocate(const Class& cls,
// If this allocation is traced, program will jump to failure path
// (i.e. the allocation stub) which will allocate the object and trace the
// allocation call site.
- MaybeTraceAllocation(cls.id(), failure, near_jump);
+ NOT_IN_PRODUCT(MaybeTraceAllocation(cls.id(), failure, near_jump));
const intptr_t instance_size = cls.instance_size();
Heap::Space space = Heap::SpaceForAllocation(cls.id());
movq(temp, Address(THR, Thread::heap_offset()));
@@ -3533,7 +3533,7 @@ void Assembler::TryAllocate(const Class& cls,
// Successfully allocated the object, now update top to point to
// next object start and store the class in the class field of object.
movq(Address(temp, Heap::TopOffset(space)), instance_reg);
- UpdateAllocationStats(cls.id(), space);
+ NOT_IN_PRODUCT(UpdateAllocationStats(cls.id(), space));
ASSERT(instance_size >= kHeapObjectTag);
AddImmediate(instance_reg, Immediate(kHeapObjectTag - instance_size));
uword tags = 0;
@@ -3560,7 +3560,7 @@ void Assembler::TryAllocateArray(intptr_t cid,
// If this allocation is traced, program will jump to failure path
// (i.e. the allocation stub) which will allocate the object and trace the
// allocation call site.
- MaybeTraceAllocation(cid, failure, near_jump);
+ NOT_IN_PRODUCT(MaybeTraceAllocation(cid, failure, near_jump));
Heap::Space space = Heap::SpaceForAllocation(cid);
movq(temp, Address(THR, Thread::heap_offset()));
movq(instance, Address(temp, Heap::TopOffset(space)));
@@ -3579,7 +3579,7 @@ void Assembler::TryAllocateArray(intptr_t cid,
// next object start and initialize the object.
movq(Address(temp, Heap::TopOffset(space)), end_address);
addq(instance, Immediate(kHeapObjectTag));
- UpdateAllocationStatsWithSize(cid, instance_size, space);
+ NOT_IN_PRODUCT(UpdateAllocationStatsWithSize(cid, instance_size, space));
// Initialize the tags.
// instance: new object start as a tagged pointer.
« no previous file with comments | « runtime/vm/assembler_mips.cc ('k') | runtime/vm/class_table.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698