Skip to content
  • barraclough@apple.com's avatar
    https://bugs.webkit.org/show_bug.cgi?id=68328 · 6d2ad995
    barraclough@apple.com authored
    The generator and intrinsic fields in HashTableValue/HashEntry and associated structures and methods are redundant
    
    Reviewed by Geoff Garen.
    
    ../JavaScriptCore: 
    
    Move the instrinsic enum out of the DFG, into runtime. Add entires for all host functions
    that have an intrinsic in the form of a generated thunk. Remove the thunk pointer from the
    hashtable, and make Intrinsic field no longer ifdef on JIT/DFG. In getHostFunction select
    a thunk genertaor to use based on the Intrinsic.
    
    * JavaScriptCore.xcodeproj/project.pbxproj:
    * create_hash_table:
    * dfg/DFGByteCodeParser.cpp:
    (JSC::DFG::ByteCodeParser::handleCall):
    (JSC::DFG::ByteCodeParser::handleIntrinsic):
    * dfg/DFGCapabilities.h:
    * dfg/DFGIntrinsic.h: Removed.
    * jit/JITStubs.cpp:
    (JSC::JITThunks::hostFunctionStub):
    * jit/JITStubs.h:
    * runtime/Executable.cpp:
    (JSC::ExecutableBase::intrinsic):
    (JSC::NativeExecutable::intrinsic):
    * runtime/Executable.h:
    (JSC::ExecutableBase::intrinsicFor):
    (JSC::NativeExecutable::create):
    (JSC::NativeExecutable::finishCreation):
    * runtime/Intrinsic.h: Copied from Source/JavaScriptCore/dfg/DFGIntrinsic.h.
    * runtime/JSGlobalData.cpp:
    (JSC::thunkGeneratorForIntrinsic):
    (JSC::JSGlobalData::getHostFunction):
    * runtime/JSGlobalData.h:
    * runtime/Lookup.cpp:
    (JSC::HashTable::createTable):
    (JSC::setUpStaticFunctionSlot):
    * runtime/Lookup.h:
    (JSC::HashEntry::initialize):
    (JSC::HashEntry::intrinsic):
    
    ../WebCore: 
    
    Intrinsic is no longer in the DFG namespace, is always in the
    hash table. Removed ThunkGenerator.
    
    * bindings/scripts/CodeGeneratorJS.pm:
    (GenerateHashTable):
    
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@102167 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    6d2ad995