diff options
author | Tim Rowley <[email protected]> | 2017-02-28 16:56:01 -0800 |
---|---|---|
committer | Tim Rowley <[email protected]> | 2017-03-20 18:04:53 -0500 |
commit | 8cd8240cfce1e26f2f237f1eb98d46ba47bca626 (patch) | |
tree | 2fdc833ce31b4e08d66b89eecababc35aeca9cd0 /src/gallium/drivers/swr/rasterizer/jitter | |
parent | ab032fb436a758743f288da33d9940e8761f134e (diff) |
swr: [rasterizer] Convert more SWR_ASSERT(false, ...) to SWR_INVALID(...)
Reviewed-by: Bruce Cherniak <[email protected]>
Diffstat (limited to 'src/gallium/drivers/swr/rasterizer/jitter')
3 files changed, 15 insertions, 15 deletions
diff --git a/src/gallium/drivers/swr/rasterizer/jitter/blend_jit.cpp b/src/gallium/drivers/swr/rasterizer/jitter/blend_jit.cpp index da1dfbb32fd..cbcc3434a16 100644 --- a/src/gallium/drivers/swr/rasterizer/jitter/blend_jit.cpp +++ b/src/gallium/drivers/swr/rasterizer/jitter/blend_jit.cpp @@ -137,7 +137,7 @@ struct BlendJit : public Builder out[0] = out[1] = out[2] = out[3] = FSUB(VIMMED1(1.0f), src1[3]); break; default: - SWR_ASSERT(false, "Unsupported blend factor: %d", factor); + SWR_INVALID("Unsupported blend factor: %d", factor); out[0] = out[1] = out[2] = out[3] = VIMMED1(0.0f); break; } @@ -179,7 +179,7 @@ struct BlendJit : public Builder src[3] = VMINPS(VMAXPS(src[3], VIMMED1(-1.0f)), VIMMED1(1.0f)); break; - default: SWR_ASSERT(false, "Unsupport format type: %d", type); + default: SWR_INVALID("Unsupport format type: %d", type); } } @@ -231,7 +231,7 @@ struct BlendJit : public Builder src[swizComp] = VROUND(src[swizComp], C(_MM_FROUND_TO_ZERO)); src[swizComp] = FMUL(src[swizComp], VIMMED1(1.0f /factor)); break; - default: SWR_ASSERT(false, "Unsupported format type: %d", info.type[c]); + default: SWR_INVALID("Unsupported format type: %d", info.type[c]); } } } @@ -287,7 +287,7 @@ struct BlendJit : public Builder break; default: - SWR_ASSERT(false, "Unsupported blend operation: %d", blendOp); + SWR_INVALID("Unsupported blend operation: %d", blendOp); out[0] = out[1] = out[2] = out[3] = VIMMED1(0.0f); break; } @@ -437,7 +437,7 @@ struct BlendJit : public Builder break; default: - SWR_ASSERT(false, "Unsupported logic operation: %d", logicOp); + SWR_INVALID("Unsupported logic operation: %d", logicOp); result[0] = result[1] = result[2] = result[3] = VIMMED1(0.0f); break; } @@ -470,7 +470,7 @@ struct BlendJit : public Builder case ZFUNC_NE: pTest = ICMP_NE(pAlphaU8, pRef); break; case ZFUNC_GE: pTest = ICMP_UGE(pAlphaU8, pRef); break; default: - SWR_ASSERT(false, "Invalid alpha test function"); + SWR_INVALID("Invalid alpha test function"); break; } } @@ -491,7 +491,7 @@ struct BlendJit : public Builder case ZFUNC_NE: pTest = FCMP_ONE(pAlpha, pRef); break; case ZFUNC_GE: pTest = FCMP_OGE(pAlpha, pRef); break; default: - SWR_ASSERT(false, "Invalid alpha test function"); + SWR_INVALID("Invalid alpha test function"); break; } } diff --git a/src/gallium/drivers/swr/rasterizer/jitter/fetch_jit.cpp b/src/gallium/drivers/swr/rasterizer/jitter/fetch_jit.cpp index df3ac5e7b36..9bc63f31c6a 100644 --- a/src/gallium/drivers/swr/rasterizer/jitter/fetch_jit.cpp +++ b/src/gallium/drivers/swr/rasterizer/jitter/fetch_jit.cpp @@ -359,7 +359,7 @@ void FetchJit::JitLoadVertices(const FETCH_COMPILE_STATE &fetchState, Value* str case 8: vptr = BITCAST(pointer, PointerType::get(VectorType::get(mInt8Ty, 4), 0)); break; case 16: vptr = BITCAST(pointer, PointerType::get(VectorType::get(mInt16Ty, 4), 0)); break; case 32: vptr = BITCAST(pointer, PointerType::get(VectorType::get(mFP32Ty, 4), 0)); break; - default: SWR_ASSERT(false, "Unsupported underlying bpp!"); + default: SWR_INVALID("Unsupported underlying bpp!"); } // load 4 components of attribute @@ -380,7 +380,7 @@ void FetchJit::JitLoadVertices(const FETCH_COMPILE_STATE &fetchState, Value* str vec = FMUL(vec, ConstantVector::get(std::vector<Constant*>(4, ConstantFP::get(mFP32Ty, 1.0 / 65535.0)))); break; default: - SWR_ASSERT(false, "Unsupported underlying type!"); + SWR_INVALID("Unsupported underlying type!"); break; } break; @@ -396,7 +396,7 @@ void FetchJit::JitLoadVertices(const FETCH_COMPILE_STATE &fetchState, Value* str vec = FMUL(vec, ConstantVector::get(std::vector<Constant*>(4, ConstantFP::get(mFP32Ty, 1.0 / 32768.0)))); break; default: - SWR_ASSERT(false, "Unsupported underlying type!"); + SWR_INVALID("Unsupported underlying type!"); break; } break; @@ -412,7 +412,7 @@ void FetchJit::JitLoadVertices(const FETCH_COMPILE_STATE &fetchState, Value* str case 32: break; // Pass through unchanged. default: - SWR_ASSERT(false, "Unsupported underlying type!"); + SWR_INVALID("Unsupported underlying type!"); break; } break; @@ -428,7 +428,7 @@ void FetchJit::JitLoadVertices(const FETCH_COMPILE_STATE &fetchState, Value* str case 32: break; // Pass through unchanged. default: - SWR_ASSERT(false, "Unsupported underlying type!"); + SWR_INVALID("Unsupported underlying type!"); break; } break; @@ -438,7 +438,7 @@ void FetchJit::JitLoadVertices(const FETCH_COMPILE_STATE &fetchState, Value* str case 32: break; // Pass through unchanged. default: - SWR_ASSERT(false, "Unsupported underlying type!"); + SWR_INVALID("Unsupported underlying type!"); } break; case SWR_TYPE_USCALED: @@ -452,7 +452,7 @@ void FetchJit::JitLoadVertices(const FETCH_COMPILE_STATE &fetchState, Value* str break; case SWR_TYPE_UNKNOWN: case SWR_TYPE_UNUSED: - SWR_ASSERT(false, "Unsupported type %d!", info.type[0]); + SWR_INVALID("Unsupported type %d!", info.type[0]); } // promote mask: sse(0,1,2,3) | avx(0,1,2,3,4,4,4,4) diff --git a/src/gallium/drivers/swr/rasterizer/jitter/fetch_jit.h b/src/gallium/drivers/swr/rasterizer/jitter/fetch_jit.h index 68c6f603985..d5cec70c2e8 100644 --- a/src/gallium/drivers/swr/rasterizer/jitter/fetch_jit.h +++ b/src/gallium/drivers/swr/rasterizer/jitter/fetch_jit.h @@ -94,7 +94,7 @@ enum ComponentControl ////////////////////////////////////////////////////////////////////////// struct FETCH_COMPILE_STATE { - uint32_t numAttribs {0}; + uint32_t numAttribs{ 0 }; INPUT_ELEMENT_DESC layout[KNOB_NUM_ATTRIBUTES]; SWR_FORMAT indexType; uint32_t cutIndex{ 0xffffffff }; |