Numbers from a shared boot carry the other VMs' unknown load, and a regression that shows only under contention (a slow or missed wake) needs a load that is the same each time. gpuload, a headless Vulkan compute loop built on the lane host, keeps the GPU busy a fixed share of every 10 ms; the bench boot starts it by its pid before the guest's run and stops it after the drags, and records the duty it reached. --bench-phases picks the bench boot's phases. Each boot also records the host's load average beside its measurements: other work's CPU and memory use, which the GPU lock does not cover, moves the numbers of the Vulkan platform's imported host RAM.
17 lines
467 B
Plaintext
17 lines
467 B
Plaintext
#version 450
|
|
// gpuload's dispatch (gpuload.c): ITERS dependent FMAs a thread, the result stored so the loop stays.
|
|
layout(local_size_x = 256) in;
|
|
layout(push_constant) uniform Push { uint iters; } p;
|
|
layout(std430, binding = 0) buffer Out { float v[]; } o;
|
|
|
|
void main()
|
|
{
|
|
uint i = gl_GlobalInvocationID.x;
|
|
float x = float(i) * 1e-6, y = 1.0;
|
|
for (uint k = 0u; k < p.iters; k++) {
|
|
x = fma(x, 1.000001, 0.5);
|
|
y = fma(y, x, -0.25);
|
|
}
|
|
o.v[i & 1023u] = x + y;
|
|
}
|