Skip to content
Commit f4b83bff authored by Jonathan Gray's avatar Jonathan Gray Committed by Emil Velikov
Browse files

configure.ac: rework compiler builtin atomic tests



The libdrm autoconf test for atomics uses __sync_val_compare_and_swap with
the address of a function argument which triggers a gcc ICE on sparc64
with the OpenBSD system compiler.

Mark Kettenis pointed out that while other architectures probably spill the
argument onto the stack this is likely not the case on register window
architectures like SPARC and suggested passing a pointer as an argument
instead which avoids the ICE and allows the drm libraries requiring
atomics to build on sparc64 with the autoconf build.

Reported-by: default avatarChristian Weisgerber <naddy@openbsd.org>
Signed-off-by: default avatarJonathan Gray <jsg@jsg.id.au>
Reviewed-by: default avatarMark Kettenis <kettenis@openbsd.org>
Reviewed-by: default avatarMatthieu Herrb <matthieu@openbsd.org>
parent c3deddd9
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment