Commit 19ce8a53 authored by Erik de Castro Lopo's avatar Erik de Castro Lopo
Browse files

Sparc*: Prevent GHC from doing unaligned accesses

This is specifically for the C backend on Sparc64 (which has
no native backend) but is also required for Sparc when building
un-registerised.

Bug reported via Debian (patch included):

    https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=842780

Test Plan: validate

Reviewers: hvr, Phyx, bgamari, austin, simonmar

Reviewed By: Phyx

Subscribers: jrtc27, thomie

Differential Revision: https://phabricator.haskell.org/D2661

GHC Trac Issues: #12793
parent 0b70ec0c
......@@ -1110,6 +1110,8 @@ cLoad expr rep
bewareLoadStoreAlignment ArchMipsel = True
bewareLoadStoreAlignment (ArchARM {}) = True
bewareLoadStoreAlignment ArchARM64 = True
bewareLoadStoreAlignment ArchSPARC = True
bewareLoadStoreAlignment ArchSPARC64 = True
-- Pessimistically assume that they will also cause problems
-- on unknown arches
bewareLoadStoreAlignment ArchUnknown = True
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment