summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/vc4/vc4_emit.c
AgeCommit message (Collapse)AuthorFilesLines
2017-07-25broadcom/vc4: Switch the Viewport Center fields to a fixed-point representation.Eric Anholt1-2/+2
This gets us automatic CL decoding to a floating-point value, and drops a magic number from the emit code. 250x250 shader runner tests now say they have a center of 125.0 instead of 2000.
2017-06-30vc4: Move rasterizer state packing to CSO creation time.Eric Anholt1-14/+1
This gets our vc4_emit.c size back down a bit: before: 1020 0 0 1020 3fc src/gallium/drivers/vc4/.libs/vc4_emit.o after: 968 0 0 968 3c8 src/gallium/drivers/vc4/.libs/vc4_emit.o
2017-06-30vc4: Simplify pack header usageEric Anholt1-11/+10
Take the CL pointer in, which will be useful for enabling relocs. However, our code expands a bit more: before: 4449 0 0 4449 1161 src/gallium/drivers/vc4/.libs/vc4_draw.o 988 0 0 988 3dc src/gallium/drivers/vc4/.libs/vc4_emit.o after: 4481 0 0 4481 1181 src/gallium/drivers/vc4/.libs/vc4_draw.o 1020 0 0 1020 3fc src/gallium/drivers/vc4/.libs/vc4_emit.o
2017-06-30vc4: Start using the pack header.Eric Anholt1-24/+41
This slightly inflates the size of the generated code, in exchange for getting us some convenient tools. before: 4389 0 0 4389 1125 src/gallium/drivers/vc4/.libs/vc4_draw.o 808 0 0 808 328 src/gallium/drivers/vc4/.libs/vc4_emit.o after: 4449 0 0 4449 1161 src/gallium/drivers/vc4/.libs/vc4_draw.o 988 0 0 988 3dc src/gallium/drivers/vc4/.libs/vc4_emit.o
2016-11-22vc4: Disable MSAA rasterization when the job binning is single-sampled.Eric Anholt1-2/+13
Gallium core just changed to start setting MSAA enabled in the rasterizer state even with samples==1 buffers. This caused disagreements in our driver between binning and rasterization state, which the simulator threw assertion failures about. Keep the single-sampled samples==1 behavior for now.
2016-09-14vc4: Move the render job state into a separate structure.Eric Anholt1-9/+10
This is a preparation step for having multiple jobs being queued up at the same time.
2016-07-26vc4: Disable early Z with computed depth.Eric Anholt1-2/+4
We don't tell the hardware whether we're computing depth, so we need to manage early Z state manually. Fixes piglit early-z.
2015-12-08vc4: Add a workaround for HW-2905, and additional failure I saw with MSAA.Eric Anholt1-2/+16
I only stumbled on this while experimenting due to reading about HW-2905. I don't know if the EZ disable in the Z-clear is actually necessary, but go with it for now.
2015-12-05vc4: Fix accidental scissoring when scissor is disabled.Eric Anholt1-5/+23
Even if the rasterizer has scissor disabled, we'll have whatever vc4->scissor bounds were last set when someone set up a scissor, so we shouldn't clip to them in that case. Fixes piglit fbo-blit-rect, and a lot of MSAA tests once they're enabled.
2015-07-14vc4: Fix some -Wdouble-promotion warnings.Eric Anholt1-4/+4
No code generation changes from this, but it'll be useful to have this next time I go checking -Wdouble-promotion.
2015-07-14vc4: Rework cl handling to be friendlier to the compiler.Eric Anholt1-27/+30
Drops 680 bytes of code, from avoiding a bunch of extra updates to the next pointer in the struct.
2014-12-30vc4: Only render tiles where the scissor ever intersected them.Eric Anholt1-2/+9
This gives a 2.7x improvement in x11perf -rect100, since we only end up load/storing the x11perf window, not the whole screen.
2014-12-11vc4: Fix triangle-guardband-viewport piglit test.Eric Anholt1-5/+14
The original Broadcom driver also did this with the viewport.
2014-09-24vc4: Add support for point size setting.Eric Anholt1-0/+3
This is the support for both the global and per-vertex modes.
2014-09-24vc4: Add support for line width setting.Eric Anholt1-0/+3
I don't see piglit tests for it, but this should be better than not emitting it at all.
2014-09-24vc4: Actually add support for polygon offset.Eric Anholt1-0/+6
Setting the bit without setting the offset values is kind of useless. Fixes piglit polygon-offset (but not polygon-mode-offset).
2014-09-23vc4: Add support for flat shading.Eric Anholt1-0/+6
This is just the GL 1.1 flat shading of colors -- we don't need to support TGSI constant interpolation bits, because we don't do GLSL 1.30. Fixes 7 piglit tests.
2014-08-11vc4: Add support for depth clears and tests within a tile.Eric Anholt1-4/+10
This doesn't load/store the Z contents across submits yet. It also disables early Z, since it's going to require tracking of Z functions across multiple state updates to track the early Z direction and whether it can be used. v2: Move the key setup to before the search for the key.
2014-08-08vc4: Initial skeleton driver import.Eric Anholt1-0/+59
This mostly just takes every draw call and turns it into a sequence of commands that clear the FBO and draw a single shaded triangle to it, regardless of the actual input vertices or shaders. I copied the initial driver skeleton mostly from freedreno, and I've preserved Rob Clark's copyright for those. I also based my initial hardcoded shaders and command lists on Scott Mansell (phire)'s "hackdriver" project, though the bit patterns of the shaders emitted end up being different. v2: Rebase on gallium megadrivers changes. v3: Rebase on PIPE_SHADER_CAP_MAX_CONSTS change. v4: Rely on simpenrose actually being installed when building for simulation. v5: Add more header duplicate-include guards. v6: Apply Emil's review (protection against vc4 sim and ilo at the same time, and dropping the dricommon drm bits) and fix a copyright header (thanks, Roland)