JavaScriptCore:
2008-08-25 Kevin McCullough <kmccullough@apple.com>
Reviewed by Geoff, Tim and Mark.
<rdar://problem/6150623> JSProfiler: It would be nice if the profiles
in the console said what file and line number they came from
- Lay the foundation for getting line numbers and other data from the
JavaScript engine. With the cleanup in kjs/ExecState this is actually
a slight performance improvement.
* JavaScriptCore.exp: Export retrieveLastCaller() for WebCore.
* JavaScriptCore.xcodeproj/project.pbxproj:
* VM/Machine.cpp: Now Host and JS functions set a call frame on the
exec state, so this and the profiler code were pulled out of the
branches.
(KJS::Machine::privateExecute):
(KJS::Machine::retrieveLastCaller): This get's the lineNumber, sourceID
and sourceURL for the previously called function.
* VM/Machine.h:
* kjs/ExecState.cpp: Remove references to JSFunction since it's not used
anywhere.
* kjs/ExecState.h:
WebCore:
2008-08-22 Kevin McCullough <kmccullough@apple.com>
Reviewed by Geoff, Mark and Tim.
<rdar://problem/6150623> JSProfiler: It would be nice if the profiles
in the console said what file and line number they came from
- Lay the foundation for getting line numbers and other data from the
JavaScript engine.
* ForwardingHeaders/VM: Added.
* ForwardingHeaders/VM/Machine.h: Added.
* page/Console.cpp: Gather the line number and file information when
profileEnd has been called, but don't use it until didFinishProfiling is
called. We won't need to wait once we remove the profiler "zombie" mode
which this patch helps pave the foundation for.
(WebCore::Console::Console):
(WebCore::Console::profileEnd):
(WebCore::Console::finishedProfiling):
* page/Console.h:
* page/InspectorController.cpp: Modify calls to
addProfileMessageToConsole to satisfy the new arguments it takes.
(WebCore::InspectorController::finishedProfiling):
(WebCore::InspectorController::addProfile):
(WebCore::InspectorController::addProfileMessageToConsole):
(WebCore::InspectorController::finishedProfiling):
* page/InspectorController.h:
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@35918 268f45cc-cd09-0410-ab3c-d52691b4dbfc
13 files changed