mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-07 04:58:05 +02:00
nv50/ir: the mad source might not have a defining instruction
For example if it's $r63 (aka 0), there won't be a definition.
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Cc: "11.0 11.1" <mesa-stable@lists.freedesktop.org>
(cherry picked from commit 11fcf46590)
This commit is contained in:
parent
0828391a34
commit
7f6e9c5f59
1 changed files with 1 additions and 1 deletions
|
|
@ -2660,7 +2660,7 @@ NV50PostRaConstantFolding::visit(BasicBlock *bb)
|
||||||
break;
|
break;
|
||||||
|
|
||||||
def = i->getSrc(1)->getInsn();
|
def = i->getSrc(1)->getInsn();
|
||||||
if (def->op == OP_MOV && def->src(0).getFile() == FILE_IMMEDIATE) {
|
if (def && def->op == OP_MOV && def->src(0).getFile() == FILE_IMMEDIATE) {
|
||||||
vtmp = i->getSrc(1);
|
vtmp = i->getSrc(1);
|
||||||
i->setSrc(1, def->getSrc(0));
|
i->setSrc(1, def->getSrc(0));
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue