mirror of
https://github.com/boykopovar/AnyPS5.git
synced 2026-10-23 00:53:02 -05:00
llvmpipe builds the high dword of the shader clock with a left shift by 32 (emit_clock in Mesa's lp_bld_nir_soa.c), so it is always 0 and s_memtime and s_memrealtime wrap every 2^32 ns. A pass of agc_driver_shader_clock whose two reads straddle a wrap failed with "memtime: lane N went back from 4294921902 to 3823"; dispatching right before the boundary fails every lane of that pass. On llvmpipe compare the low dwords modulo 2^32, which stays correct if Mesa fixes the shift. Other devices keep the 64-bit comparison. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Ha6Tsy62AFUyp9a5Mf7vjA