Skip to content

zink: cap driver inlining using ssa allocation limit

Mike Blumenkrantz requested to merge zmike/mesa:zink-inline into main

usually inlining is optimal for cpu drivers since the majority of time is spent in the shaders, and any amount of reduction to shader code will be optimal

if, however, the shaders are still really big after inlining, this improvement will be negated by the insane amount of time spent doing stupid llvm optimizer passes, so check post-inline size to see whether it exceeds a size threshold

lavapipe release build - 1700% improvement

  • spec@arb_tessellation_shader@execution@variable-indexing@tcs-output-array-vec4-index-rd-after-barrier

before: 142.15s user 0.42s system 99% cpu 2:23.14 total

after: 8.60s user 0.07s system 99% cpu 8.677 total

fixes #6647 (closed)

Merge request reports