[GHC] #16258: PowerPC Big-Endian: ArithInt16, ArithInt8, ArithWord16, and ArithWord8 fail
GHC
ghc-devs at haskell.org
Thu Jan 31 10:09:52 UTC 2019
#16258: PowerPC Big-Endian: ArithInt16, ArithInt8, ArithWord16, and ArithWord8 fail
-------------------------------------+-------------------------------------
Reporter: trommler | Owner: trommler
Type: bug | Status: new
Priority: normal | Milestone: 8.10.1
Component: Compiler | Version: 8.7
Resolution: | Keywords: Big-endian
Operating System: Unknown/Multiple | Architecture: powerpc64
Type of failure: Incorrect result | Test Case:
at runtime | primops/should_run/ArithInt16,
| primops/should_run/ArithWord16,
| primops/should_run/ArithWord8,
| primops/should_run/ArithInt8
Blocked By: | Blocking:
Related Tickets: #16222 | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by trommler):
I found the issue, patch is coming.
Small integer values passed on the stack are not promoted to word size
(stack slot size). We can get away with that on little endian systems
where the small integer ends up in the Right (TM) place for
a word size read. On big endian the small integer is written into the most
significant bits of
a word and the least significant bits contain random values.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/16258#comment:4>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list