#10926: wrong signature of atomic builtins ----------------------------------------+---------------------------------- Reporter: schwab | Owner: Type: bug | Status: patch Priority: normal | Milestone: Component: Compiler | Version: 7.10.2 Resolution: | Keywords: Operating System: Linux | Architecture: aarch64 Type of failure: Building GHC failed | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D1300 ----------------------------------------+---------------------------------- Comment (by Ben Gamari <ben@…>): In [changeset:"e3d2bab86fc89113f8ee65800fdfac81d8d54851/ghc" e3d2bab8/ghc]: {{{ #!CommitTicketReference repository="ghc" revision="e3d2bab86fc89113f8ee65800fdfac81d8d54851" Fix signature of atomic builtins This patch is due to Andreas Schwab. This fixes #10926, which reports (on AArch64) errors of the form, ``` /tmp/ghc1492_0/ghc_1.hc:2844:25: warning: passing argument 1 of 'hs_atomic_xor64' makes pointer from integer without a cast [-Wint-conversion] _c1Ho = hs_atomic_xor64((*Sp) + (((Sp[1]) << 0x3UL) + 0x10UL), Sp[2]); ^ In file included from /home/abuild/rpmbuild/BUILD/ghc-7.10.2/includes/Stg.h:273:0: 0, from /tmp/ghc1492_0/ghc_1.hc:3: /home/abuild/rpmbuild/BUILD/ghc-7.10.2/includes/stg/Prim.h:41:11: note: expected 'volatile StgWord64 * {aka volatile long unsigned int *}' but argument is of type 'long unsigned int' StgWord64 hs_atomic_xor64(volatile StgWord64 *x, StgWord64 val); ^ ``` Test Plan: Validate Reviewers: austin, simonmar Reviewed By: simonmar Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D1300 GHC Trac Issues: #10926 }}} -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/10926#comment:3> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler