mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-25 04:20:08 +01:00
aco: add support for device clock on GFX11
According to LLVM, s_sendmsg_rtn(GET_REALTIME) should be used instead of s_memrealtime. Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by: Rhys Perry <pendingchaos02@gmail.com> Reviewed-by: Georg Lehmann <dadschoorse@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19267>
This commit is contained in:
parent
c481978ac2
commit
db573f7362
1 changed files with 4 additions and 0 deletions
|
|
@ -9020,6 +9020,10 @@ visit_intrinsic(isel_context* ctx, nir_intrinsic_instr* instr)
|
|||
/* "((size - 1) << 11) | register" (SHADER_CYCLES is encoded as register 29) */
|
||||
Temp clock = bld.sopk(aco_opcode::s_getreg_b32, bld.def(s1), ((20 - 1) << 11) | 29);
|
||||
bld.pseudo(aco_opcode::p_create_vector, Definition(dst), clock, Operand::zero());
|
||||
} else if (nir_intrinsic_memory_scope(instr) == NIR_SCOPE_DEVICE &&
|
||||
ctx->options->gfx_level >= GFX11) {
|
||||
bld.sop1(aco_opcode::s_sendmsg_rtn_b64, Definition(dst),
|
||||
Operand::c32(sendmsg_rtn_get_realtime));
|
||||
} else {
|
||||
aco_opcode opcode = nir_intrinsic_memory_scope(instr) == NIR_SCOPE_DEVICE
|
||||
? aco_opcode::s_memrealtime
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue