diff options
author | Tom Stellard <thomas.stellard@amd.com> | 2012-05-25 10:29:09 -0400 |
---|---|---|
committer | Tom Stellard <thomas.stellard@amd.com> | 2012-05-25 15:40:58 -0400 |
commit | 17f852892346fdf3b1e9eec56b7a55c470279bc8 (patch) | |
tree | f5ff63b1fde8173bff34d757bcdeb1c71311cad8 /src/gallium/drivers/radeon/AMDGPUInstructions.td | |
parent | 2df2c31087770a6e4e79f90fe096e370cd632e00 (diff) |
radeon/llvm: Use a custom inserter to lower FABS
Diffstat (limited to 'src/gallium/drivers/radeon/AMDGPUInstructions.td')
-rw-r--r-- | src/gallium/drivers/radeon/AMDGPUInstructions.td | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/src/gallium/drivers/radeon/AMDGPUInstructions.td b/src/gallium/drivers/radeon/AMDGPUInstructions.td index 291081fef4..e1ace508e8 100644 --- a/src/gallium/drivers/radeon/AMDGPUInstructions.td +++ b/src/gallium/drivers/radeon/AMDGPUInstructions.td @@ -47,7 +47,19 @@ let isCodeGenOnly = 1 in { "MASK_WRITE $src", [] >; -} + +let isPseudo = 1, usesCustomInserter = 1 in { + +class FABS <RegisterClass rc> : AMDGPUShaderInst < + (outs rc:$dst), + (ins rc:$src0), + "FABS $dst, $src0", + [(set rc:$dst, (fabs rc:$src0))] +>; + +} // End isPseudo = 1, hasCustomInserter = 1 + +} // End isCodeGenOnly = 1 /* Generic helper patterns for intrinsics */ /* -------------------------------------- */ |