Encode alignment in MO_Memcpy and friends
authorBen Gamari <ben@smart-cactus.org>
Tue, 16 Jun 2015 18:16:16 +0000 (20:16 +0200)
committerBen Gamari <ben@smart-cactus.org>
Tue, 16 Jun 2015 18:16:16 +0000 (20:16 +0200)
commita0d158fdd1db6b8f586bcbc1acd317d9836fb9dc
tree82a297bb2bfef97a20ba33d106b35ed9286579ee
parentd46fdf25888e624e78eefed64bd13dc205ed5fef
parent681973c31c614185229bdae4f6b7ab4f6e64753d
Encode alignment in MO_Memcpy and friends

Summary:
Alignment needs to be a compile-time constant. Previously the code
generators had to jump through hoops to ensure this was the case as the
alignment was passed as a CmmExpr in the arguments list. Now we take
care of this up front.

This fixes #8131.

Authored-by: Reid Barton <rwbarton@gmail.com>
Dusted-off-by: Ben Gamari <ben@smart-cactus.org>
Tests for T8131

Test Plan: Validate

Reviewers: rwbarton, austin

Reviewed By: rwbarton, austin

Subscribers: bgamari, carter, thomie

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

GHC Trac Issues: #8131
compiler/cmm/PprC.hs