diff options
author | Karol Herbst <[email protected]> | 2019-11-03 00:57:28 +0100 |
---|---|---|
committer | Karol Herbst <[email protected]> | 2019-11-03 01:02:52 +0100 |
commit | 538d2c33b86dd9e66a6e900ac8e1cda10a5bfc4d (patch) | |
tree | 9d4e4ee5ec2b58ab4ea5fb5ea8587d55d9ab2fb3 /src/gallium/drivers/nouveau | |
parent | 88d665830f27087cb2188e03b0b734acc144c593 (diff) |
nv50/ir: fix crash in isUniform for undefined values
Signed-off-by: Karol Herbst <[email protected]>
Reviewed-by: Ilia Mirkin <[email protected]>
Diffstat (limited to 'src/gallium/drivers/nouveau')
-rw-r--r-- | src/gallium/drivers/nouveau/codegen/nv50_ir.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir.cpp index a181a13a3b1..ae07d967221 100644 --- a/src/gallium/drivers/nouveau/codegen/nv50_ir.cpp +++ b/src/gallium/drivers/nouveau/codegen/nv50_ir.cpp @@ -274,6 +274,8 @@ LValue::isUniform() const if (defs.size() > 1) return false; Instruction *insn = getInsn(); + if (!insn) + return false; // let's not try too hard here for now ... return !insn->srcExists(1) && insn->getSrc(0)->isUniform(); } |