Module: Mesa
Branch: main
Commit: 32d6720bb0a2fbd1503973391c66ce1edc579971
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=32d6720bb0a2fbd1503973391c66ce1edc579971

Author: Faith Ekstrand <faith.ekstr...@collabora.com>
Date:   Mon Nov 20 10:49:36 2023 -0600

nak: Only write deps.delay when set

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26291>

---

 src/nouveau/compiler/nak_ir.rs | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/nouveau/compiler/nak_ir.rs b/src/nouveau/compiler/nak_ir.rs
index e89cb64ccc6..3e03b0579f7 100644
--- a/src/nouveau/compiler/nak_ir.rs
+++ b/src/nouveau/compiler/nak_ir.rs
@@ -4530,7 +4530,9 @@ impl InstrDeps {
 
 impl fmt::Display for InstrDeps {
     fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
-        write!(f, "delay={}", self.delay)?;
+        if self.delay > 0 {
+            write!(f, " delay={}", self.delay)?;
+        }
         if self.wt_bar_mask != 0 {
             write!(f, " wt={:06b}", self.wt_bar_mask)?;
         }
@@ -4800,7 +4802,7 @@ impl fmt::Display for Instr {
         if !self.pred.is_true() {
             write!(f, "@{} ", self.pred)?;
         }
-        write!(f, "{} {}", self.op, self.deps)
+        write!(f, "{}{}", self.op, self.deps)
     }
 }
 

Reply via email to