summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/radeon/AMDGPUInstrInfo.td
diff options
context:
space:
mode:
authorTom Stellard <thomas.stellard@amd.com>2012-05-24 12:17:58 -0400
committerTom Stellard <thomas.stellard@amd.com>2012-05-24 14:12:32 -0400
commit33e7db9a1dafdcf5c7c745180831403e0485544d (patch)
treea2538001313b34330fdf84ffee2a7e9d77cd1394 /src/gallium/drivers/radeon/AMDGPUInstrInfo.td
parentd088da917bb3495491b9a5da5ca1716ddd91ddd5 (diff)
downloadexternal_mesa3d-33e7db9a1dafdcf5c7c745180831403e0485544d.zip
external_mesa3d-33e7db9a1dafdcf5c7c745180831403e0485544d.tar.gz
external_mesa3d-33e7db9a1dafdcf5c7c745180831403e0485544d.tar.bz2
radeon/llvm: Lower UDIV using the Selection DAG
Diffstat (limited to 'src/gallium/drivers/radeon/AMDGPUInstrInfo.td')
-rw-r--r--src/gallium/drivers/radeon/AMDGPUInstrInfo.td6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/gallium/drivers/radeon/AMDGPUInstrInfo.td b/src/gallium/drivers/radeon/AMDGPUInstrInfo.td
index f511d3b..5e44ef9 100644
--- a/src/gallium/drivers/radeon/AMDGPUInstrInfo.td
+++ b/src/gallium/drivers/radeon/AMDGPUInstrInfo.td
@@ -47,3 +47,9 @@ def AMDGPUsmin : SDNode<"AMDGPUISD::SMIN", SDTIntBinOp,
def AMDGPUumin : SDNode<"AMDGPUISD::UMIN", SDTIntBinOp,
[SDNPCommutative, SDNPAssociative]
>;
+
+// urecip - This operation is a helper for integer division, it returns the
+// result of 1 / a as a fractional unsigned integer.
+// out = (2^32 / a) + e
+// e is rounding error
+def AMDGPUurecip : SDNode<"AMDGPUISD::URECIP", SDTIntUnaryOp>;