mesa.git
5 years agoiris: Don't reserve new binding table section unless things are dirty
Kenneth Graunke [Wed, 25 Jul 2018 05:14:37 +0000 (22:14 -0700)]
iris: Don't reserve new binding table section unless things are dirty

5 years agoiris: implement texture/memory barriers
Kenneth Graunke [Wed, 25 Jul 2018 04:15:13 +0000 (21:15 -0700)]
iris: implement texture/memory barriers

5 years agoiris: drop unused bo parameter
Kenneth Graunke [Wed, 25 Jul 2018 04:03:52 +0000 (21:03 -0700)]
iris: drop unused bo parameter

5 years agoiris: update bindings when changing programs
Kenneth Graunke [Wed, 25 Jul 2018 03:57:10 +0000 (20:57 -0700)]
iris: update bindings when changing programs

the binding table layout depends on program info.

not known to fix anything yet.

5 years agoiris: fix for disabling ssbos
Kenneth Graunke [Wed, 25 Jul 2018 03:57:02 +0000 (20:57 -0700)]
iris: fix for disabling ssbos

5 years agoiris: fix SSBO indexing
Kenneth Graunke [Wed, 25 Jul 2018 00:44:09 +0000 (17:44 -0700)]
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.

5 years agoiris: enable SSBOs
Kenneth Graunke [Wed, 25 Jul 2018 00:03:48 +0000 (17:03 -0700)]
iris: enable SSBOs

5 years agoiris: fix TBO alignment to match 965
Kenneth Graunke [Wed, 25 Jul 2018 00:02:25 +0000 (17:02 -0700)]
iris: fix TBO alignment to match 965

5 years agoiris: unbind compiled shaders if none are present
Kenneth Graunke [Tue, 24 Jul 2018 23:20:02 +0000 (16:20 -0700)]
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

5 years agoiris: shorten loop
Kenneth Graunke [Tue, 24 Jul 2018 23:11:37 +0000 (16:11 -0700)]
iris: shorten loop

num_ubos doesn't include Tim's magic UBO for regular uniforms, so +1

5 years agoiris: emit binding table for atomic counters and SSBOs
Kenneth Graunke [Tue, 24 Jul 2018 23:03:32 +0000 (16:03 -0700)]
iris: emit binding table for atomic counters and SSBOs

5 years agoiris: implement set_shader_buffers
Kenneth Graunke [Tue, 24 Jul 2018 22:54:00 +0000 (15:54 -0700)]
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.

5 years agoiris: export get_shader_info
Kenneth Graunke [Tue, 24 Jul 2018 22:04:39 +0000 (15:04 -0700)]
iris: export get_shader_info

5 years agoiris: fix msaa flipping filters
Kenneth Graunke [Tue, 24 Jul 2018 21:52:50 +0000 (14:52 -0700)]
iris: fix msaa flipping filters

5 years agoiris: expose more things that we already support
Kenneth Graunke [Tue, 24 Jul 2018 21:49:13 +0000 (14:49 -0700)]
iris: expose more things that we already support

5 years agoiris: fix blorp filters
Kenneth Graunke [Tue, 24 Jul 2018 21:31:07 +0000 (14:31 -0700)]
iris: fix blorp filters

we have to switch to blorp enums after the rebase, but also we were
probably doing it wrong for MSAA before this.

5 years agoiris: hack around samples confusion
Kenneth Graunke [Tue, 24 Jul 2018 17:59:10 +0000 (10:59 -0700)]
iris: hack around samples confusion

5 years agoiris: point sprite enables
Kenneth Graunke [Mon, 23 Jul 2018 22:29:00 +0000 (15:29 -0700)]
iris: point sprite enables

5 years agoiris: reemit blend state for alpha test function changes
Kenneth Graunke [Sun, 22 Jul 2018 03:47:08 +0000 (20:47 -0700)]
iris: reemit blend state for alpha test function changes

fixes bin/fbo-alphatest-formats GL_EXT_texture_snorm

5 years agoiris: fix Z24
Kenneth Graunke [Sun, 22 Jul 2018 03:12:15 +0000 (20:12 -0700)]
iris: fix Z24

This was backwards.

thanks to Jason Ekstrand for realizing that I was seeing the wrong bits.

5 years agoiris: fix EmitNoIndirect
Kenneth Graunke [Fri, 20 Jul 2018 08:18:57 +0000 (01:18 -0700)]
iris: fix EmitNoIndirect

