History log of /external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
ebf33e577aee00cf888c79e11a3b62c181b46510 04-Jan-2017 Eric Anholt <eric@anholt.net> vc4: Flush the job early if we're referencing too many BOs.

If we get up toward 256MB (or whatever the CMA area size is),
VC4_GEM_CREATE will start throwing errors. Even if we don't trigger
that, when we flush the kernel's BO allocation for the CLs or bin
memory may end up throwing an error, at which point our job won't get
rendered at all.

Just flush early (half of maximum CMA size) so that hopefully we never
get to that point.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
7f27ad55974d0bdac4c94a4523a4d42cc75334d5 11-Nov-2016 Eric Anholt <eric@anholt.net> vc4: Try compiling our FSes in multithreaded mode on new kernels.

Multithreaded fragment shaders let us hide texturing latency by a
hyperthreading-style switch to another fragment shader. This gets us up
to 20% framerate improvements on glmark2 tests.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
45c022f2b06967196516f0616a9e4959ddcd14da 17-Nov-2016 Eric Anholt <eric@anholt.net> vc4: Add support for ETC1 textures if the kernel is new enough.

The kernel changes for exposing the param have now been merged, so we can
expose it here.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
96ffee2d02a9cbf7ff0042b3083376724b68ed36 11-Nov-2016 Eric Anholt <eric@anholt.net> vc4: Mark threaded FSes as non-singlethread in the CL.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
755037173d19b65777a97f55455c1f64bf618264 11-Nov-2016 Eric Anholt <eric@anholt.net> vc4: Add support for register allocation for threaded shaders.

We have two major requirements: Make sure that only the bottom half of the
physical reg space is used, and make sure that none of our values are live
in an accumulator across a switch.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
4d019bd703e7c20d56d5b858577607115b4926a3 07-Nov-2016 Eric Anholt <eric@anholt.net> vc4: Don't abort when a shader compile fails.

It's much better to just skip the draw call entirely. Getting this
information out of register allocation will also be useful for
implementing threaded fragment shaders, which will need to retry
non-threaded if RA fails.

Cc: <mesa-stable@lists.freedesktop.org>
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
1c38ee380dc6c847c62e8a83978b31382f55bcff 12-Oct-2016 Eric Anholt <eric@anholt.net> vc4: Move simulator memory management to a u_mm.h heap.

Now we aren't limited to 256MB total allocated across a driver instance,
just 256MB at one time. We're still copying in and out, which should get
fixed.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
78087676c98aa8884ba92e75a0a5306a8f78ad43 12-Oct-2016 Eric Anholt <eric@anholt.net> vc4: Restructure the simulator mode.

Rather than having simulator mode changes scattered around vc4_bufmgr.c
and vc4_screen.c, make vc4_bufmgr.c just call a vc4_simulator_ioctl, which
then dispatches to a corresponding implementation.

This will give the simulator support a centralized place to do tricks like
storing most BOs directly in simulator memory rather than copying in and
out.

This leaves special casing of mmaping BOs and execution, because of the
winsys mapping.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
06cc3dfda49b557b177ea6a5bc4fb87e087df21a 05-Oct-2016 Eric Anholt <eric@anholt.net> vc4: Fix simulator when more than one vc4_screen is opened.

We would assertion fail in setting up the simulator the second time
around. This at least postpones the assertion failure until we've closed
all of the first set of screens and started opening a new set.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
2a83036fe29262c8761812c65d6e81c7198da54e 27-Sep-2016 Nicolai Hähnle <nicolai.haehnle@amd.com> vc4: use the new parent/child pools for transfers

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
f597ac3966405934e13a9aaa18c73211b5a40c7c 08-Sep-2016 Eric Anholt <eric@anholt.net> vc4: Implement job shuffling

Track rendering to each FBO independently and flush rendering only when
necessary. This lets us avoid the overhead of storing and loading the
frame when an application momentarily switches to rendering to some other
texture in order to continue rendering the main scene.

Improves glmark -b desktop:effect=shadow:windows=4 by 27%
Improves glmark -b
desktop:blur-radius=5:effect=blur:passes=1:separable=true:windows=4
by 17%

While I haven't tested other apps, this should help X rendering a lot, and
I've heard GLBenchmark needed it too.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
9688166bd9c3e12c74c55b857ad0dbb62b28da9e 06-Apr-2015 Eric Anholt <eric@anholt.net> vc4: Move the render job state into a separate structure.

