Index: src/objects-inl.h |
diff --git a/src/objects-inl.h b/src/objects-inl.h |
index c49bfc8b9e74a11346820590dc2a4fa0ecfa7384..2123fa6e128154631a9d83a407420fcea173d336 100644 |
--- a/src/objects-inl.h |
+++ b/src/objects-inl.h |
@@ -4777,9 +4777,10 @@ int Code::profiler_ticks() { |
void Code::set_profiler_ticks(int ticks) { |
- DCHECK_EQ(FUNCTION, kind()); |
DCHECK(ticks < 256); |
- WRITE_BYTE_FIELD(this, kProfilerTicksOffset, ticks); |
+ if (kind() == FUNCTION) { |
+ WRITE_BYTE_FIELD(this, kProfilerTicksOffset, ticks); |
+ } |
} |