summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/radeon/SICodeEmitter.cpp
diff options
context:
space:
mode:
authorMichel Dänzer <[email protected]>2012-04-19 19:14:45 +0200
committerMichel Dänzer <[email protected]>2012-04-19 19:59:54 +0200
commitdbf48e88eb11270e080eced8468008ed2c3329cc (patch)
tree0772e21a3def34af7912e2a7949d895374b369a2 /src/gallium/drivers/radeon/SICodeEmitter.cpp
parent09b2cd7ade15755f7375be9704b825e6f606cf25 (diff)
radeonsi: Fix VGPR_BIT() definition.
Fixes encoding of VOP3 shader instructions. The shift was wrong for source registers 2 and 3, and the resulting value was only 32 bits, so the shift in SICodeEmitter::VOPPostEncode() didn't work as intended.
Diffstat (limited to 'src/gallium/drivers/radeon/SICodeEmitter.cpp')
-rw-r--r--src/gallium/drivers/radeon/SICodeEmitter.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gallium/drivers/radeon/SICodeEmitter.cpp b/src/gallium/drivers/radeon/SICodeEmitter.cpp
index 0553f0e7d42..ad494fae7c6 100644
--- a/src/gallium/drivers/radeon/SICodeEmitter.cpp
+++ b/src/gallium/drivers/radeon/SICodeEmitter.cpp
@@ -25,7 +25,7 @@
#include <stdio.h>
#define LITERAL_REG 255
-#define VGPR_BIT(src_idx) (1 << (8 * (src_idx)))
+#define VGPR_BIT(src_idx) (1ULL << (9 * src_idx - 1))
using namespace llvm;
namespace {