This is a preparation step for having multiple jobs being queued up at the
same time.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
21a27ad9569211e48cfd7ad60ac4025ab9f96a7a 10-Sep-2016 Eric Anholt <eric@anholt.net> vc4: Fix incorrect clearing of Z/stencil when cleared separately.

The clear of Z or stencil will end up clearing the other as well, instead
of masking. There's no way around this that I know of, so if we are
clearing just one then we need to draw a quad.

Fixes a regression in the job-shuffling code, where the clear values move
to the job and don't just have the last clear's value laying around when
you do glClear(DEPTH) and then glClear(STENCIL) separately
(ext_framebuffer_multisample-clear 4 depth)).

This causes regressions in ext_framebuffer_multisample/multisample-blit
depth and ext_framebuffer_multisample/no-color depth, but these were
formerly false positives due to the reference image also being black. Now
the reference and test images are both being drawn, and it looks like
there's an incorrect resolve of depth during blitting to an MSAA FBO.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
e7a73b75a0dbd599187b8980b2e1e1cb5dfdaf6d 28-Aug-2016 Marek Olšák <marek.olsak@amd.com> gallium: switch drivers to the slab allocator in src/util
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
e763e19808a84ae0218117c89864ff50cb6b0d16 25-Aug-2016 Eric Anholt <eric@anholt.net> vc4: Add register allocation support for MUL output rotation.

We need the source to be in r0-r3, so make a new register class for it.
It will be up to the surrounding passes to make sure that the r0-r3
allocation of its source won't conflict with anything other class
requirements on that temp.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
2350569a78c60d32e3b751b4386ea7e6d7e2ebe9 03-Aug-2016 Eric Anholt <eric@anholt.net> vc4: Avoid VS shader recompiles by keeping a set of FS inputs seen so far.

We don't want to bake the whole array into the FS key, because of the
hashing overhead. But we can keep a set of the arrays seen, and use a
pointer to the copy in as the array's proxy.

Between this and the previous patch, gl-1.0-blend-func now passes on
hardware, where previously it was filling the 256MB CMA area with shaders
and OOMing.

Drops 712 shaders from shader-db.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
ce8504d196291452b42ed755ed3830ecb16febcd 19-Jul-2016 Eric Anholt <eric@anholt.net> vc4: Disable early Z with computed depth.

We don't tell the hardware whether we're computing depth, so we need
to manage early Z state manually. Fixes piglit early-z.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
3bcd0f1912a60cc9d3813923d18d29465e41ff56 15-Jul-2016 Eric Anholt <eric@anholt.net> vc4: Speed up glGenerateMipmaps by avoiding shadow baselevel.

To support general GL_TEXTURE_BASE_LEVEL we have to copy to a temporary
miptree. However, if a single level is being selected, we can use the
existing miptree and force all the sampling to be from that particular
level.

This avoids a ton of software fallbacks in glGenerateMipmaps(), which uses
base levels in the blit implementation in gallium. Improves "glmark2 -b
terrain" from 2 fps to 3 (perhaps some more precision would be useful?),
and cuts its CPU usage during the benchmarking from ~30% to ~10% (total
CPU time from 8.8s to 7.6s).
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
88152d7dc0e2cf233cd2c38a4e9affb1ea73fa97 15-Jul-2016 Eric Anholt <eric@anholt.net> vc4: Drop VC4_DIRTY_TEXSTATE in favor of the per-stage flags.

The compiler uses the per-stage flags already, so it didn't need this.
vc4_uniforms was using it, so just replace it with both of the stage flags
for now.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
5db82e0c897da46867dec5886bae1607d3124abc 15-Jul-2016 Eric Anholt <eric@anholt.net> vc4: Remove dead dirty_samplers field.

We use a big VC4_DIRTY_FRAGTEX/VC4_DIRTY_VERTEX on the stage, instead.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
0700e4c0c79771a69ceb5f269f684650265ea900 17-May-2016 Eric Anholt <eric@anholt.net> vc4: Drop the dead export_linkage array.

This came from deriving from freedreno.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
21a9ed620764bde2021aa7592cf2695dad8f3f74 15-Apr-2016 Eric Anholt <eric@anholt.net> vc4: Don't flush on read-only access of buffers read by the CL.

