diff options
author | Tom Stellard <[email protected]> | 2012-07-25 08:23:52 -0400 |
---|---|---|
committer | Tom Stellard <[email protected]> | 2012-07-27 17:08:07 +0000 |
commit | 022b54359a0c8cc0a219b19b1f381cce66b35d35 (patch) | |
tree | 855d2cba91f4a72b8ea96aea339bab7f849e47ee | |
parent | ad95bcb31fcf49015446f5158dfaf97fefac75cd (diff) |
radeonsi: Add support for loading integers from constant memory
-rw-r--r-- | src/gallium/drivers/radeonsi/radeonsi_shader.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/gallium/drivers/radeonsi/radeonsi_shader.c b/src/gallium/drivers/radeonsi/radeonsi_shader.c index fa86b87520e..cc6003544e3 100644 --- a/src/gallium/drivers/radeonsi/radeonsi_shader.c +++ b/src/gallium/drivers/radeonsi/radeonsi_shader.c @@ -329,6 +329,7 @@ static LLVMValueRef fetch_constant( LLVMValueRef const_ptr; LLVMValueRef offset; + LLVMValueRef load; /* XXX: Assume the pointer to the constant buffer is being stored in * SGPR[0:1] */ @@ -340,7 +341,8 @@ static LLVMValueRef fetch_constant( offset = lp_build_const_int32(base->gallivm, (reg->Register.Index * 4) + swizzle); - return build_indexed_load(base->gallivm, const_ptr, offset); + load = build_indexed_load(base->gallivm, const_ptr, offset); + return bitcast(bld_base, type, load); } /* XXX: This is partially implemented for VS only at this point. It is not complete */ |