diff options
author | Eric Anholt <[email protected]> | 2016-03-15 13:53:02 -0700 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2016-07-12 17:42:39 -0700 |
commit | 54800bb71c874bc7e9953a2e6d29ea53915f5be7 (patch) | |
tree | 1539b95c3be9b7d015cfbe30642ad0e11db570a2 /src/util/Makefile.am | |
parent | e2d7760df5a65ce6ab119e026725c809b8e8bfe3 (diff) |
vc4: Add kernel support for branching in shader validation.
We're already checking that branch instructions are within the
contents of the shader and the proper PROG_END sequence is present.
The other thing we need in the presence of branching is to verify that
the shader doesn't overflow past the end of the uniforms stream.
To do that, we require that at the start of any basic block reading
uniforms have the following instructions:
load_imm temp, <offset within uniform stream>
add unif_addr, temp, unif
The instructions are generated by userspace, and the kernel verifies
that the load_imm is of the expected offset, and that the add adds it
to a uniform. We track which uniform in the stream that is, and at
draw call time fix up the uniform stream to have the address of the
start of the shader's uniforms for that draw call.
Signed-off-by: Eric Anholt <[email protected]>
Diffstat (limited to 'src/util/Makefile.am')
0 files changed, 0 insertions, 0 deletions