diff options
author | John Ky <newhoggy@gmail.com> | 2018-01-21 11:55:45 -0500 |
---|---|---|
committer | Ben Gamari <ben@smart-cactus.org> | 2018-01-21 11:56:11 -0500 |
commit | f855769690eb998ea25818ee794714957852af48 (patch) | |
tree | 969d0c0bafa72929f5ec50f1794d51e6e1799840 /compiler/cmm/CmmMachOp.hs | |
parent | 5e8ea6a62e948bcc0da1279f06844fd1d8e979bd (diff) | |
download | haskell-f855769690eb998ea25818ee794714957852af48.tar.gz |
Add new mbmi and mbmi2 compiler flags
This adds support for the bit deposit and extraction operations provided
by the BMI and BMI2 instruction set extensions on modern amd64 machines.
Implement x86 code generator for pdep and pext. Properly initialise
bmiVersion field.
pdep and pext test cases
Fix pattern match for pdep and pext instructions
Fix build of pdep and pext code for 32-bit architectures
Test Plan: Validate
Reviewers: austin, simonmar, bgamari, angerman
Reviewed By: bgamari
Subscribers: trommler, carter, angerman, thomie, rwbarton, newhoggy
GHC Trac Issues: #14206
Differential Revision: https://phabricator.haskell.org/D4236
Diffstat (limited to 'compiler/cmm/CmmMachOp.hs')
-rw-r--r-- | compiler/cmm/CmmMachOp.hs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/compiler/cmm/CmmMachOp.hs b/compiler/cmm/CmmMachOp.hs index fdbfd6e857..8ac4a6fa7b 100644 --- a/compiler/cmm/CmmMachOp.hs +++ b/compiler/cmm/CmmMachOp.hs @@ -587,6 +587,8 @@ data CallishMachOp | MO_Memcmp Int | MO_PopCnt Width + | MO_Pdep Width + | MO_Pext Width | MO_Clz Width | MO_Ctz Width |