Ignore:
Timestamp:
Apr 7, 2015, 12:41:12 PM (10 years ago)
Author:
[email protected]
Message:

Make it possible to enable LLVM FastISel
https://bugs.webkit.org/show_bug.cgi?id=143489

Reviewed by Michael Saboff.

The decision to enable FastISel is made by Options.h|cpp, but the LLVM library can disable it if it finds that it is built
against a version of LLVM that doesn't support it. Thereafter, JSC::enableLLVMFastISel is the flag that tells the system
if we should enable it.

  • ftl/FTLCompile.cpp:

(JSC::FTL::mmAllocateDataSection):

  • llvm/InitializeLLVM.cpp:

(JSC::initializeLLVMImpl):

  • llvm/InitializeLLVM.h:
  • llvm/InitializeLLVMLinux.cpp:

(JSC::getLLVMInitializerFunction):
(JSC::initializeLLVMImpl): Deleted.

  • llvm/InitializeLLVMMac.cpp:

(JSC::getLLVMInitializerFunction):
(JSC::initializeLLVMImpl): Deleted.

  • llvm/InitializeLLVMPOSIX.cpp:

(JSC::getLLVMInitializerFunctionPOSIX):
(JSC::initializeLLVMPOSIX): Deleted.

  • llvm/InitializeLLVMPOSIX.h:
  • llvm/InitializeLLVMWin.cpp:

(JSC::getLLVMInitializerFunction):
(JSC::initializeLLVMImpl): Deleted.

  • llvm/LLVMAPI.cpp:
  • llvm/LLVMAPI.h:
  • llvm/library/LLVMExports.cpp:

(initCommandLine):
(initializeAndGetJSCLLVMAPI):

  • runtime/Options.cpp:

(JSC::Options::initialize):

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/llvm/InitializeLLVMWin.cpp

    r170130 r182483  
    11/*
    2  * Copyright (C) 2014 Apple Inc. All rights reserved.
     2 * Copyright (C) 2014, 2015 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3434namespace JSC {
    3535
    36 typedef LLVMAPI* (*InitializerFunction)(void(*)(const char*, ...));
    37 
    38 void initializeLLVMImpl()
     36LLVMInitializerFunction getLLVMInitializerFunction(bool /* verbose */)
    3937{
    4038    const wchar_t* libraryName = L"libllvmForJSC.dll";
     
    4341
    4442    if (!library)
    45         return;
     43        return nullptr;
    4644
    4745    const char* symbolName = "initializeAndGetJSCLLVMAPI";
    48     InitializerFunction initializer = bitwise_cast<InitializerFunction>(GetProcAddress(library, symbolName));
    49     if (initializer)
    50         llvm = initializer(WTFLogAlwaysAndCrash);
     46    return bitwise_cast<LLVMInitializerFunction>(GetProcAddress(library, symbolName));
    5147}
    5248
Note: See TracChangeset for help on using the changeset viewer.