Commit Graph

75 Commits

Author SHA1 Message Date
Dave Airlie
9d39e69219 iris: fix some hangs around null framebuffers
This fixes some cases in fbo-none* and framebuffer_no_attachments.

I'm not sure this is correct otherwise, the tests don't all pass yet

No idea if this is in any way the correct answer
2019-02-21 10:26:08 -08:00
Kenneth Graunke
870f2e8434 iris: implement texture/memory barriers 2019-02-21 10:26:07 -08:00
Kenneth Graunke
b7b061c4e2 iris: fix SSBO indexing
st/nir offsets SSBO indexes by MaxABOs.  This is not what we want,
as it bloats the binding tables.  We'll need to adjust it to use
info->num_abos as the offset and buffer base instead.  For now,
just use the inefficient format to get us rolling.  We can add a
PIPE_CAP later.
2019-02-21 10:26:07 -08:00
Kenneth Graunke
77b9219818 iris: unbind compiled shaders if none are present
avoids the case where you have a stale compiled shader bound, but no
uncompiled shader bound, which is not just boats, but an entire marina
2019-02-21 10:26:07 -08:00
Kenneth Graunke
2d5f545464 iris: implement set_shader_buffers
for SSBOs/ABOs.  We just stream out SURFACE_STATE for now...since it's
a set_* API...and the buffer offset may change...not sure where else
we'd do it.
2019-02-21 10:26:07 -08:00
Kenneth Graunke
541cb60e7e iris: export get_shader_info 2019-02-21 10:26:07 -08:00
Kenneth Graunke
5520a54bc5 iris: vertex ID, instance ID 2019-02-21 10:26:07 -08:00
Kenneth Graunke
d223b316ad iris: NOS mechanics 2019-02-21 10:26:07 -08:00
Kenneth Graunke
b030671298 iris: fix CC_VIEWPORT
I was confusing depth bounds test with depth clamping
2019-02-21 10:26:07 -08:00
Kenneth Graunke
7b8c0f058e iris: actually pin the buffers 2019-02-21 10:26:07 -08:00
Kenneth Graunke
cef0b8b13b iris: streamout 2019-02-21 10:26:07 -08:00
Kenneth Graunke
5c00f5fdca iris: Implement 3DSTATE_SO_DECL_LIST 2019-02-21 10:26:07 -08:00
Kenneth Graunke
a3f77eceb4 iris: slab allocate transfers
apparently we need this for u_threaded_context
2019-02-21 10:26:07 -08:00
Kenneth Graunke
7f39f4843f iris: SBE change stash
not used yet, but want to flag it so I don't forget
2019-02-21 10:26:07 -08:00
Kenneth Graunke
8a080223e6 iris: just malloc one iris_genx_state instead of a bunch of oddball pieces
Things that are gen-specific can go in iris_genx_state.  Things that are
gen-agnostic can go directly in ice->state.
2019-02-21 10:26:07 -08:00
Kenneth Graunke
a7e0edffb6 iris: dead pointer 2019-02-21 10:26:07 -08:00
Kenneth Graunke
ccec5bab5b iris: implement border color, fix other sampler nonsense 2019-02-21 10:26:07 -08:00
Kenneth Graunke
1cea195a95 iris: state ref tuple 2019-02-21 10:26:07 -08:00
Kenneth Graunke
c0e80a8d0a iris: null surface for unbound textures
avoids crashes...may not be really right
2019-02-21 10:26:07 -08:00
Kenneth Graunke
72416a2d0d iris: clears 2019-02-21 10:26:07 -08:00
Kenneth Graunke
81f899c148 iris: scissor count fixes 2019-02-21 10:26:07 -08:00
Kenneth Graunke
5f722bf7c4 iris: remove 4 bytes of padding in iris_compiled_shader 2019-02-21 10:26:07 -08:00
Kenneth Graunke
23987df412 iris: some dirty fixes
two scissor bits, constants not being flagged, ZeroRTA, clip not being
flagged
2019-02-21 10:26:07 -08:00
Kenneth Graunke
ccf37c7da9 iris: bindings dirty tracking 2019-02-21 10:26:07 -08:00
Kenneth Graunke
80dee31846 iris: save pointers to streamed state resources
will be used for cross-batch validation list fixing
2019-02-21 10:26:06 -08:00
Kenneth Graunke
9247546181 iris: state cleaning 2019-02-21 10:26:06 -08:00
Kenneth Graunke
90046b43cc iris: make surface states for cbufs 2019-02-21 10:26:06 -08:00
Kenneth Graunke
4e007dbb30 iris: have more than one const_offset 2019-02-21 10:26:06 -08:00
Kenneth Graunke
9ea05ccf1f iris: completely rewrite binder
now we get a new one per batch, and flush if it fills up
2019-02-21 10:26:06 -08:00
Kenneth Graunke
26cc609927 iris: better ubo handling 2019-02-21 10:26:06 -08:00
Kenneth Graunke
7fb7704b2e iris: more depth stuffs...
still missing stencil
2019-02-21 10:26:06 -08:00
Kenneth Graunke
e2ba98ba39 iris: more blorp 2019-02-21 10:26:06 -08:00
Kenneth Graunke
698d45b725 iris: more blitting code to make readpixels work 2019-02-21 10:26:06 -08:00
Kenneth Graunke
c9d9e44720 iris: bits of blorp code 2019-02-21 10:26:06 -08:00
Kenneth Graunke
60d708bb80 iris: copy over i965's cache tracking
needed to split out vtbl so I can pipe control without ice
2019-02-21 10:26:06 -08:00
Kenneth Graunke
21acc00490 iris: crazy pipe control code
imported from ~kwg/mesa pcx-2, gen < 8 code dropped
2019-02-21 10:26:06 -08:00
Kenneth Graunke
5d2673ba7e iris: set sampler views 2019-02-21 10:26:05 -08:00
Kenneth Graunke
0707ff3f2f iris: assemble SAMPLER_STATE table at bind time
It's useless to allocate SAMPLER_STATEs in GPU memory on creation like
we do for SURFACE_STATES, because they need to be organized into a
contiguous block of memory.  But we can do that at bind time, rather
than draw time.
2019-02-21 10:26:05 -08:00
Kenneth Graunke
6cbd1d1692 iris: binders 2019-02-21 10:26:05 -08:00
Kenneth Graunke
68229caa38 iris: more uploaders 2019-02-21 10:26:05 -08:00
Kenneth Graunke
a50a3a8edf iris: uniform bits...badly 2019-02-21 10:26:05 -08:00
Kenneth Graunke
bb3c0be7a8 iris: dummy constants 2019-02-21 10:26:05 -08:00
Kenneth Graunke
538decc0de iris: URB configs. 2019-02-21 10:26:05 -08:00
Kenneth Graunke
b1115799e6 iris: actually set KSP offsets 2019-02-21 10:26:05 -08:00
Kenneth Graunke
9437e135ed iris: rewrite program cache to use u_upload_mgr 2019-02-21 10:26:05 -08:00
Kenneth Graunke
67ca2be992 iris: no NEW_SBA 2019-02-21 10:26:05 -08:00
Kenneth Graunke
bba13b1501 iris: move key pop to state module
shader key population needs to read state
2019-02-21 10:26:05 -08:00
Kenneth Graunke
5864c9414a iris: fix SBA 2019-02-21 10:26:05 -08:00
Kenneth Graunke
5ae278da18 iris: use vtbl to avoid multiple symbols, fix state base address 2019-02-21 10:26:05 -08:00
Kenneth Graunke
c493fee73f iris: drop const from prog data parameters
we ralloc steal things, which makes it a little bogus
2019-02-21 10:26:05 -08:00