summaryrefslogtreecommitdiff
path: root/Source/JavaScriptCore/jsc.cpp
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@nokia.com>2012-07-23 09:28:44 +0200
committerSimon Hausmann <simon.hausmann@nokia.com>2012-07-23 09:28:44 +0200
commit815f1ed417bd26fbe2abbdf20ac5d3423b30796c (patch)
tree923c9a9e2834ccab60f5caecfb8f0ac410c1dd9e /Source/JavaScriptCore/jsc.cpp
parentb4ad5d9d2b96baacd0180ead50de5195ca78af2d (diff)
downloadqtwebkit-815f1ed417bd26fbe2abbdf20ac5d3423b30796c.tar.gz
Imported WebKit commit e65cbc5b6ac32627c797e7fc7f46eb7794410c92 (http://svn.webkit.org/repository/webkit/trunk@123308)
New snapshot with better configure tests
Diffstat (limited to 'Source/JavaScriptCore/jsc.cpp')
-rw-r--r--Source/JavaScriptCore/jsc.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/Source/JavaScriptCore/jsc.cpp b/Source/JavaScriptCore/jsc.cpp
index 5f3dbdb99..00ad5d3b2 100644
--- a/Source/JavaScriptCore/jsc.cpp
+++ b/Source/JavaScriptCore/jsc.cpp
@@ -88,6 +88,7 @@ static EncodedJSValue JSC_HOST_CALL functionJSCStack(ExecState*);
static EncodedJSValue JSC_HOST_CALL functionGC(ExecState*);
#ifndef NDEBUG
static EncodedJSValue JSC_HOST_CALL functionReleaseExecutableMemory(ExecState*);
+static EncodedJSValue JSC_HOST_CALL functionDumpCallFrame(ExecState*);
#endif
static EncodedJSValue JSC_HOST_CALL functionVersion(ExecState*);
static EncodedJSValue JSC_HOST_CALL functionRun(ExecState*);
@@ -194,6 +195,7 @@ protected:
addFunction(globalData, "quit", functionQuit, 0);
addFunction(globalData, "gc", functionGC, 0);
#ifndef NDEBUG
+ addFunction(globalData, "dumpCallFrame", functionDumpCallFrame, 0);
addFunction(globalData, "releaseExecutableMemory", functionReleaseExecutableMemory, 0);
#endif
addFunction(globalData, "version", functionVersion, 1);
@@ -281,6 +283,15 @@ EncodedJSValue JSC_HOST_CALL functionPrint(ExecState* exec)
return JSValue::encode(jsUndefined());
}
+#ifndef NDEBUG
+EncodedJSValue JSC_HOST_CALL functionDumpCallFrame(ExecState* exec)
+{
+ if (!exec->callerFrame()->hasHostCallFrameFlag())
+ exec->globalData().interpreter->dumpCallFrame(exec->callerFrame());
+ return JSValue::encode(jsUndefined());
+}
+#endif
+
EncodedJSValue JSC_HOST_CALL functionDebug(ExecState* exec)
{
fprintf(stderr, "--> %s\n", exec->argument(0).toString(exec)->value(exec).utf8().data());