Fixes piglit mixed-immediate-and-vbo, and may significantly improve
performance of applications that store a 4-byte IB in the same VBO as
vertex data.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
edfd4d853a0d26bc0cde811de7b20116db7e66fc 22-Jun-2015 Eric Anholt <eric@anholt.net> vc4: Add support for drawing in MSAA.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
70b06fb5d55d639fd74596a2ff6971cb57c030ca 19-Aug-2015 Eric Anholt <eric@anholt.net> vc4: Convert blending to being done in 4x8 unorm normally.

We can't do this all the time, because you want blending to be done in
linear space, and sRGB would lose too much precision being done in 4x8.
The win on instructions is pretty huge when you can, though.

total uniforms in shared programs: 32065 -> 32168 (0.32%)
uniforms in affected programs: 327 -> 430 (31.50%)
total instructions in shared programs: 92644 -> 89830 (-3.04%)
instructions in affected programs: 15580 -> 12766 (-18.06%)

Improves openarena performance at 1920x1080 from 10.7fps to 11.2fps.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
7d7fbcdf4e1683d1aef19c7ee08cc222d8279672 23-Oct-2015 Eric Anholt <eric@anholt.net> vc4: Add a workaround for HW-2116 (state counter wrap fails).

I haven't proven that this happens (I've got other GPU hangs in the
way), but the closed driver also does this and it's documented as an
errata.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
64d9d4b73031d1bc23ae869e2afad86ed01edea5 27-Sep-2015 Boyan Ding <boyan.j.ding@gmail.com> vc4: use nir two-sided-color lowering

Similar to 9ffc1049ca (freedreno/ir3: use nir two-sided-color lowering).
No piglit regression.

Signed-off-by: Boyan Ding <boyan.j.ding@gmail.com>
Reviewed-by: Eric Anholt <eric@anholt.net>
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
cfa980f49356eb2d94178f8cc9d67d01b4e3d695 09-Sep-2015 Eric Anholt <eric@anholt.net> vc4: convert from tgsi semantic/index to varying-slot

(originally part of previous patch, split out to separate patch by Rob)

v2: squash in some fixes from Eric
v3: Another fix from Eric for point coords.

Signed-off-by: Rob Clark <robclark@freedesktop.org>
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
0fc21ecfc0891d239f20bf7724e51bc75503570c 25-Jul-2015 Marek Olšák <marek.olsak@amd.com> gallium: add flags parameter to pipe_screen::context_create

This allows creating compute-only and debug contexts.

Reviewed-by: Brian Paul <brianp@vmware.com>
Acked-by: Christian König <christian.koenig@amd.com>
Acked-by: Alex Deucher <alexander.deucher@amd.com>
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
eb2776504ae32feaf41a5bad9f09f154045e96a3 21-Aug-2015 Eric Anholt <eric@anholt.net> vc4: Actually allow math results to allocate into r4.

I switched us to tracking whether the results *could* go to r4, but then
didn't make a separate register class for the class bits that included r4.
Switch the "any" class to actually be "any", and name the "any but r4"
class more appropriately.

total instructions in shared programs: 96798 -> 94680 (-2.19%)
instructions in affected programs: 62736 -> 60618 (-3.38%)
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
cc8fb2904673588d31b660dbfaf692615b5202dd 31-Jul-2015 Eric Anholt <eric@anholt.net> vc4: Make r4-writes implicitly move to a temp, and allocate temps to r4.

Previously, SFU values always moved to a temporary, and TLB color reads
and texture reads always lived in r4. Instead, we can have these results
just be normal temporaries, and the register allocator can leave the
values in r4 when they don't interfere with anything else using r4.

shader-db results:
total instructions in shared programs: 100809 -> 100040 (-0.76%)
instructions in affected programs: 42383 -> 41614 (-1.81%)
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
2e04492a142102823dfb8fc8599cfd417b84c97a 28-Jul-2015 Eric Anholt <eric@anholt.net> vc4: Skip re-emitting the shader_rec if it's unchanged.

It's a bunch of work for us to emit it (and its uniforms), more work for
the kernel to validate it, and additional work for the CLE to read
it. Improves es2gears framerate by about 50%.

Signed-off-by: Eric Anholt <eric@anholt.net>
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
7124feba1b879deb88dbf2baf600ed42309d9839 14-Jul-2015 Eric Anholt <eric@anholt.net> vc4: Cache the texture p1 for the sampler.

