Ignore:
Timestamp:
Aug 10, 2017, 4:00:06 PM (8 years ago)
Author:
[email protected]
Message:

Apply the UNLIKELY macro to some unlikely things.
https://bugs.webkit.org/show_bug.cgi?id=175440
<rdar://problem/33834767>

Reviewed by Yusuke Suzuki.

Source/JavaScriptCore:

  • bytecode/CodeBlock.cpp:

(JSC::CodeBlock::~CodeBlock):
(JSC::CodeBlock::jettison):

  • dfg/DFGByteCodeParser.cpp:

(JSC::DFG::ByteCodeParser::handleCall):
(JSC::DFG::ByteCodeParser::handleVarargsCall):
(JSC::DFG::ByteCodeParser::handleGetById):
(JSC::DFG::ByteCodeParser::handlePutById):
(JSC::DFG::ByteCodeParser::parseBlock):
(JSC::DFG::ByteCodeParser::parseCodeBlock):

  • dfg/DFGJITCompiler.cpp:

(JSC::DFG::JITCompiler::JITCompiler):
(JSC::DFG::JITCompiler::linkOSRExits):
(JSC::DFG::JITCompiler::link):
(JSC::DFG::JITCompiler::disassemble):

  • dfg/DFGJITFinalizer.cpp:

(JSC::DFG::JITFinalizer::finalizeCommon):

  • dfg/DFGOSRExit.cpp:

(JSC::DFG::OSRExit::compileOSRExit):

  • dfg/DFGPlan.cpp:

(JSC::DFG::Plan::Plan):

  • ftl/FTLJITFinalizer.cpp:

(JSC::FTL::JITFinalizer::finalizeCommon):

  • ftl/FTLLink.cpp:

(JSC::FTL::link):

  • ftl/FTLOSRExitCompiler.cpp:

(JSC::FTL::compileStub):

  • jit/JIT.cpp:

(JSC::JIT::privateCompileMainPass):
(JSC::JIT::compileWithoutLinking):
(JSC::JIT::link):

  • runtime/ScriptExecutable.cpp:

(JSC::ScriptExecutable::installCode):

  • runtime/VM.cpp:

(JSC::VM::VM):

Source/WebKit:

  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::getBytecodeProfile):

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/runtime/ScriptExecutable.cpp

    r220432 r220556  
    152152        RELEASE_ASSERT(JITCode::isExecutableScript(genericCodeBlock->jitType()));
    153153       
    154         if (Options::verboseOSR())
     154        if (UNLIKELY(Options::verboseOSR()))
    155155            dataLog("Installing ", *genericCodeBlock, "\n");
    156156       
    157         if (vm.m_perBytecodeProfiler)
     157        if (UNLIKELY(vm.m_perBytecodeProfiler))
    158158            vm.m_perBytecodeProfiler->ensureBytecodesFor(genericCodeBlock);
    159159       
    160         if (Debugger* debugger = genericCodeBlock->globalObject()->debugger())
     160        Debugger* debugger = genericCodeBlock->globalObject()->debugger();
     161        if (UNLIKELY(debugger))
    161162            debugger->registerCodeBlock(genericCodeBlock);
    162163    }
Note: See TracChangeset for help on using the changeset viewer.