|
| 1 | +2014-07-22 Filip Pizlo < [email protected]> |
| 2 | + |
| 3 | + Merge r169628 from ftlopt. |
| 4 | + |
| 5 | + 2014-06-04 Matthew Mirman < [email protected]> |
| 6 | + |
| 7 | + Added system for inlining native functions via the FTL. |
| 8 | + https://bugs.webkit.org/show_bug.cgi?id=131515 |
| 9 | + |
| 10 | + Reviewed by Filip Pizlo. |
| 11 | + |
| 12 | + Also fixed the build to not compress the bitcode and to |
| 13 | + include all of the relevant runtime. With GCC_GENERATE_DEBUGGING_SYMBOLS = NO, |
| 14 | + the produced bitcode files are a 100th the size they were before. |
| 15 | + Now we can include all of the relevant runtime files with only a 3mb overhead. |
| 16 | + This is the same overhead as for two compressed files before, |
| 17 | + but done more efficiently (on both ends) and with less code. |
| 18 | + |
| 19 | + Deciding whether to inline native functions is left up to LLVM. |
| 20 | + The entire module containing the function is linked into the current |
| 21 | + compiled JS so that inlining the native functions shouldn't make them smaller. |
| 22 | + |
| 23 | + Rather than loading Runtime.symtbl at runtime FTLState.cpp now generates a file |
| 24 | + InlineRuntimeSymbolTable.h which statically builds the symbol table hash table. |
| 25 | + |
| 26 | + * JavaScriptCore.xcodeproj/project.pbxproj: Added back runtime files to compile. |
| 27 | + * build-symbol-table-index.py: Changed bitcode suffix. |
| 28 | + Added inclusion of only tested symbols. |
| 29 | + Added output to InlineRuntimeSymbolTable.h. |
| 30 | + * build-symbol-table-index.sh: Changed bitcode suffix. |
| 31 | + * copy-llvm-ir-to-derived-sources.sh: Removed gzip compression. |
| 32 | + * tested-symbols.symlst: Added. |
| 33 | + * dfg/DFGByteCodeParser.cpp: |
| 34 | + (JSC::DFG::ByteCodeParser::handleCall): |
| 35 | + Now sets the knownFunction of the call node if such a function exists |
| 36 | + and emits a check that during runtime the callee is in fact known. |
| 37 | + * dfg/DFGNode.h: |
| 38 | + Added functions to set the known function of a call node. |
| 39 | + (JSC::DFG::Node::canBeKnownFunction): Added. |
| 40 | + (JSC::DFG::Node::hasKnownFunction): Added. |
| 41 | + (JSC::DFG::Node::knownFunction): Added. |
| 42 | + (JSC::DFG::Node::giveKnownFunction): Added. |
| 43 | + * ftl/FTLAbbreviatedTypes.h: Added a typedef for LLVMMemoryBufferRef |
| 44 | + * ftl/FTLAbbreviations.h: Added some abbreviations. |
| 45 | + * ftl/FTLLowerDFGToLLVM.cpp: |
| 46 | + (JSC::FTL::LowerDFGToLLVM::isInlinableSize): Added. Hardcoded threshold to 275. |
| 47 | + (JSC::FTL::LowerDFGToLLVM::getModuleByPathForSymbol): Added. |
| 48 | + (JSC::FTL::LowerDFGToLLVM::getFunctionBySymbol): Added. |
| 49 | + (JSC::FTL::LowerDFGToLLVM::possiblyCompileInlineableNativeCall): Added. |
| 50 | + (JSC::FTL::LowerDFGToLLVM::compileCallOrConstruct): |
| 51 | + Added call to possiblyCompileInlineableNativeCall |
| 52 | + * ftl/FTLOutput.h: |
| 53 | + (JSC::FTL::Output::allocaName): Added. Useful for debugging. |
| 54 | + * ftl/FTLState.cpp: |
| 55 | + (JSC::FTL::State::State): Added an include for InlineRuntimeSymbolTable.h |
| 56 | + * ftl/FTLState.h: Added symbol table hash table. |
| 57 | + * ftl/FTLCompile.cpp: |
| 58 | + (JSC::FTL::compile): Added inlining and dead function elimination passes. |
| 59 | + * heap/HandleStack.h: Added JS_EXPORT_PRIVATE to a few functions to get inlining to compile. |
| 60 | + * llvm/InitializeLLVMMac.mm: Deleted. |
| 61 | + * llvm/InitializeLLVMMac.cpp: Added. |
| 62 | + * llvm/LLVMAPIFunctions.h: Added macros to include Bitcode parsing and linking functions. |
| 63 | + * llvm/LLVMHeaders.h: Added includes for Bitcode parsing and linking. |
| 64 | + * runtime/BundlePath.h: Added. |
| 65 | + * runtime/BundlePath.mm: Added. |
| 66 | + * runtime/DateInstance.h: Added JS_EXPORT_PRIVATE to a few functions to get inlining to compile. |
| 67 | + * runtime/DateInstance.h: ditto. |
| 68 | + * runtime/DateConversion.h: ditto. |
| 69 | + * runtime/ExceptionHelpers.h: ditto. |
| 70 | + * runtime/JSCJSValue.h: ditto. |
| 71 | + * runtime/JSArray.h: ditto. |
| 72 | + * runtime/JSDateMath.h: ditto. |
| 73 | + * runtime/JSObject.h: ditto. |
| 74 | + * runtime/JSObject.h: ditto. |
| 75 | + * runtime/RegExp.h: ditto. |
| 76 | + * runtime/Structure.h: ditto. |
| 77 | + * runtime/Options.h: Added maximumLLVMInstructionCountForNativeInlining. |
| 78 | + |
1 | 79 | 2014-07-22 Mark Lam < [email protected]>
|
2 | 80 |
|
3 | 81 | Array.concat() should work on runtime arrays too.
|
|
0 commit comments