JSON streaming calls JS::GetProfiledFrames: https://searchfox.org/mozilla-central/rev/e7d9a8749303b39dadcc0e18ea0d60a570a68145/tools/profiler/core/ProfileBufferEntry.cpp#674 However this seems bad because it can race with the main thread or worker thread updating the JIT code map. (JS::GetProfiledFrames should probably have a CHECK_THREAD(cx) to assert this.) For bug 1548775 I need a similar mechanism to run code on thread before streaming.
Bug 1549735 Comment 0 Edit History
Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.
JSON streaming calls JS::GetProfiledFrames: https://searchfox.org/mozilla-central/rev/e7d9a8749303b39dadcc0e18ea0d60a570a68145/tools/profiler/core/ProfileBufferEntry.cpp#674 However this seems bad because it can race with the main thread or DOM Worker threads updating the JIT code map. (JS::GetProfiledFrames should probably have a CHECK_THREAD(cx) to assert this.) For bug 1548775 I need a similar mechanism to run code on thread before streaming.
JSON streaming calls JS::GetProfiledFrames: https://searchfox.org/mozilla-central/rev/e7d9a8749303b39dadcc0e18ea0d60a570a68145/tools/profiler/core/ProfileBufferEntry.cpp#674 However this seems bad because it can race with the main thread or DOM Worker threads updating the JIT code map. (JS::GetProfiledFrames should probably have a CHECK_THREAD(cx) to assert this.) For bug 1548775 I need a similar mechanism to run code on-thread before streaming..