Changeset 237219 in webkit
- Timestamp:
- Oct 17, 2018, 7:10:44 AM (7 years ago)
- Location:
- trunk/Source/JavaScriptCore
- Files:
-
- 2 added
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/CMakeLists.txt
r237214 r237219 239 239 240 240 add_custom_command( 241 OUTPUT ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LLIntDesiredSettings.h 242 MAIN_DEPENDENCY ${JAVASCRIPTCORE_DIR}/offlineasm/generate_settings_extractor.rb 243 DEPENDS ${LLINT_ASM} ${OFFLINE_ASM} ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/InitBytecodes.asm 244 COMMAND ${RUBY_EXECUTABLE} ${JAVASCRIPTCORE_DIR}/offlineasm/generate_settings_extractor.rb -I${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/ ${JAVASCRIPTCORE_DIR}/llint/LowLevelInterpreter.asm ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LLIntDesiredSettings.h ${OFFLINE_ASM_BACKEND} 245 VERBATIM) 246 247 add_custom_command( 241 248 OUTPUT ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LLIntDesiredOffsets.h 242 249 MAIN_DEPENDENCY ${JAVASCRIPTCORE_DIR}/offlineasm/generate_offset_extractor.rb 243 DEPENDS ${LLINT_ASM} ${OFFLINE_ASM} ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/InitBytecodes.asm244 COMMAND ${RUBY_EXECUTABLE} ${JAVASCRIPTCORE_DIR}/offlineasm/generate_offset_extractor.rb -I${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/ ${JAVASCRIPTCORE_DIR}/llint/LowLevelInterpreter.asm $ {DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LLIntDesiredOffsets.h ${OFFLINE_ASM_BACKEND}250 DEPENDS LLIntSettingsExtractor ${LLINT_ASM} ${OFFLINE_ASM} ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/InitBytecodes.asm 251 COMMAND ${RUBY_EXECUTABLE} ${JAVASCRIPTCORE_DIR}/offlineasm/generate_offset_extractor.rb -I${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/ ${JAVASCRIPTCORE_DIR}/llint/LowLevelInterpreter.asm $<TARGET_FILE:LLIntSettingsExtractor> ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LLIntDesiredOffsets.h ${OFFLINE_ASM_BACKEND} 245 252 VERBATIM) 246 253 … … 254 261 # dependency of both LLIntOffsetsExtractor and LLIntOffsetsExtractor.cpp, so the command will 255 262 # actually be run multiple times! 263 add_executable(LLIntSettingsExtractor 264 ${JAVASCRIPTCORE_DIR}/llint/LLIntSettingsExtractor.cpp 265 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LLIntDesiredSettings.h ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/Bytecodes.h ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/BytecodeStructs.h 266 ) 267 256 268 add_executable(LLIntOffsetsExtractor 257 269 ${JAVASCRIPTCORE_DIR}/llint/LLIntOffsetsExtractor.cpp 258 270 ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LLIntDesiredOffsets.h ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/Bytecodes.h ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/BytecodeStructs.h 259 271 ) 272 273 target_link_libraries(LLIntSettingsExtractor WTF) 274 add_dependencies(LLIntSettingsExtractor JavaScriptCoreForwardingHeaders) 260 275 target_link_libraries(LLIntOffsetsExtractor WTF) 261 276 add_dependencies(LLIntOffsetsExtractor JavaScriptCoreForwardingHeaders) … … 1220 1235 ) 1221 1236 1237 target_include_directories(LLIntSettingsExtractor PRIVATE 1238 ${JavaScriptCore_INCLUDE_DIRECTORIES} 1239 ${JavaScriptCore_PRIVATE_INCLUDE_DIRECTORIES} 1240 ) 1241 target_include_directories(LLIntSettingsExtractor SYSTEM PRIVATE ${JavaScriptCore_SYSTEM_INCLUDE_DIRECTORIES}) 1242 1222 1243 target_include_directories(LLIntOffsetsExtractor PRIVATE 1223 1244 ${JavaScriptCore_INCLUDE_DIRECTORIES} -
trunk/Source/JavaScriptCore/ChangeLog
r237215 r237219 1 2018-10-17 Keith Miller <keith_miller@apple.com> 2 3 Unreviewed revert Fujii's revert in r237214 with new WinCairo build fix. 4 1 5 2018-10-16 Mark Lam <mark.lam@apple.com> 2 6 -
trunk/Source/JavaScriptCore/JavaScriptCore.xcodeproj/project.pbxproj
r237214 r237219 16 16 dependencies = ( 17 17 65442D5018EBB744007AF92F /* PBXTargetDependency */, 18 14BD68992151916D0050DAFF /* PBXTargetDependency */, 18 19 ); 19 20 name = "LLInt Offsets"; 21 productName = "Derived Sources"; 22 }; 23 14BD688F215191450050DAFF /* LLInt Settings */ = { 24 isa = PBXAggregateTarget; 25 buildConfigurationList = 14BD6893215191450050DAFF /* Build configuration list for PBXAggregateTarget "LLInt Settings" */; 26 buildPhases = ( 27 14BD6892215191450050DAFF /* Generate Derived Sources */, 28 ); 29 dependencies = ( 30 14BD6890215191450050DAFF /* PBXTargetDependency */, 31 ); 32 name = "LLInt Settings"; 20 33 productName = "Derived Sources"; 21 34 }; … … 799 812 14BA7A9813AADFF8005B7C2C /* Heap.h in Headers */ = {isa = PBXBuildFile; fileRef = 14BA7A9613AADFF8005B7C2C /* Heap.h */; settings = {ATTRIBUTES = (Private, ); }; }; 800 813 14BD59C50A3E8F9F00BAF59C /* JavaScriptCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 932F5BD90822A1C700736975 /* JavaScriptCore.framework */; }; 814 14BD689D215191C10050DAFF /* LLIntSettingsExtractor.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 14BD689C215191B30050DAFF /* LLIntSettingsExtractor.cpp */; }; 801 815 14BE7D3317135CF400D1807A /* WeakInlines.h in Headers */ = {isa = PBXBuildFile; fileRef = 14BE7D3217135CF400D1807A /* WeakInlines.h */; settings = {ATTRIBUTES = (Private, ); }; }; 802 816 14BFCE6910CDB1FC00364CCE /* WeakGCMap.h in Headers */ = {isa = PBXBuildFile; fileRef = 14BFCE6810CDB1FC00364CCE /* WeakGCMap.h */; settings = {ATTRIBUTES = (Private, ); }; }; … … 1846 1860 remoteGlobalIDString = 0F4680A914BA7FD900BFE272; 1847 1861 remoteInfo = "LLInt Offsets"; 1862 }; 1863 14BD6883215191310050DAFF /* PBXContainerItemProxy */ = { 1864 isa = PBXContainerItemProxy; 1865 containerPortal = 0867D690FE84028FC02AAC07 /* Project object */; 1866 proxyType = 1; 1867 remoteGlobalIDString = 65FB3F6609D11E9100F49DEB; 1868 remoteInfo = "Derived Sources"; 1869 }; 1870 14BD6891215191450050DAFF /* PBXContainerItemProxy */ = { 1871 isa = PBXContainerItemProxy; 1872 containerPortal = 0867D690FE84028FC02AAC07 /* Project object */; 1873 proxyType = 1; 1874 remoteGlobalIDString = 65FB3F6609D11E9100F49DEB; 1875 remoteInfo = "Derived Sources"; 1876 }; 1877 14BD68982151916D0050DAFF /* PBXContainerItemProxy */ = { 1878 isa = PBXContainerItemProxy; 1879 containerPortal = 0867D690FE84028FC02AAC07 /* Project object */; 1880 proxyType = 1; 1881 remoteGlobalIDString = 14BD6881215191310050DAFF; 1882 remoteInfo = JSCLLIntSettingsExtractor; 1883 }; 1884 14BD689A215191740050DAFF /* PBXContainerItemProxy */ = { 1885 isa = PBXContainerItemProxy; 1886 containerPortal = 0867D690FE84028FC02AAC07 /* Project object */; 1887 proxyType = 1; 1888 remoteGlobalIDString = 14BD688F215191450050DAFF; 1889 remoteInfo = "LLInt Settings"; 1848 1890 }; 1849 1891 53B4BD131F68C2AA00D2BEA3 /* PBXContainerItemProxy */ = { … … 3181 3223 14BD5A2B0A3E91F600BAF59C /* JSValueRef.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = JSValueRef.cpp; sourceTree = "<group>"; }; 3182 3224 14BD5A2D0A3E91F600BAF59C /* testapi.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = testapi.c; path = API/tests/testapi.c; sourceTree = "<group>"; }; 3225 14BD688E215191310050DAFF /* JSCLLIntSettingsExtractor */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = JSCLLIntSettingsExtractor; sourceTree = BUILT_PRODUCTS_DIR; }; 3226 14BD689C215191B30050DAFF /* LLIntSettingsExtractor.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = LLIntSettingsExtractor.cpp; path = llint/LLIntSettingsExtractor.cpp; sourceTree = "<group>"; }; 3183 3227 14BE7D3217135CF400D1807A /* WeakInlines.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WeakInlines.h; sourceTree = "<group>"; }; 3184 3228 14BFCE6810CDB1FC00364CCE /* WeakGCMap.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WeakGCMap.h; sourceTree = "<group>"; }; … … 3534 3578 5D5D8AD00E0D0EBE00F9C692 /* libedit.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libedit.dylib; path = /usr/lib/libedit.dylib; sourceTree = "<absolute>"; }; 3535 3579 5DAFD6CB146B686300FBEFB4 /* JSC.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = JSC.xcconfig; sourceTree = "<group>"; }; 3536 5DDDF44614FEE72200B4FB4D /* LLIntDesiredOffsets.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = LLIntDesiredOffsets.h; path = LLIntOffsets/LLIntDesiredOffsets.h; sourceTree = BUILT_PRODUCTS_DIR; };3537 3580 5DE3D0F40DD8DDFB00468714 /* WebKitAvailability.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebKitAvailability.h; sourceTree = "<group>"; }; 3538 3581 623A37EB1B87A7BD00754209 /* RegisterMap.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RegisterMap.h; sourceTree = "<group>"; }; … … 4871 4914 runOnlyForDeploymentPostprocessing = 0; 4872 4915 }; 4916 14BD6888215191310050DAFF /* Frameworks */ = { 4917 isa = PBXFrameworksBuildPhase; 4918 buildActionMask = 2147483647; 4919 files = ( 4920 ); 4921 runOnlyForDeploymentPostprocessing = 0; 4922 }; 4873 4923 651122FC14046A4C002B101D /* Frameworks */ = { 4874 4924 isa = PBXFrameworksBuildPhase; … … 4930 4980 932F5BE10822A1C700736975 /* jsc */, 4931 4981 0FF922CF14F46B130041A24E /* JSCLLIntOffsetsExtractor */, 4982 14BD688E215191310050DAFF /* JSCLLIntSettingsExtractor */, 4932 4983 141211200A48793C00480255 /* minidom */, 4933 4984 0F6183431C45F62A0072450B /* testair */, … … 5021 5072 0F4680CE14BBB3D100BFE272 /* LLIntData.cpp */, 5022 5073 0F4680CF14BBB3D100BFE272 /* LLIntData.h */, 5023 5DDDF44614FEE72200B4FB4D /* LLIntDesiredOffsets.h */,5024 5074 0F38B00F17CF077F00B144D3 /* LLIntEntrypoint.cpp */, 5025 5075 0F38B01017CF077F00B144D3 /* LLIntEntrypoint.h */, … … 5030 5080 FED287B115EC9A5700DA8161 /* LLIntOpcode.h */, 5031 5081 79CFC6EF1C33B10000C768EA /* LLIntPCRanges.h */, 5082 14BD689C215191B30050DAFF /* LLIntSettingsExtractor.cpp */, 5032 5083 0F46809F14BA7F8200BFE272 /* LLIntSlowPaths.cpp */, 5033 5084 0F4680A014BA7F8200BFE272 /* LLIntSlowPaths.h */, … … 9808 9859 productType = "com.apple.product-type.tool"; 9809 9860 }; 9861 14BD6881215191310050DAFF /* JSCLLIntSettingsExtractor */ = { 9862 isa = PBXNativeTarget; 9863 buildConfigurationList = 14BD6889215191310050DAFF /* Build configuration list for PBXNativeTarget "JSCLLIntSettingsExtractor" */; 9864 buildPhases = ( 9865 14BD6886215191310050DAFF /* Sources */, 9866 14BD6888215191310050DAFF /* Frameworks */, 9867 ); 9868 buildRules = ( 9869 ); 9870 dependencies = ( 9871 14BD6882215191310050DAFF /* PBXTargetDependency */, 9872 14BD689B215191740050DAFF /* PBXTargetDependency */, 9873 ); 9874 name = JSCLLIntSettingsExtractor; 9875 productInstallPath = /usr/local/bin; 9876 productName = jsc; 9877 productReference = 14BD688E215191310050DAFF /* JSCLLIntSettingsExtractor */; 9878 productType = "com.apple.product-type.tool"; 9879 }; 9810 9880 651122F714046A4C002B101D /* testRegExp */ = { 9811 9881 isa = PBXNativeTarget; … … 9930 10000 932F5BE30822A1C700736975 /* All */, 9931 10001 932F5B3E0822A1C700736975 /* JavaScriptCore */, 10002 65FB3F6609D11E9100F49DEB /* Derived Sources */, 10003 14BD688F215191450050DAFF /* LLInt Settings */, 10004 14BD6881215191310050DAFF /* JSCLLIntSettingsExtractor */, 9932 10005 0F4680A914BA7FD900BFE272 /* LLInt Offsets */, 9933 65FB3F6609D11E9100F49DEB /* Derived Sources */,9934 10006 0FF922C314F46B130041A24E /* JSCLLIntOffsetsExtractor */, 9935 10007 65788A9D18B409EB00C189FF /* Offline Assembler */, … … 9973 10045 runOnlyForDeploymentPostprocessing = 0; 9974 10046 shellPath = /bin/sh; 9975 shellScript = "set -e\n\nmkdir -p \"${BUILT_PRODUCTS_DIR}/LLIntOffsets/${ARCHS}\"\n\n/usr/bin/env ruby \"${SRCROOT}/offlineasm/generate_offset_extractor.rb\" \"-I${BUILT_PRODUCTS_DIR}/DerivedSources/JavaScriptCore\" \"${SRCROOT}/llint/LowLevelInterpreter.asm\" \"${BUILT_PRODUCTS_DIR}/LLIntOffsets/${ARCHS}/LLIntDesiredOffsets.h\" \"${ARCHS} C_LOOP\"\n"; 10047 shellScript = "set -e\n\nmkdir -p \"${BUILT_PRODUCTS_DIR}/LLIntOffsets/${ARCHS}\"\n\n/usr/bin/env ruby \"${SRCROOT}/offlineasm/generate_offset_extractor.rb\" \"-I${BUILT_PRODUCTS_DIR}/DerivedSources/JavaScriptCore\" \"${SRCROOT}/llint/LowLevelInterpreter.asm\" \"${BUILT_PRODUCTS_DIR}/JSCLLIntSettingsExtractor\" \"${BUILT_PRODUCTS_DIR}/LLIntOffsets/${ARCHS}/LLIntDesiredOffsets.h\" \"${ARCHS} C_LOOP\"\n"; 10048 }; 10049 14BD6892215191450050DAFF /* Generate Derived Sources */ = { 10050 isa = PBXShellScriptBuildPhase; 10051 buildActionMask = 2147483647; 10052 files = ( 10053 ); 10054 inputPaths = ( 10055 ); 10056 name = "Generate Derived Sources"; 10057 outputPaths = ( 10058 ); 10059 runOnlyForDeploymentPostprocessing = 0; 10060 shellPath = /bin/sh; 10061 shellScript = "set -e\n\nmkdir -p \"${BUILT_PRODUCTS_DIR}/LLIntOffsets/${ARCHS}\"\n\n/usr/bin/env ruby \"${SRCROOT}/offlineasm/generate_settings_extractor.rb\" \"-I${BUILT_PRODUCTS_DIR}/DerivedSources/JavaScriptCore\" \"${SRCROOT}/llint/LowLevelInterpreter.asm\" \"${BUILT_PRODUCTS_DIR}/LLIntOffsets/${ARCHS}/LLIntDesiredSettings.h\" \"${ARCHS} C_LOOP\"\n"; 9976 10062 }; 9977 10063 1A02D9A81B34A882000D1522 /* Add Symlink in /System/Library/PrivateFrameworks */ = { … … 10244 10330 86D2221A167EF9440024C804 /* testapi.mm in Sources */, 10245 10331 534902851C7276B70012BCB8 /* TypedArrayCTest.cpp in Sources */, 10332 ); 10333 runOnlyForDeploymentPostprocessing = 0; 10334 }; 10335 14BD6886215191310050DAFF /* Sources */ = { 10336 isa = PBXSourcesBuildPhase; 10337 buildActionMask = 2147483647; 10338 files = ( 10339 14BD689D215191C10050DAFF /* LLIntSettingsExtractor.cpp in Sources */, 10246 10340 ); 10247 10341 runOnlyForDeploymentPostprocessing = 0; … … 10471 10565 targetProxy = 0FF922D214F46B2F0041A24E /* PBXContainerItemProxy */; 10472 10566 }; 10567 14BD6882215191310050DAFF /* PBXTargetDependency */ = { 10568 isa = PBXTargetDependency; 10569 target = 65FB3F6609D11E9100F49DEB /* Derived Sources */; 10570 targetProxy = 14BD6883215191310050DAFF /* PBXContainerItemProxy */; 10571 }; 10572 14BD6890215191450050DAFF /* PBXTargetDependency */ = { 10573 isa = PBXTargetDependency; 10574 target = 65FB3F6609D11E9100F49DEB /* Derived Sources */; 10575 targetProxy = 14BD6891215191450050DAFF /* PBXContainerItemProxy */; 10576 }; 10577 14BD68992151916D0050DAFF /* PBXTargetDependency */ = { 10578 isa = PBXTargetDependency; 10579 target = 14BD6881215191310050DAFF /* JSCLLIntSettingsExtractor */; 10580 targetProxy = 14BD68982151916D0050DAFF /* PBXContainerItemProxy */; 10581 }; 10582 14BD689B215191740050DAFF /* PBXTargetDependency */ = { 10583 isa = PBXTargetDependency; 10584 target = 14BD688F215191450050DAFF /* LLInt Settings */; 10585 targetProxy = 14BD689A215191740050DAFF /* PBXContainerItemProxy */; 10586 }; 10473 10587 53B4BD141F68C2AA00D2BEA3 /* PBXTargetDependency */ = { 10474 10588 isa = PBXTargetDependency; … … 10857 10971 name = Production; 10858 10972 }; 10973 14BD688A215191310050DAFF /* Debug */ = { 10974 isa = XCBuildConfiguration; 10975 baseConfigurationReference = BC021BF2136900C300FC5467 /* ToolExecutable.xcconfig */; 10976 buildSettings = { 10977 HEADER_SEARCH_PATHS = ( 10978 "\"${BUILT_PRODUCTS_DIR}/DerivedSources/JavaScriptCore\"", 10979 "\"${BUILT_PRODUCTS_DIR}/LLIntOffsets/${ARCHS}\"", 10980 "\"$(JAVASCRIPTCORE_FRAMEWORKS_DIR)/JavaScriptCore.framework/PrivateHeaders\"", 10981 "$(inherited)", 10982 ); 10983 PRODUCT_NAME = "$(TARGET_NAME)"; 10984 }; 10985 name = Debug; 10986 }; 10987 14BD688B215191310050DAFF /* Release */ = { 10988 isa = XCBuildConfiguration; 10989 baseConfigurationReference = BC021BF2136900C300FC5467 /* ToolExecutable.xcconfig */; 10990 buildSettings = { 10991 HEADER_SEARCH_PATHS = ( 10992 "\"${BUILT_PRODUCTS_DIR}/DerivedSources/JavaScriptCore\"", 10993 "\"${BUILT_PRODUCTS_DIR}/LLIntOffsets/${ARCHS}\"", 10994 "\"$(JAVASCRIPTCORE_FRAMEWORKS_DIR)/JavaScriptCore.framework/PrivateHeaders\"", 10995 "$(inherited)", 10996 ); 10997 PRODUCT_NAME = "$(TARGET_NAME)"; 10998 }; 10999 name = Release; 11000 }; 11001 14BD688C215191310050DAFF /* Profiling */ = { 11002 isa = XCBuildConfiguration; 11003 baseConfigurationReference = BC021BF2136900C300FC5467 /* ToolExecutable.xcconfig */; 11004 buildSettings = { 11005 HEADER_SEARCH_PATHS = ( 11006 "\"${BUILT_PRODUCTS_DIR}/DerivedSources/JavaScriptCore\"", 11007 "\"${BUILT_PRODUCTS_DIR}/LLIntOffsets/${ARCHS}\"", 11008 "\"$(JAVASCRIPTCORE_FRAMEWORKS_DIR)/JavaScriptCore.framework/PrivateHeaders\"", 11009 "$(inherited)", 11010 ); 11011 PRODUCT_NAME = "$(TARGET_NAME)"; 11012 }; 11013 name = Profiling; 11014 }; 11015 14BD688D215191310050DAFF /* Production */ = { 11016 isa = XCBuildConfiguration; 11017 baseConfigurationReference = BC021BF2136900C300FC5467 /* ToolExecutable.xcconfig */; 11018 buildSettings = { 11019 HEADER_SEARCH_PATHS = ( 11020 "\"${BUILT_PRODUCTS_DIR}/DerivedSources/JavaScriptCore\"", 11021 "\"${BUILT_PRODUCTS_DIR}/LLIntOffsets/${ARCHS}\"", 11022 "\"$(JAVASCRIPTCORE_FRAMEWORKS_DIR)/JavaScriptCore.framework/PrivateHeaders\"", 11023 "$(inherited)", 11024 ); 11025 PRODUCT_NAME = "$(TARGET_NAME)"; 11026 }; 11027 name = Production; 11028 }; 11029 14BD6894215191450050DAFF /* Debug */ = { 11030 isa = XCBuildConfiguration; 11031 buildSettings = { 11032 PRODUCT_NAME = "$(TARGET_NAME)"; 11033 }; 11034 name = Debug; 11035 }; 11036 14BD6895215191450050DAFF /* Release */ = { 11037 isa = XCBuildConfiguration; 11038 buildSettings = { 11039 PRODUCT_NAME = "$(TARGET_NAME)"; 11040 }; 11041 name = Release; 11042 }; 11043 14BD6896215191450050DAFF /* Profiling */ = { 11044 isa = XCBuildConfiguration; 11045 buildSettings = { 11046 PRODUCT_NAME = "$(TARGET_NAME)"; 11047 }; 11048 name = Profiling; 11049 }; 11050 14BD6897215191450050DAFF /* Production */ = { 11051 isa = XCBuildConfiguration; 11052 buildSettings = { 11053 PRODUCT_NAME = "$(TARGET_NAME)"; 11054 }; 11055 name = Production; 11056 }; 10859 11057 53B4BD0B1F68AF8900D2BEA3 /* Debug */ = { 10860 11058 isa = XCBuildConfiguration; … … 11244 11442 defaultConfigurationName = Production; 11245 11443 }; 11444 14BD6889215191310050DAFF /* Build configuration list for PBXNativeTarget "JSCLLIntSettingsExtractor" */ = { 11445 isa = XCConfigurationList; 11446 buildConfigurations = ( 11447 14BD688A215191310050DAFF /* Debug */, 11448 14BD688B215191310050DAFF /* Release */, 11449 14BD688C215191310050DAFF /* Profiling */, 11450 14BD688D215191310050DAFF /* Production */, 11451 ); 11452 defaultConfigurationIsVisible = 0; 11453 defaultConfigurationName = Production; 11454 }; 11455 14BD6893215191450050DAFF /* Build configuration list for PBXAggregateTarget "LLInt Settings" */ = { 11456 isa = XCConfigurationList; 11457 buildConfigurations = ( 11458 14BD6894215191450050DAFF /* Debug */, 11459 14BD6895215191450050DAFF /* Release */, 11460 14BD6896215191450050DAFF /* Profiling */, 11461 14BD6897215191450050DAFF /* Production */, 11462 ); 11463 defaultConfigurationIsVisible = 0; 11464 defaultConfigurationName = Production; 11465 }; 11246 11466 53B4BD0A1F68AF8900D2BEA3 /* Build configuration list for PBXAggregateTarget "Generate Unified Sources" */ = { 11247 11467 isa = XCConfigurationList; -
trunk/Source/JavaScriptCore/assembler/Printer.h
r237214 r237219 26 26 #pragma once 27 27 28 #include "CPU.h" 29 28 30 #include <wtf/PrintStream.h> 29 31 #include <wtf/StringPrintStream.h> -
trunk/Source/JavaScriptCore/llint/LLIntOffsetsExtractor.cpp
r237214 r237219 61 61 #include "ValueProfile.h" 62 62 #include "Watchdog.h" 63 #include <stdio.h> 63 64 #include <wtf/text/StringImpl.h> 64 65 … … 81 82 // compiler to kindly step aside and yield to our best intentions. 82 83 #include "LLIntDesiredOffsets.h" 83 return extractorTable;84 return offsetExtractorTable; 84 85 } 85 86 -
trunk/Source/JavaScriptCore/offlineasm/generate_offset_extractor.rb
r237214 r237219 1 1 #!/usr/bin/env ruby 2 2 3 # Copyright (C) 2011 Apple Inc. All rights reserved.3 # Copyright (C) 2011-2018 Apple Inc. All rights reserved. 4 4 # 5 5 # Redistribution and use in source and binary forms, with or without … … 38 38 39 39 inputFlnm = ARGV.shift 40 settingsFlnm = ARGV.shift 40 41 outputFlnm = ARGV.shift 41 42 42 43 validBackends = canonicalizeBackendNames(ARGV.shift.split(/[,\s]+/)) 43 44 includeOnlyBackends(validBackends) 45 46 begin 47 configurationList = configurationIndices(settingsFlnm) 48 rescue MissingMagicValuesException 49 $stderr.puts "OffsetExtractor: No magic values found. Skipping offsets extractor file generation." 50 exit 1 51 end 44 52 45 53 def emitMagicNumber … … 50 58 end 51 59 52 inputHash = "// offlineasm input hash: #{parseHash(inputFlnm)} #{selfHash}" 60 configurationHash = Digest::SHA1.hexdigest(configurationList.join(' ')) 61 inputHash = "// OffsetExtractor input hash: #{parseHash(inputFlnm)} #{configurationHash} #{selfHash}" 53 62 54 63 if FileTest.exist? outputFlnm … … 57 66 firstLine = inp.gets 58 67 if firstLine and firstLine.chomp == inputHash 59 $stderr.puts " offlineasm: Nothing changed."68 $stderr.puts "OffsetExtractor: Nothing changed." 60 69 exit 0 61 70 end … … 63 72 end 64 73 65 originalAST = parse(inputFlnm) 66 67 # 68 # Optimize the AST to make configuration extraction faster. This reduces the AST to a form 69 # that only contains the things that matter for our purposes: offsets, sizes, and if 70 # statements. 71 # 72 73 class Node 74 def offsetsPruneTo(sequence) 75 children.each { 76 | child | 77 child.offsetsPruneTo(sequence) 78 } 79 end 80 81 def offsetsPrune 82 result = Sequence.new(codeOrigin, []) 83 offsetsPruneTo(result) 84 result 85 end 86 end 87 88 class IfThenElse 89 def offsetsPruneTo(sequence) 90 ifThenElse = IfThenElse.new(codeOrigin, predicate, thenCase.offsetsPrune) 91 ifThenElse.elseCase = elseCase.offsetsPrune 92 sequence.list << ifThenElse 93 end 94 end 95 96 class StructOffset 97 def offsetsPruneTo(sequence) 98 sequence.list << self 99 end 100 end 101 102 class Sizeof 103 def offsetsPruneTo(sequence) 104 sequence.list << self 105 end 106 end 107 108 class ConstExpr 109 def offsetsPruneTo(sequence) 110 sequence.list << self 111 end 112 end 113 114 prunedAST = originalAST.offsetsPrune 74 ast = parse(inputFlnm) 75 settingsCombinations = computeSettingsCombinations(ast) 115 76 116 77 File.open(outputFlnm, "w") { … … 118 79 $output = outp 119 80 outp.puts inputHash 120 length = 0121 81 122 emitCodeInAllConfigurations(prunedAST) { 123 | settings, ast, backend, index | 124 constsList = ast.filter(ConstExpr).uniq.sort 82 configurationList.each { 83 | configIndex | 84 forSettings(settingsCombinations[configIndex], ast) { 85 | concreteSettings, lowLevelAST, backend | 125 86 126 constsList.each_with_index { 127 | const, index | 128 outp.puts "constexpr int64_t constValue#{index} = static_cast<int64_t>(#{const.value});" 87 offsetsList = offsetsList(lowLevelAST) 88 sizesList = sizesList(lowLevelAST) 89 constsList = constsList(lowLevelAST) 90 91 emitCodeInConfiguration(concreteSettings, lowLevelAST, backend) { 92 constsList.each_with_index { 93 | const, index | 94 outp.puts "constexpr int64_t constValue#{index} = static_cast<int64_t>(#{const.value});" 95 } 96 outp.puts "static const int64_t offsetExtractorTable[] = {" 97 OFFSET_HEADER_MAGIC_NUMBERS.each { 98 | number | 99 outp.puts "unsigned(#{number})," 100 } 101 102 emitMagicNumber 103 outp.puts "#{configIndex}," 104 offsetsList.each { 105 | offset | 106 emitMagicNumber 107 outp.puts "OFFLINE_ASM_OFFSETOF(#{offset.struct}, #{offset.field})," 108 } 109 sizesList.each { 110 | sizeof | 111 emitMagicNumber 112 outp.puts "sizeof(#{sizeof.struct})," 113 } 114 constsList.each_with_index { 115 | const, index | 116 emitMagicNumber 117 outp.puts "constValue#{index}," 118 } 119 outp.puts "};" 120 } 129 121 } 130 122 } 131 123 132 emitCodeInAllConfigurations(prunedAST) {133 | settings, ast, backend, index |134 offsetsList = ast.filter(StructOffset).uniq.sort135 sizesList = ast.filter(Sizeof).uniq.sort136 constsList = ast.filter(ConstExpr).uniq.sort137 length += OFFSET_HEADER_MAGIC_NUMBERS.size + (OFFSET_MAGIC_NUMBERS.size + 1) * (1 + offsetsList.size + sizesList.size + constsList.size)138 }139 outp.puts "static const int64_t extractorTable[#{length}] = {"140 emitCodeInAllConfigurations(prunedAST) {141 | settings, ast, backend, index |142 OFFSET_HEADER_MAGIC_NUMBERS.each {143 | number |144 $output.puts "unsigned(#{number}),"145 }146 147 offsetsList = ast.filter(StructOffset).uniq.sort148 sizesList = ast.filter(Sizeof).uniq.sort149 constsList = ast.filter(ConstExpr).uniq.sort150 151 emitMagicNumber152 outp.puts "#{index},"153 offsetsList.each {154 | offset |155 emitMagicNumber156 outp.puts "OFFLINE_ASM_OFFSETOF(#{offset.struct}, #{offset.field}),"157 }158 sizesList.each {159 | sizeof |160 emitMagicNumber161 outp.puts "sizeof(#{sizeof.struct}),"162 }163 constsList.each_index {164 | index |165 emitMagicNumber166 outp.puts "constValue#{index},"167 }168 }169 outp.puts "};"170 171 124 } -
trunk/Source/JavaScriptCore/offlineasm/offsets.rb
r237214 r237219 57 57 end 58 58 59 # 60 # offsetsAndConfigurationIndex(ast, file) -> 61 # [[offsets, index], ...] 62 # 63 # Parses the offsets from a file and returns a list of offsets and the 64 # index of the configuration that is valid in this build target. 65 # 66 67 def offsetsAndConfigurationIndex(file) 68 endiannessMarkerBytes = nil 69 result = {} 70 71 def readInt(endianness, bytes) 72 if endianness == :little 73 # Little endian 74 number = (bytes[0] << 0 | 75 bytes[1] << 8 | 76 bytes[2] << 16 | 77 bytes[3] << 24 | 78 bytes[4] << 32 | 79 bytes[5] << 40 | 80 bytes[6] << 48 | 81 bytes[7] << 56) 82 else 83 # Big endian 84 number = (bytes[0] << 56 | 85 bytes[1] << 48 | 86 bytes[2] << 40 | 87 bytes[3] << 32 | 88 bytes[4] << 24 | 89 bytes[5] << 16 | 90 bytes[6] << 8 | 91 bytes[7] << 0) 92 end 93 if number > 0x7fffffff_ffffffff 94 number -= 1 << 64 95 end 96 number 59 def readInt(endianness, bytes) 60 if endianness == :little 61 # Little endian 62 number = (bytes[0] << 0 | 63 bytes[1] << 8 | 64 bytes[2] << 16 | 65 bytes[3] << 24 | 66 bytes[4] << 32 | 67 bytes[5] << 40 | 68 bytes[6] << 48 | 69 bytes[7] << 56) 70 else 71 # Big endian 72 number = (bytes[0] << 56 | 73 bytes[1] << 48 | 74 bytes[2] << 40 | 75 bytes[3] << 32 | 76 bytes[4] << 24 | 77 bytes[5] << 16 | 78 bytes[6] << 8 | 79 bytes[7] << 0) 97 80 end 98 99 def prepareMagic(endianness, numbers)100 magicBytes = []101 numbers.each {102 | number | 103 currentBytes = [] 104 8.times { 105 currentBytes << (number & 0xff)106 number >>= 8107 }108 if endianness == :big109 currentBytes.reverse!110 end111 magicBytes += currentBytes81 if number > 0x7fffffff_ffffffff 82 number -= 1 << 64 83 end 84 number 85 end 86 87 def prepareMagic(endianness, numbers) 88 magicBytes = [] 89 numbers.each { 90 | number | 91 currentBytes = [] 92 8.times { 93 currentBytes << (number & 0xff) 94 number >>= 8 112 95 } 113 magicBytes 114 end 115 96 if endianness == :big 97 currentBytes.reverse! 98 end 99 magicBytes += currentBytes 100 } 101 magicBytes 102 end 103 104 def fileBytes(file) 116 105 fileBytes = [] 117 118 106 File.open(file, "rb") { 119 107 | inp | … … 124 112 } 125 113 } 126 127 def sliceByteArrays(byteArray, pattern) 128 result = [] 129 lastSlicePoint = 0 130 (byteArray.length - pattern.length + 1).times { 131 | index | 132 foundOne = true 133 pattern.length.times { 134 | subIndex | 135 if byteArray[index + subIndex] != pattern[subIndex] 136 foundOne = false 137 break 138 end 139 } 140 if foundOne 141 result << byteArray[lastSlicePoint...index] 142 lastSlicePoint = index + pattern.length 114 fileBytes 115 end 116 117 def sliceByteArrays(byteArray, pattern) 118 result = [] 119 lastSlicePoint = 0 120 (byteArray.length - pattern.length + 1).times { 121 | index | 122 foundOne = true 123 pattern.length.times { 124 | subIndex | 125 if byteArray[index + subIndex] != pattern[subIndex] 126 foundOne = false 127 break 143 128 end 144 129 } 145 146 result << byteArray[lastSlicePoint...(byteArray.length)] 147 148 result 149 end 150 130 if foundOne 131 result << byteArray[lastSlicePoint...index] 132 lastSlicePoint = index + pattern.length 133 end 134 } 135 136 result << byteArray[lastSlicePoint...(byteArray.length)] 137 138 result 139 end 140 141 # 142 # offsetsAndConfigurationIndex(ast, file) -> 143 # [[offsets, index], ...] 144 # 145 # Parses the offsets from a file and returns a list of offsets and the 146 # index of the configuration that is valid in this build target. 147 # 148 149 def offsetsAndConfigurationIndex(file) 150 fileBytes = fileBytes(file) 151 result = {} 152 151 153 [:little, :big].each { 152 154 | endianness | 153 155 headerMagicBytes = prepareMagic(endianness, OFFSET_HEADER_MAGIC_NUMBERS) 154 156 magicBytes = prepareMagic(endianness, OFFSET_MAGIC_NUMBERS) 155 157 156 158 bigArray = sliceByteArrays(fileBytes, headerMagicBytes) 157 159 unless bigArray.size <= 1 … … 169 171 end 170 172 } 171 173 172 174 raise MissingMagicValuesException unless result.length >= 1 173 175 174 176 # result is {index1=>offsets1, index2=>offsets2} but we want to return 175 177 # [[offsets1, index1], [offsets2, index2]]. … … 181 183 182 184 # 185 # configurationIndices(ast, file) -> 186 # [[offsets, index], ...] 187 # 188 # Parses the configurations from a file and returns a list of the indices of 189 # the configurations that are valid in this build target. 190 # 191 192 def configurationIndices(file) 193 fileBytes = fileBytes(file) 194 result = [] 195 196 [:little, :big].each { 197 | endianness | 198 headerMagicBytes = prepareMagic(endianness, OFFSET_HEADER_MAGIC_NUMBERS) 199 200 bigArray = sliceByteArrays(fileBytes, headerMagicBytes) 201 unless bigArray.size <= 1 202 bigArray[1..-1].each { 203 | configArray | 204 result << readInt(endianness, configArray) 205 } 206 end 207 } 208 209 raise MissingMagicValuesException unless result.length >= 1 210 211 return result 212 end 213 214 # 183 215 # buildOffsetsMap(ast, extractedConstants) -> map 184 216 # -
trunk/Source/JavaScriptCore/offlineasm/settings.rb
r237214 r237219 91 91 def forSettings(concreteSettings, ast) 92 92 # Check which architectures this combinator claims to support. 93 numClaimedBackends = 094 93 selectedBackend = nil 95 94 BACKENDS.each { … … 167 166 168 167 def isASTErroneous(ast) 169 not ast. filter(Error).empty?168 not ast.demacroify({}).filter(Error).empty? 170 169 end 171 170 … … 205 204 206 205 if isASTErroneous(ast) 207 $output.puts "#error \"Invalid configuration. \""206 $output.puts "#error \"Invalid configuration. Error at: #{ast.filter(Error)[0].codeOrigin}\"" 208 207 elsif not WORKING_BACKENDS.include? backend 209 208 $output.puts "#error \"This backend is not supported yet.\""
Note:
See TracChangeset
for help on using the changeset viewer.