Skip to content

Commit

Permalink
Bug 895015 - OdinMonkey: make asm.js entries show up builtin FF profi…
Browse files Browse the repository at this point in the history
…ler (r=bbouvier)

--HG--
extra : rebase_source : 0f682fde81ef8e9dc89f0b9ad76e928d24358394
  • Loading branch information
Luke Wagner committed Jul 17, 2013
1 parent 2671098 commit 822ad10
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
6 changes: 5 additions & 1 deletion js/src/ion/AsmJSLink.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -261,8 +261,12 @@ AsmJSActivation::AsmJSActivation(JSContext *cx, AsmJSModule &module)
resumePC_(NULL)
{
if (cx->runtime()->spsProfiler.enabled()) {
// Use a profiler string that matches jsMatch regex in
// browser/devtools/profiler/cleopatra/js/parserWorker.js.
// (For now use a single static string to avoid further slowing down
// calls into asm.js.)
profiler_ = &cx->runtime()->spsProfiler;
profiler_->enterNative("asm.js code", this);
profiler_->enterNative("asm.js code :0", this);
}

prev_ = cx_->runtime()->mainThread.asmJSActivationStack_;
Expand Down
2 changes: 2 additions & 0 deletions js/src/vm/SPSProfiler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,8 @@ SPSProfiler::pop()
const char*
SPSProfiler::allocProfileString(JSContext *cx, JSScript *script, JSFunction *maybeFun)
{
// Note: this profiler string is regexp-matched by
// browser/devtools/profiler/cleopatra/js/parserWorker.js.
DebugOnly<uint64_t> gcBefore = cx->runtime()->gcNumber;
StringBuffer buf(cx);
bool hasAtom = maybeFun != NULL && maybeFun->displayAtom() != NULL;
Expand Down

0 comments on commit 822ad10

Please sign in to comment.