diff options
author | Tom Stellard <thomas.stellard@amd.com> | 2014-03-24 18:21:32 +0000 |
---|---|---|
committer | Tom Stellard <thomas.stellard@amd.com> | 2014-03-24 18:21:32 +0000 |
commit | 3e1bcea5d089c031e520c135d882d7c0f8c71aba (patch) | |
tree | 940491debe957708f450690ae34ffebe91605ea5 /lib | |
parent | ff1afeb16df041f870fffbae5b23167a950b590b (diff) | |
download | llvm-3e1bcea5d089c031e520c135d882d7c0f8c71aba.tar.gz llvm-3e1bcea5d089c031e520c135d882d7c0f8c71aba.tar.bz2 llvm-3e1bcea5d089c031e520c135d882d7c0f8c71aba.tar.xz |
Merging r200283:
------------------------------------------------------------------------
r200283 | michel.daenzer | 2014-01-27 19:01:16 -0800 (Mon, 27 Jan 2014) | 6 lines
R600/SI: Add pattern for truncating i32 to i1
Fixes half a dozen piglit tests with radeonsi.
Reviewed-by: Tom Stellard <thomas.stellard@amd.com>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_34@204642 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Target/R600/SIInstructions.td | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/Target/R600/SIInstructions.td b/lib/Target/R600/SIInstructions.td index 88f6b0d8f6..6d38481cd2 100644 --- a/lib/Target/R600/SIInstructions.td +++ b/lib/Target/R600/SIInstructions.td @@ -2111,6 +2111,11 @@ def : Pat < (EXTRACT_SUBREG $a, sub0) >; +def : Pat < + (i1 (trunc i32:$a)), + (V_CMP_EQ_I32_e64 (V_AND_B32_e32 (i32 1), $a), 1) +>; + // V_ADD_I32_e32/S_ADD_I32 produces carry in VCC/SCC. For the vector // case, the sgpr-copies pass will fix this to use the vector version. def : Pat < |