nak: Allow SSA value 0 again

We no longer need the index to be non-zero because we add 17.

Reviewed-by: Mel Henning <mhenning@darkrefraction.com>
Acked-by: Karol Herbst <kherbst@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/41462>
This commit is contained in:
Faith Ekstrand 2026-05-10 00:17:18 -04:00 committed by Marge Bot
parent 8629f5cb3e
commit f279bcdaef

View file

@ -306,8 +306,9 @@ impl SSAValueAllocator {
/// Allocates an SSA value.
pub fn alloc(&mut self, file: RegFile) -> SSAValue {
let idx = self.count;
self.count += 1;
SSAValue::new(file, self.count)
SSAValue::new(file, idx)
}
/// Allocates multiple SSA values and returns them as an SSA reference.