[Webkit-unassigned] [Bug 188483] Cannot build for i386 architecture

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Aug 15 06:44:35 PDT 2018


https://bugs.webkit.org/show_bug.cgi?id=188483

--- Comment #2 from karogyoker2+webkit at gmail.com ---
When I built like this:
cmake -DPORT=GTK -DCMAKE_BUILD_TYPE=Release -DCMAKE_C_FLAGS="-march=i386 -latomic" -DCMAKE_CXX_FLAGS="-march=i386 -latomic" -DUSE_WOFF2=OFF -GNinja

It built, and WebKit is also working.

"Those atomic primitives need CPU instructions not available in older
processors."

Which instructions are these? After a quick search I found these atomic operations are using the lock instruction[1,2] but that's available since the 8086[3]. Maybe the 80386 doesn't support a hardware implementation for __atomic_fetch_sub and __atomic_compare_exchange but it only does for other atomic operations?

We could fix the test in WebKitCompilerFlags.cmake by setting the CXX flags before running the test to include the flags which are provided by the user when it was initially starting cmake. This way "-march=i386" would be used by the compiler and it would fail the test. But this would only make sense if the 80386 would be able to run the compiled code. Currently I don't see why it could not.

[1]: http://www.mohawksoft.org/?q=node/78
[2]: https://stackoverflow.com/questions/38447226/atomicity-on-x86
[3]: https://en.wikipedia.org/wiki/X86_instruction_listings#Original_8086/8088_instructions

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20180815/a6c9b0f3/attachment-0001.html>


More information about the webkit-unassigned mailing list