nak/calc_instr_deps: Add latencies for uniform instructions

We know this is wrong.  In many cases, they're faster than warp
instructions, sometimes with a latency as low as 2.  However, there seem
to be a bunch of exceptions we don't understand and it's better to be
more concervative and have correct shaders.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29591>
This commit is contained in:
Faith Ekstrand 2024-06-04 14:55:04 -05:00 committed by Marge Bot
parent 2d4e445099
commit be91c321c9

View file

@ -478,10 +478,14 @@ fn instr_latency(op: &Op, dst_idx: usize) -> u32 {
};
// This is BS and we know it
if file.is_predicate() {
13
} else {
6
match file {
RegFile::GPR => 6,
RegFile::UGPR => 12,
RegFile::Pred => 13,
RegFile::UPred => 11,
RegFile::Bar => 0, // Barriers have a HW scoreboard
RegFile::Carry => 6,
RegFile::Mem => panic!("Not a register"),
}
}