Index: src/perf-jit.cc |
diff --git a/src/perf-jit.cc b/src/perf-jit.cc |
index 5e7fd4cf4ac09991882af58175e52b1d71243baf..3f30e384674fb5d7ee05b5621824290244d62ef3 100644 |
--- a/src/perf-jit.cc |
+++ b/src/perf-jit.cc |
@@ -83,7 +83,8 @@ void PerfJitLogger::LogRecordedBuffer(Code* code, SharedFunctionInfo*, |
const char* code_name = name; |
uint8_t* code_pointer = reinterpret_cast<uint8_t*>(code->instruction_start()); |
- uint32_t code_size = code->instruction_size(); |
+ uint32_t code_size = code->is_crankshafted() ? code->safepoint_table_offset() |
+ : code->instruction_size(); |
static const char string_terminator[] = "\0"; |