diff options
author | Vinson Lee <vlee@freedesktop.org> | 2021-02-13 22:20:39 -0800 |
---|---|---|
committer | Marge Bot <eric+marge@anholt.net> | 2021-02-19 04:43:58 +0000 |
commit | bf535c082bfbb1bf2271a514e677185af040b765 (patch) | |
tree | 39eaed4d7d89e5c3fd0e19354f6b7c86070658f8 /src/gallium/drivers/nouveau | |
parent | 31dd0a4a1e509c7cfbdf2cc015a89d58ffbdc896 (diff) |
nv50/ir: Initialize Instruction members.
Fix defects reported by Coverity Scan.
uninit_member: Non-static class member serial is not initialized in this constructor nor in any functions that it calls.
uninit_member: Non-static class member sched is not initialized in this constructor nor in any functions that it calls.
uninit_member: Non-static class member bb is not initialized in this constructor nor in any functions that it calls.
Signed-off-by: Vinson Lee <vlee@freedesktop.org>
Reviewed-by: Karol Herbst <kherbst@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9037>
Diffstat (limited to 'src/gallium/drivers/nouveau')
-rw-r--r-- | src/gallium/drivers/nouveau/codegen/nv50_ir.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir.cpp index 919f68ddcab..6119827474e 100644 --- a/src/gallium/drivers/nouveau/codegen/nv50_ir.cpp +++ b/src/gallium/drivers/nouveau/codegen/nv50_ir.cpp @@ -563,6 +563,7 @@ Symbol::equals(const Value *that, bool strict) const void Instruction::init() { next = prev = 0; + serial = 0; cc = CC_ALWAYS; rnd = ROUND_N; @@ -589,6 +590,9 @@ void Instruction::init() predSrc = -1; flagsDef = -1; flagsSrc = -1; + + sched = 0; + bb = NULL; } Instruction::Instruction() @@ -599,7 +603,6 @@ Instruction::Instruction() dType = sType = TYPE_F32; id = -1; - bb = 0; } Instruction::Instruction(Function *fn, operation opr, DataType ty) |