Unified build failure when compiling for iOS simulator debug - #75650
Conversation
|
EWS run on previous version of this PR (hash df46d3d) Details |
df46d3d to
f1fc211
Compare
|
EWS run on current version of this PR (hash f1fc211) Details |
youennf
left a comment
There was a problem hiding this comment.
LGTM.
I wonder whether we should not move JSObject::setStructure and JSObject::didBecomePrototype to JSObjectInlines.h instead.
I tried that already StructureCreateInlines.h doesn't include JSObjectInlines.h, so any file that included StructureCreateInlines.h but not JSObjectInlines.h called setStructure without its body. The build failed when linking libWebCoreTestSupport.dylib in a similar fashion as the bug description. |
and it created a an include cycle:
|
f1fc211 to
b1ef4a2
Compare
https://bugs.webkit.org/show_bug.cgi?id=326068 rdar://188997830 Reviewed by Youenn Fablet. JSObject.h defines JSObject::setStructure() inline, and it calls JSCell::setStructure(), which is only defined, always-inline in release, in JSCellInlines.h. The cmake build emits every inline function in a prefix header into a PCH object (-fpch-codegen). WebCorePrefix.h includes JSObject.h but not JSCellInlines.h, so each WebCore PCH object referenced a JSCell::setStructure() that no object file defines. The release iOS build failed to link with an undefined symbol `JSC::JSCell::setStructure(JSC::VM&, JSC::Structure*)`. Move the definition of JSObject::setStructure() to StructureCreateInlines.h, next to JSObject::didBecomePrototype(), which calls it. Declare it inline in JSObject.h, have JSObjectInlines.h include StructureCreateInlines.h, and have the bindings generator include StructureCreateInlines.h in constructors that call setSubclassStructureIfNeeded(). * Source/JavaScriptCore/runtime/JSObject.h: (JSC::JSObject::setStructure): Deleted. * Source/JavaScriptCore/runtime/JSObjectInlines.h: * Source/JavaScriptCore/runtime/StructureCreateInlines.h: (JSC::JSObject::setStructure): * Source/WebCore/bindings/scripts/CodeGeneratorJS.pm: (GenerateConstructorDefinition): * Source/WebCore/bindings/scripts/test/JS/JSExposedToWorkerAndWindow.cpp: * Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.cpp: * Source/WebCore/bindings/scripts/test/JS/JSTestInterface.cpp: * Source/WebCore/bindings/scripts/test/JS/JSTestLegacyFactoryFunction.cpp: * Source/WebCore/bindings/scripts/test/JS/JSTestNode.cpp: * Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp: * Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp: * Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructorsWithSequence.cpp: * Source/WebCore/bindings/scripts/test/JS/JSTestPromiseRejectionEvent.cpp: * Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.cpp: * Source/WebCore/dom/ios/MouseEventIOS.cpp: Canonical link: https://commits.webkit.org/322499@main
b1ef4a2 to
720bc3a
Compare
|
Committed 322499@main (720bc3a): https://commits.webkit.org/322499@main Reviewed commits have been landed. Closing PR #75650 and removing active labels. |
🧪 jsc-wpe
720bc3a
f1fc211
🧪 wpe-wk2🧪 api-wpe