I think this:
|
for (let i = tick.s.length; i >= 0; i -= 2) { |
|
const code = log.code[tick.s[i]]; |
should be i = tick.s.length - 1, otherwise this is going to consistently access something out of bounds in the tick.s array. Possibly you want it to be tick.s.length - 2 in order to retain alignment with the alternation between C++ and JavaScript stacks?
Thanks for writing this, by the way!
I'm using this as reference for importing v8 logs into speedscope (https://github.com/jlfwong/speedscope)
I think this:
flamebearer/index.js
Lines 72 to 73 in a8d4d5c
should be
i = tick.s.length - 1, otherwise this is going to consistently access something out of bounds in thetick.sarray. Possibly you want it to betick.s.length - 2in order to retain alignment with the alternation between C++ and JavaScript stacks?Thanks for writing this, by the way!
I'm using this as reference for importing v8 logs into speedscope (https://github.com/jlfwong/speedscope)