diff options
author | Simon Hausmann <simon.hausmann@digia.com> | 2012-11-30 16:58:06 +0100 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@digia.com> | 2012-11-30 17:03:09 +0100 |
commit | 32ea33253afbbdefd2680aa95ab5f57455272ae7 (patch) | |
tree | 2389569585b666c310fbb36d3fb8e6ab94462967 /Source/JavaScriptCore/jit | |
parent | 41c25f231cbca1babc445187283524cc6c751c71 (diff) | |
download | qtwebkit-32ea33253afbbdefd2680aa95ab5f57455272ae7.tar.gz |
Imported WebKit commit 6a4a1d32e1d779548c726c4826cba9d69eb87601 (http://svn.webkit.org/repository/webkit/trunk@136242)
Final import for the Qt 5.x series that implements the QtWebKit / QtWebKitWidgets split
Extra fixes will be cherry-picked.
Change-Id: I844f1ebb99c6d6b75db31d6538c2acd628e79681
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Diffstat (limited to 'Source/JavaScriptCore/jit')
-rw-r--r-- | Source/JavaScriptCore/jit/JITCode.cpp | 58 | ||||
-rw-r--r-- | Source/JavaScriptCore/jit/JITCode.h | 13 | ||||
-rw-r--r-- | Source/JavaScriptCore/jit/JITDisassembler.cpp | 5 | ||||
-rw-r--r-- | Source/JavaScriptCore/jit/JITPropertyAccess.cpp | 46 | ||||
-rw-r--r-- | Source/JavaScriptCore/jit/JITPropertyAccess32_64.cpp | 41 | ||||
-rw-r--r-- | Source/JavaScriptCore/jit/JITStubs.cpp | 34 |
6 files changed, 135 insertions, 62 deletions
diff --git a/Source/JavaScriptCore/jit/JITCode.cpp b/Source/JavaScriptCore/jit/JITCode.cpp new file mode 100644 index 000000000..5cfa6304b --- /dev/null +++ b/Source/JavaScriptCore/jit/JITCode.cpp @@ -0,0 +1,58 @@ +/* + * Copyright (C) 2008, 2012 Apple Inc. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR + * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY + * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "config.h" +#include "JITCode.h" + +#include <wtf/PrintStream.h> + +namespace WTF { + +void printInternal(PrintStream& out, JSC::JITCode::JITType type) +{ + switch (type) { + case JSC::JITCode::None: + out.print("None"); + return; + case JSC::JITCode::HostCallThunk: + out.print("Host"); + return; + case JSC::JITCode::InterpreterThunk: + out.print("LLInt"); + return; + case JSC::JITCode::BaselineJIT: + out.print("Baseline"); + return; + case JSC::JITCode::DFGJIT: + out.print("DFG"); + return; + default: + CRASH(); + return; + } +} + +} // namespace WTF + diff --git a/Source/JavaScriptCore/jit/JITCode.h b/Source/JavaScriptCore/jit/JITCode.h index 93fa88a23..0929397ee 100644 --- a/Source/JavaScriptCore/jit/JITCode.h +++ b/Source/JavaScriptCore/jit/JITCode.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008 Apple Inc. All rights reserved. + * Copyright (C) 2008, 2012 Apple Inc. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -157,7 +157,7 @@ namespace JSC { return m_ref.executableMemory(); } - JITType jitType() + JITType jitType() const { return m_jitType; } @@ -187,6 +187,13 @@ namespace JSC { #endif // ENABLE(JIT) || ENABLE(LLINT) }; -}; +} // namespace JSC + +namespace WTF { + +class PrintStream; +void printInternal(PrintStream&, JSC::JITCode::JITType); + +} // namespace WTF #endif diff --git a/Source/JavaScriptCore/jit/JITDisassembler.cpp b/Source/JavaScriptCore/jit/JITDisassembler.cpp index 0ec72e205..eaef844bf 100644 --- a/Source/JavaScriptCore/jit/JITDisassembler.cpp +++ b/Source/JavaScriptCore/jit/JITDisassembler.cpp @@ -29,6 +29,7 @@ #if ENABLE(JIT) #include "CodeBlock.h" +#include "CodeBlockWithJITType.h" #include "JIT.h" namespace JSC { @@ -46,7 +47,7 @@ JITDisassembler::~JITDisassembler() void JITDisassembler::dump(PrintStream& out, LinkBuffer& linkBuffer) { - out.print("Baseline JIT code for CodeBlock ", RawPointer(m_codeBlock), ", instruction count = ", m_codeBlock->instructionCount(), "\n"); + out.print("Baseline JIT code for ", CodeBlockWithJITType(m_codeBlock, JITCode::BaselineJIT), ", instruction count = ", m_codeBlock->instructionCount(), "\n"); out.print(" Code at [", RawPointer(linkBuffer.debugAddress()), ", ", RawPointer(static_cast<char*>(linkBuffer.debugAddress()) + linkBuffer.debugSize()), "):\n"); dumpDisassembly(out, linkBuffer, m_startOfCode, m_labelForBytecodeIndexInMainPath[0]); @@ -78,7 +79,7 @@ void JITDisassembler::dumpForInstructions(PrintStream& out, LinkBuffer& linkBuff continue; } out.print(prefix); - m_codeBlock->dump(i); + m_codeBlock->dumpBytecode(i); for (unsigned nextIndex = i + 1; ; nextIndex++) { if (nextIndex >= labels.size()) { dumpDisassembly(out, linkBuffer, labels[i], endLabel); diff --git a/Source/JavaScriptCore/jit/JITPropertyAccess.cpp b/Source/JavaScriptCore/jit/JITPropertyAccess.cpp index 57a5685eb..e377c8adb 100644 --- a/Source/JavaScriptCore/jit/JITPropertyAccess.cpp +++ b/Source/JavaScriptCore/jit/JITPropertyAccess.cpp @@ -42,6 +42,7 @@ #include "RepatchBuffer.h" #include "ResultType.h" #include "SamplingTool.h" +#include <wtf/StringPrintStream.h> #ifndef NDEBUG #include <stdio.h> @@ -746,8 +747,8 @@ void JIT::privateCompilePutByIdTransition(StructureStubInfo* stubInfo, Structure stubInfo->stubRoutine = createJITStubRoutine( FINALIZE_CODE( patchBuffer, - ("Baseline put_by_id transition for CodeBlock %p, return point %p", - m_codeBlock, returnAddress.value())), + ("Baseline put_by_id transition for %s, return point %p", + toCString(*m_codeBlock).data(), returnAddress.value())), *m_globalData, m_codeBlock->ownerExecutable(), willNeedStorageRealloc, @@ -815,9 +816,10 @@ void JIT::privateCompilePatchGetArrayLength(ReturnAddressPtr returnAddress) // Track the stub we have created so that it will be deleted later. stubInfo->stubRoutine = FINALIZE_CODE_FOR_STUB( patchBuffer, - ("Basline JIT get_by_id array length stub for CodeBlock %p, return point %p", - m_codeBlock, stubInfo->hotPathBegin.labelAtOffset( - stubInfo->patch.baseline.u.get.putResult).executableAddress())); + ("Basline JIT get_by_id array length stub for %s, return point %p", + toCString(*m_codeBlock).data(), + stubInfo->hotPathBegin.labelAtOffset( + stubInfo->patch.baseline.u.get.putResult).executableAddress())); // Finally patch the jump to slow case back in the hot path to jump here instead. CodeLocationJump jumpLocation = stubInfo->hotPathBegin.jumpAtOffset(stubInfo->patch.baseline.u.get.structureCheck); @@ -883,9 +885,9 @@ void JIT::privateCompileGetByIdProto(StructureStubInfo* stubInfo, Structure* str stubInfo->stubRoutine = createJITStubRoutine( FINALIZE_CODE( patchBuffer, - ("Baseline JIT get_by_id proto stub for CodeBlock %p, return point %p", - m_codeBlock, stubInfo->hotPathBegin.labelAtOffset( - stubInfo->patch.baseline.u.get.putResult).executableAddress())), + ("Baseline JIT get_by_id proto stub for %s, return point %p", + toCString(*m_codeBlock).data(), stubInfo->hotPathBegin.labelAtOffset( + stubInfo->patch.baseline.u.get.putResult).executableAddress())), *m_globalData, m_codeBlock->ownerExecutable(), needsStubLink); @@ -948,9 +950,9 @@ void JIT::privateCompileGetByIdSelfList(StructureStubInfo* stubInfo, Polymorphic RefPtr<JITStubRoutine> stubCode = createJITStubRoutine( FINALIZE_CODE( patchBuffer, - ("Baseline JIT get_by_id list stub for CodeBlock %p, return point %p", - m_codeBlock, stubInfo->hotPathBegin.labelAtOffset( - stubInfo->patch.baseline.u.get.putResult).executableAddress())), + ("Baseline JIT get_by_id list stub for %s, return point %p", + toCString(*m_codeBlock).data(), stubInfo->hotPathBegin.labelAtOffset( + stubInfo->patch.baseline.u.get.putResult).executableAddress())), *m_globalData, m_codeBlock->ownerExecutable(), needsStubLink); @@ -1022,9 +1024,9 @@ void JIT::privateCompileGetByIdProtoList(StructureStubInfo* stubInfo, Polymorphi RefPtr<JITStubRoutine> stubCode = createJITStubRoutine( FINALIZE_CODE( patchBuffer, - ("Baseline JIT get_by_id proto list stub for CodeBlock %p, return point %p", - m_codeBlock, stubInfo->hotPathBegin.labelAtOffset( - stubInfo->patch.baseline.u.get.putResult).executableAddress())), + ("Baseline JIT get_by_id proto list stub for %s, return point %p", + toCString(*m_codeBlock).data(), stubInfo->hotPathBegin.labelAtOffset( + stubInfo->patch.baseline.u.get.putResult).executableAddress())), *m_globalData, m_codeBlock->ownerExecutable(), needsStubLink); @@ -1099,9 +1101,9 @@ void JIT::privateCompileGetByIdChainList(StructureStubInfo* stubInfo, Polymorphi RefPtr<JITStubRoutine> stubRoutine = createJITStubRoutine( FINALIZE_CODE( patchBuffer, - ("Baseline JIT get_by_id chain list stub for CodeBlock %p, return point %p", - m_codeBlock, stubInfo->hotPathBegin.labelAtOffset( - stubInfo->patch.baseline.u.get.putResult).executableAddress())), + ("Baseline JIT get_by_id chain list stub for %s, return point %p", + toCString(*m_codeBlock).data(), stubInfo->hotPathBegin.labelAtOffset( + stubInfo->patch.baseline.u.get.putResult).executableAddress())), *m_globalData, m_codeBlock->ownerExecutable(), needsStubLink); @@ -1174,9 +1176,9 @@ void JIT::privateCompileGetByIdChain(StructureStubInfo* stubInfo, Structure* str RefPtr<JITStubRoutine> stubRoutine = createJITStubRoutine( FINALIZE_CODE( patchBuffer, - ("Baseline JIT get_by_id chain stub for CodeBlock %p, return point %p", - m_codeBlock, stubInfo->hotPathBegin.labelAtOffset( - stubInfo->patch.baseline.u.get.putResult).executableAddress())), + ("Baseline JIT get_by_id chain stub for %s, return point %p", + toCString(*m_codeBlock).data(), stubInfo->hotPathBegin.labelAtOffset( + stubInfo->patch.baseline.u.get.putResult).executableAddress())), *m_globalData, m_codeBlock->ownerExecutable(), needsStubLink); @@ -1428,7 +1430,7 @@ void JIT::privateCompileGetByVal(ByValInfo* byValInfo, ReturnAddressPtr returnAd byValInfo->stubRoutine = FINALIZE_CODE_FOR_STUB( patchBuffer, - ("Baseline get_by_val stub for CodeBlock %p, return point %p", m_codeBlock, returnAddress.value())); + ("Baseline get_by_val stub for %s, return point %p", toCString(*m_codeBlock).data(), returnAddress.value())); RepatchBuffer repatchBuffer(m_codeBlock); repatchBuffer.relink(byValInfo->badTypeJump, CodeLocationLabel(byValInfo->stubRoutine->code().code())); @@ -1498,7 +1500,7 @@ void JIT::privateCompilePutByVal(ByValInfo* byValInfo, ReturnAddressPtr returnAd byValInfo->stubRoutine = FINALIZE_CODE_FOR_STUB( patchBuffer, - ("Baseline put_by_val stub for CodeBlock %p, return point %p", m_codeBlock, returnAddress.value())); + ("Baseline put_by_val stub for %s, return point %p", toCString(*m_codeBlock).data(), returnAddress.value())); RepatchBuffer repatchBuffer(m_codeBlock); repatchBuffer.relink(byValInfo->badTypeJump, CodeLocationLabel(byValInfo->stubRoutine->code().code())); diff --git a/Source/JavaScriptCore/jit/JITPropertyAccess32_64.cpp b/Source/JavaScriptCore/jit/JITPropertyAccess32_64.cpp index be146a402..391dd1d8c 100644 --- a/Source/JavaScriptCore/jit/JITPropertyAccess32_64.cpp +++ b/Source/JavaScriptCore/jit/JITPropertyAccess32_64.cpp @@ -42,6 +42,7 @@ #include "RepatchBuffer.h" #include "ResultType.h" #include "SamplingTool.h" +#include <wtf/StringPrintStream.h> #ifndef NDEBUG #include <stdio.h> @@ -704,8 +705,8 @@ void JIT::privateCompilePutByIdTransition(StructureStubInfo* stubInfo, Structure stubInfo->stubRoutine = createJITStubRoutine( FINALIZE_CODE( patchBuffer, - ("Baseline put_by_id transition stub for CodeBlock %p, return point %p", - m_codeBlock, returnAddress.value())), + ("Baseline put_by_id transition stub for %s, return point %p", + toCString(*m_codeBlock).data(), returnAddress.value())), *m_globalData, m_codeBlock->ownerExecutable(), willNeedStorageRealloc, @@ -778,9 +779,9 @@ void JIT::privateCompilePatchGetArrayLength(ReturnAddressPtr returnAddress) // Track the stub we have created so that it will be deleted later. stubInfo->stubRoutine = FINALIZE_CODE_FOR_STUB( patchBuffer, - ("Baseline get_by_id array length stub for CodeBlock %p, return point %p", - m_codeBlock, stubInfo->hotPathBegin.labelAtOffset( - stubInfo->patch.baseline.u.get.putResult).executableAddress())); + ("Baseline get_by_id array length stub for %s, return point %p", + toCString(*m_codeBlock).data(), stubInfo->hotPathBegin.labelAtOffset( + stubInfo->patch.baseline.u.get.putResult).executableAddress())); // Finally patch the jump to slow case back in the hot path to jump here instead. CodeLocationJump jumpLocation = stubInfo->hotPathBegin.jumpAtOffset(stubInfo->patch.baseline.u.get.structureCheck); @@ -849,9 +850,9 @@ void JIT::privateCompileGetByIdProto(StructureStubInfo* stubInfo, Structure* str stubInfo->stubRoutine = createJITStubRoutine( FINALIZE_CODE( patchBuffer, - ("Baseline get_by_id proto stub for CodeBlock %p, return point %p", - m_codeBlock, stubInfo->hotPathBegin.labelAtOffset( - stubInfo->patch.baseline.u.get.putResult).executableAddress())), + ("Baseline get_by_id proto stub for %s, return point %p", + toCString(*m_codeBlock).data(), stubInfo->hotPathBegin.labelAtOffset( + stubInfo->patch.baseline.u.get.putResult).executableAddress())), *m_globalData, m_codeBlock->ownerExecutable(), needsStubLink); @@ -915,9 +916,9 @@ void JIT::privateCompileGetByIdSelfList(StructureStubInfo* stubInfo, Polymorphic RefPtr<JITStubRoutine> stubRoutine = createJITStubRoutine( FINALIZE_CODE( patchBuffer, - ("Baseline get_by_id self list stub for CodeBlock %p, return point %p", - m_codeBlock, stubInfo->hotPathBegin.labelAtOffset( - stubInfo->patch.baseline.u.get.putResult).executableAddress())), + ("Baseline get_by_id self list stub for %s, return point %p", + toCString(*m_codeBlock).data(), stubInfo->hotPathBegin.labelAtOffset( + stubInfo->patch.baseline.u.get.putResult).executableAddress())), *m_globalData, m_codeBlock->ownerExecutable(), needsStubLink); @@ -988,9 +989,9 @@ void JIT::privateCompileGetByIdProtoList(StructureStubInfo* stubInfo, Polymorphi RefPtr<JITStubRoutine> stubRoutine = createJITStubRoutine( FINALIZE_CODE( patchBuffer, - ("Baseline get_by_id proto list stub for CodeBlock %p, return point %p", - m_codeBlock, stubInfo->hotPathBegin.labelAtOffset( - stubInfo->patch.baseline.u.get.putResult).executableAddress())), + ("Baseline get_by_id proto list stub for %s, return point %p", + toCString(*m_codeBlock).data(), stubInfo->hotPathBegin.labelAtOffset( + stubInfo->patch.baseline.u.get.putResult).executableAddress())), *m_globalData, m_codeBlock->ownerExecutable(), needsStubLink); @@ -1066,9 +1067,9 @@ void JIT::privateCompileGetByIdChainList(StructureStubInfo* stubInfo, Polymorphi RefPtr<JITStubRoutine> stubRoutine = createJITStubRoutine( FINALIZE_CODE( patchBuffer, - ("Baseline get_by_id chain list stub for CodeBlock %p, return point %p", - m_codeBlock, stubInfo->hotPathBegin.labelAtOffset( - stubInfo->patch.baseline.u.get.putResult).executableAddress())), + ("Baseline get_by_id chain list stub for %s, return point %p", + toCString(*m_codeBlock).data(), stubInfo->hotPathBegin.labelAtOffset( + stubInfo->patch.baseline.u.get.putResult).executableAddress())), *m_globalData, m_codeBlock->ownerExecutable(), needsStubLink); @@ -1140,9 +1141,9 @@ void JIT::privateCompileGetByIdChain(StructureStubInfo* stubInfo, Structure* str RefPtr<JITStubRoutine> stubRoutine = createJITStubRoutine( FINALIZE_CODE( patchBuffer, - ("Baseline get_by_id chain stub for CodeBlock %p, return point %p", - m_codeBlock, stubInfo->hotPathBegin.labelAtOffset( - stubInfo->patch.baseline.u.get.putResult).executableAddress())), + ("Baseline get_by_id chain stub for %s, return point %p", + toCString(*m_codeBlock).data(), stubInfo->hotPathBegin.labelAtOffset( + stubInfo->patch.baseline.u.get.putResult).executableAddress())), *m_globalData, m_codeBlock->ownerExecutable(), needsStubLink); diff --git a/Source/JavaScriptCore/jit/JITStubs.cpp b/Source/JavaScriptCore/jit/JITStubs.cpp index 760ffd429..f47ac08ef 100644 --- a/Source/JavaScriptCore/jit/JITStubs.cpp +++ b/Source/JavaScriptCore/jit/JITStubs.cpp @@ -1808,12 +1808,16 @@ DEFINE_STUB_FUNCTION(void, optimize) unsigned bytecodeIndex = stackFrame.args[0].int32(); #if ENABLE(JIT_VERBOSE_OSR) - dataLogF("%p: Entered optimize with bytecodeIndex = %u, executeCounter = %s, reoptimizationRetryCounter = %u, optimizationDelayCounter = %u, exitCounter = ", codeBlock, bytecodeIndex, codeBlock->jitExecuteCounter().status(), codeBlock->reoptimizationRetryCounter(), codeBlock->optimizationDelayCounter()); + dataLog( + *codeBlock, ": Entered optimize with bytecodeIndex = ", bytecodeIndex, + ", executeCounter = ", codeBlock->jitExecuteCounter(), + ", optimizationDelayCounter = ", codeBlock->reoptimizationRetryCounter(), + ", exitCounter = "); if (codeBlock->hasOptimizedReplacement()) - dataLogF("%u", codeBlock->replacement()->osrExitCounter()); + dataLog(codeBlock->replacement()->osrExitCounter()); else - dataLogF("N/A"); - dataLogF("\n"); + dataLog("N/A"); + dataLog("\n"); #endif if (!codeBlock->checkIfOptimizationThresholdReached()) { @@ -1823,7 +1827,7 @@ DEFINE_STUB_FUNCTION(void, optimize) if (codeBlock->hasOptimizedReplacement()) { #if ENABLE(JIT_VERBOSE_OSR) - dataLogF("Considering OSR into %p(%p).\n", codeBlock, codeBlock->replacement()); + dataLogF("Considering OSR ", *codeBlock, " -> ", *codeBlock->replacement(), ".\n"); #endif // If we have an optimized replacement, then it must be the case that we entered // cti_optimize from a loop. That's because is there's an optimized replacement, @@ -1840,7 +1844,7 @@ DEFINE_STUB_FUNCTION(void, optimize) // additional checking anyway, to reduce the amount of recompilation thrashing. if (codeBlock->replacement()->shouldReoptimizeFromLoopNow()) { #if ENABLE(JIT_VERBOSE_OSR) - dataLogF("Triggering reoptimization of %p(%p) (in loop).\n", codeBlock, codeBlock->replacement()); + dataLogF("Triggering reoptimization of ", *codeBlock, "(", *codeBlock->replacement(), ") (in loop).\n"); #endif codeBlock->reoptimize(); return; @@ -1848,7 +1852,7 @@ DEFINE_STUB_FUNCTION(void, optimize) } else { if (!codeBlock->shouldOptimizeNow()) { #if ENABLE(JIT_VERBOSE_OSR) - dataLogF("Delaying optimization for %p (in loop) because of insufficient profiling.\n", codeBlock); + dataLogF("Delaying optimization for ", *codeBlock, " (in loop) because of insufficient profiling.\n"); #endif return; } @@ -1864,7 +1868,7 @@ DEFINE_STUB_FUNCTION(void, optimize) if (codeBlock->replacement() == codeBlock) { #if ENABLE(JIT_VERBOSE_OSR) - dataLogF("Optimizing %p failed.\n", codeBlock); + dataLogF("Optimizing ", *codeBlock, " failed.\n"); #endif ASSERT(codeBlock->getJITType() == JITCode::BaselineJIT); @@ -1878,12 +1882,12 @@ DEFINE_STUB_FUNCTION(void, optimize) if (void* address = DFG::prepareOSREntry(callFrame, optimizedCodeBlock, bytecodeIndex)) { if (Options::showDFGDisassembly()) { - dataLogF( - "Performing OSR from code block %p to code block %p, address %p to %p.\n", - codeBlock, optimizedCodeBlock, (STUB_RETURN_ADDRESS).value(), address); + dataLog( + "Performing OSR ", *codeBlock, " -> ", *optimizedCodeBlock, ", address ", + RawPointer((STUB_RETURN_ADDRESS).value()), " -> ", RawPointer(address), ".\n"); } #if ENABLE(JIT_VERBOSE_OSR) - dataLogF("Optimizing %p succeeded, performing OSR after a delay of %u.\n", codeBlock, codeBlock->optimizationDelayCounter()); + dataLogF("Optimizing ", *codeBlock, " succeeded, performing OSR after a delay of ", codeBlock->optimizationDelayCounter(), ".\n"); #endif codeBlock->optimizeSoon(); @@ -1892,7 +1896,7 @@ DEFINE_STUB_FUNCTION(void, optimize) } #if ENABLE(JIT_VERBOSE_OSR) - dataLogF("Optimizing %p succeeded, OSR failed, after a delay of %u.\n", codeBlock, codeBlock->optimizationDelayCounter()); + dataLogF("Optimizing ", *codeBlock, " succeeded, OSR failed, after a delay of ", codeBlock->optimizationDelayCounter(), ".\n"); #endif // Count the OSR failure as a speculation failure. If this happens a lot, then @@ -1900,7 +1904,7 @@ DEFINE_STUB_FUNCTION(void, optimize) optimizedCodeBlock->countOSRExit(); #if ENABLE(JIT_VERBOSE_OSR) - dataLogF("Encountered OSR failure into %p(%p).\n", codeBlock, codeBlock->replacement()); + dataLogF("Encountered OSR failure ", *codeBlock, " -> ", *codeBlock->replacement(), ".\n"); #endif // We are a lot more conservative about triggering reoptimization after OSR failure than @@ -1913,7 +1917,7 @@ DEFINE_STUB_FUNCTION(void, optimize) // reoptimization trigger. if (optimizedCodeBlock->shouldReoptimizeNow()) { #if ENABLE(JIT_VERBOSE_OSR) - dataLogF("Triggering reoptimization of %p(%p) (after OSR fail).\n", codeBlock, codeBlock->replacement()); + dataLogF("Triggering reoptimization of ", *codeBlock, " -> ", *codeBlock->replacement(), " (after OSR fail).\n"); #endif codeBlock->reoptimize(); return; |