Cuts another 12% of vc4_uniforms.o, in exchange for computing it at
CSO creation time.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
0f4d2b0a2dd3fa39426f2789bf2a8fc939adf001 14-Jul-2015 Eric Anholt <eric@anholt.net> vc4: Cache texture p0/p1 setup for the sampler view.

In exchange for a bit of space and computation in CSO setup, we cut
vc4_uniform.c (draw time) code size by 4.8%.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
1d45e44b2f9e52d6eebe84ab08da6b7393011f95 17-Jun-2015 Eric Anholt <eric@anholt.net> vc4: Move tile state/alloc allocation into the kernel.

This avoids a security issue where userspace could have written the tile
state/tile alloc behind the GPU's back, and will apparently be necessary
for fixing stability bugs (tile state buffers are missing some top bits
for the tile alloc's address).
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
9adcd2d80aceec90b9c3712b53d8e7839dc5634b 10-Jun-2015 Eric Anholt <eric@anholt.net> vc4: Move RCL generation into the kernel.

There weren't that many variations of RCL generation, and this lets us
skip all the in-kernel validation for what we generated.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
10aacf5ae8f3e90e2f0967fbdcf96df93e346e20 15-Apr-2015 Eric Anholt <eric@anholt.net> vc4: Just stream out fallback IB contents.

The idea I had when I wrote the original shadow code was that you'd see a
set_index_buffer to the IB, then a bunch of draws out of it. What's
actually happening in openarena is that set_index_buffer occurs at every
draw, so we end up making a new shadow BO every time, and converting more
of the BO than is actually used in the draw.

While I could maybe come up with a better caching scheme, for now just
do the simple thing that doesn't result in a new shadow IB allocation
per draw.

Improves performance of isosurf in drawelements mode by 58.7967% +/-
3.86152% (n=8).
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
bd957b1b79124c5061af1eddf16932793e806d87 14-Apr-2015 Eric Anholt <eric@anholt.net> vc4: Hook up VC4_DEBUG=perf to some useful printfs.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
43b20795b742b9f1608dd6f2dc586337408760ad 09-Apr-2015 Eric Anholt <eric@anholt.net> vc4: Move the blit code to a separate file.

There will be other blit code showing up, and it seems like the place
you'd look.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
e214a596352e67c89ce379a1e5a060dbc1ce31e1 06-Apr-2015 Eric Anholt <eric@anholt.net> vc4: Separate out a bit of code for submitting jobs to the kernel.

I want to be able to have multiple jobs being set up at the same time (for
example, a render job to do a little fixup blit in the course of doing a
render to the main FBO).
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
af3d7471943d54e692f2dd7448321a4f96e56ed2 24-Mar-2015 Eric Anholt <eric@anholt.net> vc4: Make a new #define for making code conditional on the simulator.

I'd like to compile as much of the device-specific code as possible
when building for simulator, and using if (using_simulator) instead of
ifdefs helps.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
1a328120d334ae09fa6a1ce8b599174f730a9753 11-Jan-2015 Eric Anholt <eric@anholt.net> vc4: Fix up statechange management for uncompiled/compiled FS/VS.

No need to recheck the FS compile when the VS source has changed, but
there *is* a need to recheck the VS compile when the compiled VS has
changed (since the live inputs may change).

Fixes es3conform's blend test.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
b920ecf793bd419558a240014624add08774765d 10-Jan-2015 Eric Anholt <eric@anholt.net> vc4: Cook up the draw-time VPM setup info during shader compile.

This will give the compiler the chance to dead-code eliminate unused VPM
reads. This is particularly a big deal in the CS where a bunch of vattrs
are just not going to be used.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
3ba57bae47666ada1145259755fc326b1b9f9463 28-Dec-2014 Eric Anholt <eric@anholt.net> vc4: Only render tiles where the scissor ever intersected them.

This gives a 2.7x improvement in x11perf -rect100, since we only end up
load/storing the x11perf window, not the whole screen.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
80ed075e6033eba68b034fbd748da4e0b82a27f4 15-Dec-2014 Eric Anholt <eric@anholt.net> vc4: Fix leak of the compiled shader programs in the cache.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
5c9b8eace2b7e92899aae2cad131c0ca05b389e7 15-Dec-2014 Eric Anholt <eric@anholt.net> vc4: Switch to using the util/ hash table.

No performance difference on a microbenchmark with norast that should hit it
enough to have mattered, n=220.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
21577571b37e68edc0422fbf80932588a4614abc 20-Nov-2014 Eric Anholt <eric@anholt.net> vc4: Update for new kernel ABI with async execution and waits.

Our submits now return immediately and you have to manually wait for
things to complete if you want to (like a normal driver).
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
f87c7008958cdb095efa1cfb29ca8f3c9b9066e4 02-Oct-2014 Eric Anholt <eric@anholt.net> vc4: Add support for ARL and indirect register access on TGSI_FILE_CONSTANT.

Fixes 14 ARB_vp tests (which had no lowering done), and should improve
performance of indirect uniform array access in GLSL.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
a71c3b885a532016aa426b5bb753291cffe39a44 24-Oct-2014 Eric Anholt <eric@anholt.net> vc4: Refactor flushing before mapping a BO.

I'm going to want to make some other decisions here before flushing.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
5d32e263357e562779bfc0d2af712d4c7538a32b 22-Oct-2014 Eric Anholt <eric@anholt.net> vc4: Add debug output to match shaderdb info to program dumps.

I'm going to be using VC4_DEBUG=shaderdb,norast to do shaderdb stats, but
when debugging regressions, I want to match shaderdb output to shader
disassembly.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
201d4c0b2a6f7f0c1d59c4fd5cce4916fc48a2d2 15-Oct-2014 Eric Anholt <eric@anholt.net> vc4: Add support for user clip plane and gl_ClipVertex.

Fixes about 15 piglit tests about interpolation and clipping.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
5d72a1c95662109b1338605da83329dd25e00859 13-Oct-2014 Eric Anholt <eric@anholt.net> vc4: Match VS outputs to FS inputs.

If the VS doesn't output a value that the FS needs, we still need to read
the right contents for the remaining FS inputs, by emitting padding. And
if the VS outputs something the FS doesn't need, we shouldn't put it in
the VPM at all (so the code producing it can get DCEed).

Fixes 77 piglit tests.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
d09509da2aa5ff709c48bdc4163a2c57811c70ab 10-Oct-2014 Eric Anholt <eric@anholt.net> vc4: Don't look up the compiled shaders unless state has changed.

Improves simulated norast performance on a little benchmark by 38.0965%
+/- 3.27534% (n=11).
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
c4b0dd53568fa276079f6b6bf7ba4b857ddd65a5 02-Oct-2014 Eric Anholt <eric@anholt.net> vc4: Split the coordinate shader to its own vc4_compiled_shader.

Merging VS and CS into the same struct wasn't winning us anything except
for not allocating a separate BO (but if we want to pack programs into
BOs, we should pack not just those 2 programs together). What it was
getting us was a bunch of code duplication about hash table lookups and
propagating vc4_compile contents into a vc4_compiled_shader.

I was about to make the situation worse with indirect uniform buffer
access.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
581418585e5dee3cca1b42c472b72aa9c74140bb 01-Oct-2014 Eric Anholt <eric@anholt.net> vc4: Add support for two-sided color.

It's fairly easy, thanks to Rob Clark's lowering code. Fixes
two-sided-lighting and 4 vertex-program-two-side testcases, while
regressing 8 testcases that involve enabling two-sided color while only
initializing one of the two colors in the VS. If you're enabling two
sided color, it's of course expected that you really do set up both
colors, so this is still an improvement (and when we set up a linker for
TGSI, we'll hopefully fix those 8 fails).
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
b65761f764f2c03b375460b3d6e36227ec161c2d 29-Sep-2014 Eric Anholt <eric@anholt.net> vc4: Add the necessary stubs for occlusion queries.

We have to expose them for GL 2.0, but we just always return a value of 0.
We should be advertising 0 query bits instead of 64, but gallium doesn't
have plumbing for that yet. At least this stops the segfaults.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
7fa399f93af288bc0b9764819d4e5b6184e75d78 24-Sep-2014 Eric Anholt <eric@anholt.net> vc4: Actually add support for polygon offset.

Setting the bit without setting the offset values is kind of useless.
Fixes piglit polygon-offset (but not polygon-mode-offset).
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
45b104e0a228595142ed4bc62bbc8948100b9325 24-Sep-2014 Eric Anholt <eric@anholt.net> vc4: Add support for flat shading.

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.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
71e5ba9c011939c962018af7f3ca78b600c95148 22-Sep-2014 Eric Anholt <eric@anholt.net> vc4: Switch to using Mesa's register allocator.

This will let me more reliably allocate a-file registers, which are going
to be even more in demand when I start using a-file unpacks.

Also fixes a bug where the reservation of payload registers (FRAG_Z/W) was
off by one but just caused failure to register allocate at all if the
off-by-one was fixed.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
19589147ef660c0bf7fcc52ca82dfbbadf3a9a23 18-Sep-2014 Eric Anholt <eric@anholt.net> vc4: Add support for stencil operations.

While depth test state is passed through the fragment shader as sideband,
data, the stencil test state has to be set by the fragment shader itself.

Many tests are still failing, but this gets most of hiz/ passing.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
ad02ba42f0931abfdb79af29678267bd063e92f3 15-Sep-2014 Eric Anholt <eric@anholt.net> vc4: Move register allocation to a separate file.

I'm going to be rewriting it all, and having it mixed up with the
QIR-to-QPU opcode translation was messy.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
5774f164532ac85d213469f688ea87e1da16d444 05-Sep-2014 Eric Anholt <eric@anholt.net> vc4: Fill out the stencil clear field.

The rest of stencil handling isn't done yet, but it documents an extra
cl_u8(0) and helps make it obvious why we don't need to format clear_depth
the same way the depth/stencil buffer is formatted.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
4bca922878a4d433077d21d4918b1db71b3a15f7 13-Aug-2014 Eric Anholt <eric@anholt.net> vc4: Merge qcompile and tgsi_to_qir

The split between these two didn't make much sense. I'm going to want the
chance to look at uniform contents in optimization passes, and the QPU
emit I think is going to end up rewriting the uniforms stream.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
b064c9103d8fc0bb4ae8fe597b4d9de82a274638 20-Aug-2014 Eric Anholt <eric@anholt.net> vc4: Add support for all the texture and FBO formats we can.

Now that tiling is in place, we can expose the other formats. Depth is
still broken (need to make changes in the shader), but if you don't expose
it things crash all over. SNORM is dropped, but we could re-add it later
with some shader fixes to handle converting between [0,1] and [-1,1].
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
b0a1e401a93b7b13870b936bc667b3fc15dba6d5 19-Aug-2014 Eric Anholt <eric@anholt.net> vc4: Include stdio/stdlib in headers so I don't have to include it per file.

There are a few tools I want to have always available, and fprintf() and
abort() are among them.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
ba875b3a0d8119fda030dfdc28cd831d9ca51e08 13-Aug-2014 Eric Anholt <eric@anholt.net> vc4: Consume the implicit varyings for points and lines.

We were triggering simulator assertion failures for not consuming these,
and presumably we want to actually make use of them some day (for things
like point/line antialiasing)

Note that this has the qreg index as 0, which is the same index as the
first GL varyings read. This doesn't matter currently, since that number
isn't used for anything except dumping.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
64ad96a9f4dec0724d7276d32de59cc621fccb55 13-Aug-2014 Eric Anholt <eric@anholt.net> vc4: Move the deref of the color buffer for simulator into the simulator.

At some point I'm going to want to move the information necessary for the
host buffer upload/download into the BO so that it's independent of the
current vc4->framebuffer, but for now this fixes pointless derefs on
non-simulator in vc4_context.c since the dump_fbo() removal
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
4160ac5ee41630a5c9fc4e1f3520f0fabf42cb14 01-Aug-2014 Eric Anholt <eric@anholt.net> vc4: Add support for depth clears and tests within a tile.

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.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
2259cc5aebcb16636b1399dd438beed9d9867e67 02-Aug-2014 Eric Anholt <eric@anholt.net> vc4: Avoid flushing when mapping buffers that aren't in the batch.

This should prevent a bunch of unnecessary flushes for things like
updating immediate vertex data.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
027d730aff4abf89f8c01049d245c670c6740a26 31-Jul-2014 Eric Anholt <eric@anholt.net> vc4: Keep a reference to BOs queued for rendering.

Otherwise, once we're not flushing at the end of every draw, we'll free
things like gallium resources, and free the backing GEM object, before
we've flushed the rendering using it to the kernel.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
165ca6b5ad4fbd20798b6bd8120504761865436c 23-Jul-2014 Eric Anholt <eric@anholt.net> vc4: Track clears veresus uncleared draws, and the clear color.

This is a step toward queueing more than one draw per frame.

Fixes piglit attribute0 test, since we get a working clear color now.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
a8f2bf0f51222a96a49dfb3d6f9b36d3e54d08cd 21-Jul-2014 Eric Anholt <eric@anholt.net> vc4: Rewrite the kernel ABI to support texture uniform relocation.

This required building a shader parser that would walk the program to find
where the texturing-related uniforms are in the uniforms stream.

Note that as of this commit, a new kernel is required for rendering on
actual VC4 hardware (currently that commit is named "drm/vc4: Introduce
shader validation and better command stream validation.", but is likely to
be squashed as part of an eventual merge of the kernel driver).
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
a3cd3c0d198374647df3db83198e8ce0cddcb6b7 18-Jul-2014 Eric Anholt <eric@anholt.net> vc4: Switch simulator to using kernel validator

This ensures that when I'm using the simulator, I get a closer match to
what behavior on real hardware will be. It lets me rapidly iterate on the
kernel validation code (which otherwise has a several-minute turnaround
time), and helps catch buffer overflow bugs in the userspace driver
faster.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
a02c658908384b81e9d27e2555ba2fce2cc0f6a8 18-Jul-2014 Eric Anholt <eric@anholt.net> vc4: Drop pointless shader state struct
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
66c6c401279aa4152a24681f64d0e101aa004593 15-Jul-2014 Eric Anholt <eric@anholt.net> vc4: Add support for texturing (under simulation)

Only rgba8888 works, and only a single texture unit, and it's only under
simulation because I haven't built the kernel interface yet.

v2: Rebase on helpers.
v3: Fold in the don't-break-the-arm-build fix.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
c29392751180e21a2857cade8d0b4902cbe9d001 04-Jul-2014 Eric Anholt <eric@anholt.net> vc4: Add WIP support for varyings.

It doesn't do all the interpolation yet, but more tests can run now.

v2: Rebase on helpers.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
cf2d777fbe7fd87f9076d4bc0ad639b33e7ffb70 01-Jul-2014 Eric Anholt <eric@anholt.net> vc4: Add shader variant caching to handle FS output swizzle.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
c3f96060a8d1ebc9caa7053592e80155a5266e92 28-Jun-2014 Eric Anholt <eric@anholt.net> vc4: Don't reallocate the tile alloc/state bos every frame.

This was a problem for the simulator since we don't free memory back to
it, and it would soon just run out.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
7108c24fd02a76f3efef4ba5d9aefdf0704ab0d8 27-Jun-2014 Eric Anholt <eric@anholt.net> vc4: Use the user's actual first vertex attribute.

This is hardcoded to read it as RGBA32F so far, but starts to get more
tests working.
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
792d1c92df6f58f219eb8b77e668424cdcc9c9af 27-Jun-2014 Eric Anholt <eric@anholt.net> vc4: Switch to actually generating vertex and fragment shader code from TGSI.

This introduces an IR (QIR, for QPU IR) to do optimization on. It's a
scalar, SSA IR in general. It looks like optimization is pretty easy this
way, though I haven't figured out if it's going to be good for our weird
register allocation or not (or if I want to reduce to basically QPU
instructions first), and I've got some problems with it having some
multi-QPU-instruction opcodes (SEQ and CMP, for example) which I probably
want to break down.

Of course, this commit mostly doesn't work, since many other things are
still hardwired, like the VBO data.

v2: Rewrite to use a bunch of helpers (qir_OPCODE) for emitting QIR
instructions into temporary values, and make qir_inst4 take the 4 args
separately instead of an array (all later callers wanted individual
args).
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
e59890aebbad990a02c2c27531525804de47115d 24-Jun-2014 Eric Anholt <eric@anholt.net> vc4: Start converting the driver to use vertex shaders.

Note: This is the cutoff point where I switched from developing primarily
on the Pi to developing o the simulator. As a result, from this point on
the code is untested on the Pi (the kernel code I have currently wasn't
rendering anything at this commit, though the simulator renders
successfully, suggesting kernel bugs).
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h
1850d0a1cbf044dc4d29b7a9ede2c634f667d853 19-Jun-2014 Eric Anholt <eric@anholt.net> vc4: Initial skeleton driver import.

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)
/external/mesa3d/src/gallium/drivers/vc4/vc4_context.h