we were using pipe stages, which are ordered dumbly for historical
reasons.  we want gl_shader_stage here.  this got us the wrong options

5 years agoiris: assert about passthrough shaders to make this easier to detect
Kenneth Graunke [Fri, 20 Jul 2018 07:47:40 +0000 (00:47 -0700)]
iris: assert about passthrough shaders to make this easier to detect

otherwise it just silently fails and looks like some obscure problem

5 years agoiris: fill out MAX_PATCH_VERTICES
Kenneth Graunke [Thu, 19 Jul 2018 04:08:32 +0000 (21:08 -0700)]
iris: fill out MAX_PATCH_VERTICES

5 years agoiris: fix SGVS when there are no valid vertex elements
Kenneth Graunke [Wed, 18 Jul 2018 23:27:07 +0000 (16:27 -0700)]
iris: fix SGVS when there are no valid vertex elements

tessellation nop.shader_test now passes

5 years agoiris: vertex ID, instance ID
Kenneth Graunke [Wed, 18 Jul 2018 16:23:24 +0000 (09:23 -0700)]
iris: vertex ID, instance ID

5 years agoiris: don't emit SO_BUFFERS and SO_DECL_LIST unless streamout is enabled
Kenneth Graunke [Wed, 18 Jul 2018 16:02:35 +0000 (09:02 -0700)]
iris: don't emit SO_BUFFERS and SO_DECL_LIST unless streamout is enabled

Otherwise on the first draw, if XFB isn't enabled, we get a pile of
MI_NOOPS where SO_BUFFERS should be

5 years agoiris: compile a TCS...don't bother with passthrough yet
Kenneth Graunke [Tue, 17 Jul 2018 21:21:42 +0000 (14:21 -0700)]
iris: compile a TCS...don't bother with passthrough yet

5 years agoiris: TES program key inputs
Kenneth Graunke [Tue, 17 Jul 2018 21:01:58 +0000 (14:01 -0700)]
iris: TES program key inputs

5 years agoiris: fix texture buffer stride
Kenneth Graunke [Tue, 17 Jul 2018 15:59:25 +0000 (08:59 -0700)]
iris: fix texture buffer stride

5 years agoiris: fix sampler views of TBOs
Kenneth Graunke [Tue, 17 Jul 2018 07:17:55 +0000 (00:17 -0700)]
iris: fix sampler views of TBOs

we can't read levels/layers, they're invalid for PIPE_BUFFER

5 years agoiris: fix crash
Kenneth Graunke [Mon, 16 Jul 2018 23:45:22 +0000 (16:45 -0700)]
iris: fix crash

5 years agoiris: record FS NOS
Kenneth Graunke [Mon, 16 Jul 2018 23:41:23 +0000 (16:41 -0700)]
iris: record FS NOS

5 years agoiris: NOS mechanics
Kenneth Graunke [Mon, 16 Jul 2018 23:21:22 +0000 (16:21 -0700)]
iris: NOS mechanics

5 years agoiris: bind state helper function
Kenneth Graunke [Mon, 16 Jul 2018 23:25:02 +0000 (16:25 -0700)]
iris: bind state helper function

5 years agoiris: s/hwcso/state/g
Kenneth Graunke [Mon, 16 Jul 2018 23:21:41 +0000 (16:21 -0700)]
iris: s/hwcso/state/g

5 years agoiris: bits of multisample program key
Kenneth Graunke [Mon, 16 Jul 2018 22:36:34 +0000 (15:36 -0700)]
iris: bits of multisample program key

5 years agoiris: save query type
Kenneth Graunke [Sun, 15 Jul 2018 23:20:16 +0000 (16:20 -0700)]
iris: save query type

5 years agoiris: draw indirect support?
Kenneth Graunke [Sun, 15 Jul 2018 05:15:39 +0000 (22:15 -0700)]
iris: draw indirect support?

5 years agoiris: fix CC_VIEWPORT
Kenneth Graunke [Sat, 14 Jul 2018 08:29:33 +0000 (01:29 -0700)]
iris: fix CC_VIEWPORT

I was confusing depth bounds test with depth clamping

5 years agoiris: multislice transfer maps
Kenneth Graunke [Thu, 12 Jul 2018 21:44:55 +0000 (14:44 -0700)]
iris: multislice transfer maps

5 years agoiris: disable 6x MSAA support
Kenneth Graunke [Thu, 12 Jul 2018 17:51:14 +0000 (10:51 -0700)]
iris: disable 6x MSAA support

