Changeset 268385 in webkit
- Timestamp:
- Oct 12, 2020, 9:52:53 PM (5 years ago)
- Location:
- trunk/Source
- Files:
-
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/ChangeLog
r268375 r268385 1 2020-10-12 Yusuke Suzuki <ysuzuki@apple.com> 2 3 JIT operations do not need extern "C" 4 https://bugs.webkit.org/show_bug.cgi?id=217636 5 6 Reviewed by Saam Barati. 7 8 Since they are directly embedded by JIT code generator (not linked via linker), they do not need to be C linkage. 9 10 * dfg/DFGOperations.cpp: 11 * dfg/DFGOperations.h: 12 * ftl/FTLOSRExitCompiler.cpp: 13 * ftl/FTLOSRExitCompiler.h: 14 * ftl/FTLOperations.cpp: 15 * ftl/FTLOperations.h: 16 * jit/JITOperations.cpp: 17 * jit/JITOperations.h: 18 1 19 2020-10-12 Saam Barati <sbarati@apple.com> 2 20 -
trunk/Source/JavaScriptCore/dfg/DFGOperations.cpp
r268316 r268385 218 218 } 219 219 220 extern "C" {221 222 220 JSC_DEFINE_JIT_OPERATION(operationToThis, EncodedJSValue, (JSGlobalObject* globalObject, EncodedJSValue encodedOp)) 223 221 { … … 3997 3995 #endif // ENABLE(FTL_JIT) 3998 3996 3999 } // extern "C"4000 3997 } } // namespace JSC::DFG 4001 3998 -
trunk/Source/JavaScriptCore/dfg/DFGOperations.h
r267754 r268385 40 40 41 41 struct OSRExitBase; 42 43 extern "C" {44 42 45 43 JSC_DECLARE_JIT_OPERATION(operationStringFromCharCode, JSCell*, (JSGlobalObject*, int32_t)); … … 342 340 #endif // ENABLE(FTL_JIT) 343 341 344 } // extern "C"345 346 342 inline auto operationNewTypedArrayWithSizeForType(TypedArrayType type) -> decltype(&operationNewInt8ArrayWithSize) 347 343 { -
trunk/Source/JavaScriptCore/ftl/FTLOSRExitCompiler.cpp
r267727 r268385 550 550 } 551 551 552 extern "C" {553 554 552 JSC_DEFINE_JIT_OPERATION(operationCompileFTLOSRExit, void*, (CallFrame* callFrame, unsigned exitID)) 555 553 { … … 605 603 } 606 604 607 } // extern "C"608 609 605 } } // namespace JSC::FTL 610 606 -
trunk/Source/JavaScriptCore/ftl/FTLOSRExitCompiler.h
r267727 r268385 34 34 // Takes the call frame and the index of the exit, and returns the address to 35 35 // jump to. 36 extern "C" {37 36 JSC_DECLARE_JIT_OPERATION(operationCompileFTLOSRExit, void*, (CallFrame*, unsigned exitID)); 38 }39 37 40 38 } } // namespace JSC::FTL -
trunk/Source/JavaScriptCore/ftl/FTLOperations.cpp
r267727 r268385 54 54 namespace JSC { namespace FTL { 55 55 56 extern "C" {57 58 56 JSC_DEFINE_JIT_OPERATION(operationPopulateObjectInOSR, void, (JSGlobalObject* globalObject, ExitTimeObjectMaterialization* materialization, EncodedJSValue* encodedValue, EncodedJSValue* values)) 59 57 { … … 753 751 } 754 752 755 } // extern "C"756 757 753 } } // namespace JSC::FTL 758 754 -
trunk/Source/JavaScriptCore/ftl/FTLOperations.h
r267732 r268385 35 35 class LazySlowPath; 36 36 37 extern "C" {38 39 37 JSC_DECLARE_JIT_OPERATION(operationMaterializeObjectInOSR, JSCell*, (JSGlobalObject*, ExitTimeObjectMaterialization*, EncodedJSValue*)); 40 38 … … 48 46 JSC_DECLARE_JIT_OPERATION(operationReportBoundsCheckEliminationErrorAndCrash, void, (intptr_t codeBlockAsIntPtr, int32_t, int32_t, int32_t, int32_t, int32_t)); 49 47 50 } // extern "C"51 52 48 } } // namespace JSC::DFG 53 49 -
trunk/Source/JavaScriptCore/jit/JITOperations.cpp
r268316 r268385 81 81 } 82 82 83 extern "C" {84 85 83 #if COMPILER(MSVC) 86 void * _ReturnAddress(void);84 extern "C" void * _ReturnAddress(void); 87 85 #pragma intrinsic(_ReturnAddress) 88 86 … … 672 670 } 673 671 674 } // extern "C"675 676 672 template<typename PutPrivateFieldCallback> 677 673 ALWAYS_INLINE static void setPrivateField(VM& vm, JSGlobalObject* globalObject, CallFrame* callFrame, JSValue baseValue, CacheableIdentifier identifier, JSValue value, PutPrivateFieldCallback callback) … … 711 707 callback(vm, codeBlock, oldStructure, putSlot, ident); 712 708 } 713 714 extern "C" {715 709 716 710 JSC_DEFINE_JIT_OPERATION(operationPutByIdDefinePrivateFieldStrict, void, (JSGlobalObject* globalObject, StructureStubInfo*, EncodedJSValue encodedValue, EncodedJSValue encodedBase, uintptr_t rawCacheableIdentifier)) … … 1515 1509 } 1516 1510 1517 }1518 1519 1511 template<typename FunctionType> 1520 1512 static EncodedJSValue newFunctionCommon(VM& vm, JSScope* scope, JSCell* functionExecutable, bool isInvalidated) … … 1525 1517 return JSValue::encode(FunctionType::create(vm, static_cast<FunctionExecutable*>(functionExecutable), scope)); 1526 1518 } 1527 1528 extern "C" {1529 1519 1530 1520 JSC_DEFINE_JIT_OPERATION(operationNewFunction, EncodedJSValue, (VM* vmPointer, JSScope* scope, JSCell* functionExecutable)) … … 2091 2081 } 2092 2082 2093 }2094 2095 2083 ALWAYS_INLINE static JSValue getByVal(JSGlobalObject* globalObject, CallFrame* callFrame, ArrayProfile* arrayProfile, JSValue baseValue, JSValue subscript) 2096 2084 { … … 2156 2144 RELEASE_AND_RETURN(scope, baseValue.get(globalObject, property)); 2157 2145 } 2158 2159 extern "C" {2160 2146 2161 2147 JSC_DEFINE_JIT_OPERATION(operationGetByValGeneric, EncodedJSValue, (JSGlobalObject* globalObject, StructureStubInfo* stubInfo, ArrayProfile* profile, EncodedJSValue encodedBase, EncodedJSValue encodedSubscript)) … … 2250 2236 } 2251 2237 2252 } // extern "C"2253 2254 2238 ALWAYS_INLINE static JSValue getPrivateName(JSGlobalObject* globalObject, CallFrame* callFrame, JSValue baseValue, JSValue fieldNameValue) 2255 2239 { … … 2270 2254 return slot.getValue(globalObject, fieldName); 2271 2255 } 2272 2273 extern "C" {2274 2256 2275 2257 JSC_DEFINE_JIT_OPERATION(operationGetPrivateNameOptimize, EncodedJSValue, (JSGlobalObject* globalObject, StructureStubInfo* stubInfo, EncodedJSValue encodedBase, EncodedJSValue encodedFieldName)) … … 3342 3324 } 3343 3325 3344 } // extern "C"3345 3346 3326 } // namespace JSC 3347 3327 -
trunk/Source/JavaScriptCore/jit/JITOperations.h
r267754 r268385 69 69 struct InlineCallFrame; 70 70 struct Instruction; 71 72 extern "C" {73 71 74 72 typedef char* UnusedPtr; … … 317 315 JSC_DECLARE_JIT_OPERATION(operationProcessShadowChickenLog, void, (VM*)); 318 316 319 } // extern "C"320 321 317 } // namespace JSC 322 318 -
trunk/Source/WebCore/ChangeLog
r268382 r268385 1 2020-10-12 Yusuke Suzuki <ysuzuki@apple.com> 2 3 JIT operations do not need extern "C" 4 https://bugs.webkit.org/show_bug.cgi?id=217636 5 6 Reviewed by Saam Barati. 7 8 * domjit/DOMJITHelpers.h: 9 * domjit/JSDocumentDOMJIT.cpp: 10 1 11 2020-10-12 Zalan Bujtas <zalan@apple.com> 2 12 -
trunk/Source/WebCore/domjit/DOMJITHelpers.h
r267727 r268385 194 194 } 195 195 196 extern "C" {197 198 196 JSC_DECLARE_JIT_OPERATION(operationToJSNode, JSC::EncodedJSValue, (JSC::JSGlobalObject*, void*)); 199 197 JSC_DECLARE_JIT_OPERATION(operationToJSContainerNode, JSC::EncodedJSValue, (JSC::JSGlobalObject*, void*)); … … 202 200 JSC_DECLARE_JIT_OPERATION(operationToJSDocument, JSC::EncodedJSValue, (JSC::JSGlobalObject*, void*)); 203 201 204 }205 206 202 } } 207 203 -
trunk/Source/WebCore/domjit/JSDocumentDOMJIT.cpp
r267938 r268385 143 143 namespace DOMJIT { 144 144 145 extern "C" {146 147 145 JSC_DEFINE_JIT_OPERATION(operationToJSElement, JSC::EncodedJSValue, (JSC::JSGlobalObject* globalObject, void* result)) 148 146 { … … 195 193 } 196 194 197 }198 199 195 } } 200 196
Note:
See TracChangeset
for help on using the changeset viewer.