diff options
author | George Kyriazis <[email protected]> | 2018-04-10 18:43:31 -0500 |
---|---|---|
committer | George Kyriazis <[email protected]> | 2018-04-27 14:36:41 -0500 |
commit | 9ceeb671a39ddd83a817d353d937283a3b44409e (patch) | |
tree | 04e16a16f5f2c5022f836a3c5672d65192a3e37f /src/gallium | |
parent | 7083ac7290a0c37a45494437a45441112f3cc36c (diff) |
swr/rast: Fix byte offset for non-indexed draws
for the case when USE_SIMD16_SHADERS == FALSE
Reviewed-by: Bruce Cherniak <[email protected]>
Diffstat (limited to 'src/gallium')
-rw-r--r-- | src/gallium/drivers/swr/rasterizer/core/frontend.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/gallium/drivers/swr/rasterizer/core/frontend.cpp b/src/gallium/drivers/swr/rasterizer/core/frontend.cpp index 9630afa036d..6e2bab3e234 100644 --- a/src/gallium/drivers/swr/rasterizer/core/frontend.cpp +++ b/src/gallium/drivers/swr/rasterizer/core/frontend.cpp @@ -1729,15 +1729,15 @@ void ProcessDraw( fetchInfo_lo.xpLastIndex = fetchInfo_lo.xpIndices; uint32_t offset; offset = std::min(endVertex-i, (uint32_t) KNOB_SIMD16_WIDTH); -#if USE_SIMD16_SHADERS offset *= 4; // convert from index to address +#if USE_SIMD16_SHADERS fetchInfo_lo.xpLastIndex += offset; #else - fetchInfo_lo.xpLastIndex += std::min(offset, (uint32_t) KNOB_SIMD_WIDTH) * 4; // * 4 for converting index to address + fetchInfo_lo.xpLastIndex += std::min(offset, (uint32_t) KNOB_SIMD_WIDTH); uint32_t offset2 = std::min(offset, (uint32_t) KNOB_SIMD16_WIDTH)-KNOB_SIMD_WIDTH; assert(offset >= 0); fetchInfo_hi.xpLastIndex = fetchInfo_hi.xpIndices; - fetchInfo_hi.xpLastIndex += offset2 * 4; // * 4 for converting index to address + fetchInfo_hi.xpLastIndex += offset2; #endif } // 1. Execute FS/VS for a single SIMD. |