5 years agoiris: fix sample mask for MSAA-off
Kenneth Graunke [Thu, 12 Jul 2018 17:42:49 +0000 (10:42 -0700)]
iris: fix sample mask for MSAA-off

5 years agoiris: actually pin the buffers
Kenneth Graunke [Thu, 12 Jul 2018 00:05:10 +0000 (17:05 -0700)]
iris: actually pin the buffers

5 years agoiris: fix SO_DECL_LIST
Kenneth Graunke [Wed, 11 Jul 2018 23:26:06 +0000 (16:26 -0700)]
iris: fix SO_DECL_LIST

5 years agoiris: bother setting program_string_id...
Kenneth Graunke [Wed, 11 Jul 2018 20:40:33 +0000 (13:40 -0700)]
iris: bother setting program_string_id...

not sure how useful this really is...

./bin/ext_transform_feedback-tessellation triangles flat_first
is hitting a case where we rebind the same VS program, but with
different streamout info...which isn't in the key...but is in the
cache...so we don't rebuild it...

5 years agoiris: set even if no outputs
Kenneth Graunke [Wed, 11 Jul 2018 20:22:02 +0000 (13:22 -0700)]
iris: set even if no outputs

5 years agoiris: streamout
Kenneth Graunke [Wed, 11 Jul 2018 19:45:19 +0000 (12:45 -0700)]
iris: streamout

5 years agoiris: SO buffers
Kenneth Graunke [Fri, 29 Jun 2018 19:58:31 +0000 (12:58 -0700)]
iris: SO buffers

5 years agoiris: Implement 3DSTATE_SO_DECL_LIST
Kenneth Graunke [Fri, 29 Jun 2018 19:58:31 +0000 (12:58 -0700)]
iris: Implement 3DSTATE_SO_DECL_LIST

5 years agoiris: rearrange iris_resource.h
Kenneth Graunke [Mon, 9 Jul 2018 22:15:52 +0000 (15:15 -0700)]
iris: rearrange iris_resource.h

5 years agoiris: slab allocate transfers
Kenneth Graunke [Fri, 6 Jul 2018 18:29:51 +0000 (11:29 -0700)]
iris: slab allocate transfers

apparently we need this for u_threaded_context

5 years agoiris: don't crash on shader perf logs
Kenneth Graunke [Thu, 5 Jul 2018 09:53:54 +0000 (02:53 -0700)]
iris: don't crash on shader perf logs

5 years agoiris: fix depth bounds clamp enables
Kenneth Graunke [Thu, 5 Jul 2018 09:48:23 +0000 (02:48 -0700)]
iris: fix depth bounds clamp enables

fixes depthrange-clear among others

5 years agoiris: fix clip flagging on fb changes
Kenneth Graunke [Thu, 5 Jul 2018 09:41:52 +0000 (02:41 -0700)]
iris: fix clip flagging on fb changes

5 years agoiris: comment out l/a/i/la
Kenneth Graunke [Wed, 4 Jul 2018 23:11:01 +0000 (16:11 -0700)]
iris: comment out l/a/i/la

in hopes of r/rg fallbacks

5 years agoiris: actually handle array layers in blits
Kenneth Graunke [Wed, 4 Jul 2018 23:07:28 +0000 (16:07 -0700)]
iris: actually handle array layers in blits

5 years agoiris: keep DISCARD_RANGE
Kenneth Graunke [Wed, 4 Jul 2018 22:37:34 +0000 (15:37 -0700)]
iris: keep DISCARD_RANGE

this isn't really an iris_bo_map flag, but the various resource mappers
want to check for it to avoid making temp copies.

5 years agoiris: actually set cube bit properly
Kenneth Graunke [Wed, 4 Jul 2018 22:34:24 +0000 (15:34 -0700)]
iris: actually set cube bit properly

5 years agoiris: rename map->stride
Kenneth Graunke [Wed, 4 Jul 2018 06:44:40 +0000 (23:44 -0700)]
iris: rename map->stride

5 years agoiris: fix zoffset asserts with 2DArray/Cube
Kenneth Graunke [Tue, 3 Jul 2018 20:23:47 +0000 (13:23 -0700)]
iris: fix zoffset asserts with 2DArray/Cube

5 years agoiris: SBE change stash
Kenneth Graunke [Tue, 3 Jul 2018 06:16:20 +0000 (23:16 -0700)]
iris: SBE change stash

not used yet, but want to flag it so I don't forget

5 years agoiris: just malloc one iris_genx_state instead of a bunch of oddball pieces
Kenneth Graunke [Mon, 2 Jul 2018 05:13:07 +0000 (22:13 -0700)]
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.

5 years agoiris: dead pointer
Kenneth Graunke [Mon, 2 Jul 2018 05:03:20 +0000 (22:03 -0700)]
iris: dead pointer

5 years agoiris: implement border color, fix other sampler nonsense
Kenneth Graunke [Thu, 28 Jun 2018 09:25:25 +0000 (02:25 -0700)]
iris: implement border color, fix other sampler nonsense

5 years agoiris: border color memory zone :(
Kenneth Graunke [Thu, 28 Jun 2018 08:00:11 +0000 (01:00 -0700)]
iris: border color memory zone :(

They took away our pointer bits, so now we need a pile of special code
to handle this instead of just using u_upload_mgr. :(

5 years agoiris: don't include binder in surface VMA range
Kenneth Graunke [Thu, 28 Jun 2018 08:00:11 +0000 (01:00 -0700)]
iris: don't include binder in surface VMA range

5 years agoiris: state ref tuple
Kenneth Graunke [Thu, 28 Jun 2018 07:57:49 +0000 (00:57 -0700)]
iris: state ref tuple

5 years agoiris: null surface for unbound textures
Kenneth Graunke [Wed, 27 Jun 2018 23:59:59 +0000 (16:59 -0700)]
iris: null surface for unbound textures

avoids crashes...may not be really right

5 years agoiris: depth clears
Kenneth Graunke [Wed, 27 Jun 2018 05:41:07 +0000 (22:41 -0700)]
iris: depth clears

5 years agoiris: fix GS dispatch mode
Kenneth Graunke [Tue, 26 Jun 2018 20:35:47 +0000 (13:35 -0700)]
iris: fix GS dispatch mode

5 years agoiris: fix 3DSTATE_VERTEX_ELEMENTS / VF_INSTANCING for 0 elements
Kenneth Graunke [Tue, 26 Jun 2018 20:32:19 +0000 (13:32 -0700)]
iris: fix 3DSTATE_VERTEX_ELEMENTS / VF_INSTANCING for 0 elements

5 years agoiris: don't emit garbage 3DSTATE_VERTEX_BUFFERS when there aren't any
Kenneth Graunke [Tue, 26 Jun 2018 20:25:22 +0000 (13:25 -0700)]
iris: don't emit garbage 3DSTATE_VERTEX_BUFFERS when there aren't any

5 years agoiris: geometry shader support
Kenneth Graunke [Tue, 26 Jun 2018 20:11:18 +0000 (13:11 -0700)]
iris: geometry shader support

5 years agoiris: TES uniform fixes
Kenneth Graunke [Tue, 26 Jun 2018 20:11:05 +0000 (13:11 -0700)]
iris: TES uniform fixes

not that we have a TES, but...

5 years agoiris: larger polygon offset
Kenneth Graunke [Tue, 26 Jun 2018 17:09:08 +0000 (10:09 -0700)]
iris: larger polygon offset

5 years agoiris: fix provoking vertex ordering
Kenneth Graunke [Tue, 26 Jun 2018 17:02:46 +0000 (10:02 -0700)]
iris: fix provoking vertex ordering

had this backwards

5 years agoiris: maybe-flush before blorp operations
Kenneth Graunke [Tue, 26 Jun 2018 14:31:56 +0000 (07:31 -0700)]
iris: maybe-flush before blorp operations

otherwise if we have a lot of back-to-back blorp operations we can
potentially overflow even the chained batch

5 years agoiris: lightmodel flat
Kenneth Graunke [Tue, 26 Jun 2018 08:00:37 +0000 (01:00 -0700)]
iris: lightmodel flat

5 years agoiris: implement copy image
Kenneth Graunke [Tue, 26 Jun 2018 07:28:52 +0000 (00:28 -0700)]
iris: implement copy image

5 years agoiris: fall back to u_generate_mipmap
Kenneth Graunke [Tue, 26 Jun 2018 07:17:36 +0000 (00:17 -0700)]
iris: fall back to u_generate_mipmap

It just does blits between layers, which is all we'd do anyway,
and it already should use BLORP because of iris_blit().  Plus it
handles 3D, which our code in i965 doesn't.

5 years agoiris: clear fix
Kenneth Graunke [Mon, 25 Jun 2018 20:27:14 +0000 (13:27 -0700)]
iris: clear fix

5 years agoiris: shader dirty bits
Kenneth Graunke [Mon, 25 Jun 2018 15:23:40 +0000 (08:23 -0700)]
iris: shader dirty bits

5 years agoiris: rework DEBUG_REEMIT
Kenneth Graunke [Mon, 25 Jun 2018 15:25:22 +0000 (08:25 -0700)]
iris: rework DEBUG_REEMIT

don't want to have to special case this everywhere

5 years agoiris: clears
Kenneth Graunke [Sun, 24 Jun 2018 22:16:34 +0000 (15:16 -0700)]
iris: clears

5 years agoiris: better boxing on maps
Kenneth Graunke [Sun, 24 Jun 2018 07:27:58 +0000 (00:27 -0700)]
iris: better boxing on maps

5 years agoiris: fix fragcoord ytransform
Kenneth Graunke [Sun, 24 Jun 2018 06:52:43 +0000 (23:52 -0700)]
iris: fix fragcoord ytransform

the TGSI in the name is a misnomer, it actually controls wpos_ytransform
lowering in NIR these days.

5 years agoiris: Disable unsupported mirror clamp modes
Kenneth Graunke [Sun, 24 Jun 2018 00:30:18 +0000 (17:30 -0700)]
iris: Disable unsupported mirror clamp modes

5 years agoiris: tidy comments about mirroring modes
Kenneth Graunke [Sun, 24 Jun 2018 00:19:50 +0000 (17:19 -0700)]
iris: tidy comments about mirroring modes

5 years agoiris: iris - fix QWord aligned endings after batch chaining rework
Kenneth Graunke [Sat, 23 Jun 2018 19:48:37 +0000 (12:48 -0700)]
iris: iris - fix QWord aligned endings after batch chaining rework

I need to save the primary batch size after expanding it to include
MI_BATCH_BUFFER_END and the QWord padding NOP

5 years agoiris: colorize batchbuffer failures to make them stand out
Kenneth Graunke [Sat, 23 Jun 2018 19:31:17 +0000 (12:31 -0700)]
iris: colorize batchbuffer failures to make them stand out

5 years agoiris: bad inherited comments
Kenneth Graunke [Sat, 23 Jun 2018 19:18:11 +0000 (12:18 -0700)]
iris: bad inherited comments

5 years agoiris: Handle batch submission failure "better"
Kenneth Graunke [Sat, 23 Jun 2018 19:13:03 +0000 (12:13 -0700)]
iris: Handle batch submission failure "better"

We used to not reset the batch, and just keep appending to it, so you'd
get the same invalid contents over and over.

I'd also really like to know about this, so aborting seems wise for now,
if not for the long term

5 years agoiris: don't always flush
Kenneth Graunke [Fri, 22 Jun 2018 16:57:45 +0000 (09:57 -0700)]
iris: don't always flush

5 years agoiris: print second batch size separately
Kenneth Graunke [Fri, 22 Jun 2018 16:57:36 +0000 (09:57 -0700)]
iris: print second batch size separately

5 years agoiris: actually init num_viewports
Kenneth Graunke [Wed, 20 Jun 2018 23:11:08 +0000 (16:11 -0700)]
iris: actually init num_viewports

fixes regressions

5 years agoiris: scissor count fixes
Kenneth Graunke [Wed, 20 Jun 2018 23:07:05 +0000 (16:07 -0700)]
iris: scissor count fixes

5 years agoiris: fix VP iteration
Kenneth Graunke [Wed, 20 Jun 2018 23:03:43 +0000 (16:03 -0700)]
iris: fix VP iteration

5 years agoiris: fix num viewports to be based on programs
Kenneth Graunke [Wed, 20 Jun 2018 22:57:46 +0000 (15:57 -0700)]
iris: fix num viewports to be based on programs

5 years agoiris: fix viewport counts and settings
Kenneth Graunke [Wed, 20 Jun 2018 22:45:48 +0000 (15:45 -0700)]
iris: fix viewport counts and settings

seeing

   set_viewport_state 0 1
   set_viewport_state 1 15

which gives us a total of 16 viewports, updated incrementally
so keep old values around and update them...

5 years agoiris: max VP index
Kenneth Graunke [Wed, 20 Jun 2018 22:35:10 +0000 (15:35 -0700)]
iris: max VP index