summaryrefslogtreecommitdiffstats
path: root/src/intel/vulkan/anv_private.h
Commit message (Collapse)AuthorAgeFilesLines
* anv: strdup the device path into the physical deviceJason Ekstrand2016-05-271-1/+1
| | | | | This way we don't have to assume that the string coming in is a piece of constant data that exists forever.
* anv/cmd_buffer: Only emit PIPE_CONTROL on-demandJason Ekstrand2016-05-271-0/+40
| | | | | | | | | | | This is in contrast to emitting it directly in vkCmdPipelineBarrier. This has a couple of advantages. First, it means that no matter how many vkCmdPipelineBarrier calls the application strings together it gets one or two PIPE_CONTROLs. Second, it allow us to better track when we need to do stalls because we can flag when a flush has happened and we need a stall. Signed-off-by: Jason Ekstrand <[email protected]> Reviewed-by: Jordan Justen <[email protected]>
* anv/clear: Only clear the render area when doing subpass clearsJason Ekstrand2016-05-271-0/+1
| | | | | Signed-off-by: Jason Ekstrand <[email protected]> Reviewed-by: Jordan Justen <[email protected]>
* anv: Move push constant allocation to the command bufferJason Ekstrand2016-05-271-1/+1
| | | | | | | | | | Instead of blasting it out as part of the pipeline, we put it in the command buffer and only blast it out when it's really needed. Since the PUSH_CONSTANT_ALLOC commands aren't pipelined, they immediately cause a stall which we would like to avoid. Signed-off-by: Jason Ekstrand <[email protected]> Reviewed-by: Jordan Justen <[email protected]>
* vk/intel: use negative VK_NO_PROTOTYPES schemeEric Engestrom2016-05-231-1/+0
| | | | | | | | | | 3d0fac7aca237bbe8ed8e2a362d3b42d0ef8c46c changed all VK_PROTOTYPES to VK_NO_PROTOTYPES This brings the Intel header in line with the rest of the Vulkan code. Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Chad Versace <[email protected]>
* anv/device: Add a boolean for robust buffer accessJason Ekstrand2016-05-191-0/+1
|
* anv: Port L3 cache programming from i965Jordan Justen2016-05-171-1/+11
| | | | | Signed-off-by: Jordan Justen <[email protected]> Acked-by: Jason Ekstrand <[email protected]>
* anv: Keep track of whether the data cache should be enabled in L3Jordan Justen2016-05-171-0/+1
| | | | | | | | If images or shader buffers are used, we will enable the data cache in the the L3 config. Signed-off-by: Jordan Justen <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* anv: Add a devinfo argument to the get_format functionsJason Ekstrand2016-05-171-5/+5
|
* anv: Use 16 bits for the isl_format in anv_formatJason Ekstrand2016-05-171-1/+1
| | | | This way the entire anv_format structure fits in 32 bits
* anv/formats: Use the isl_channel_select enum for the swizzleJason Ekstrand2016-05-171-4/+4
|
* anv/formats: Add an anv_get_format helperJason Ekstrand2016-05-171-5/+9
| | | | | | | | | This commit removes anv_format_for_vk_format and adds an anv_get_format helper. The anv_get_format helper returns the anv_format by-value. Unlike anv_format_for_vk_format the format returned by anv_get_format is 100% accurate and includes any tweaks needed for tiled vs. linear. anv_get_isl_format is now just a wrapper around anv_get_format that picks off just the isl_format.
* anv/format: Simplify anv_formatJason Ekstrand2016-05-171-18/+1
| | | | | | Now that we have VkFormat introspection and we've removed everything that tried to use anv_format for introspection, we no longer need most of what was in anv_format.
* anv: Remove the anv_format member from anv_imageJason Ekstrand2016-05-171-1/+0
|
* anv: Change render_pass_attachment.format to a VkFormatJason Ekstrand2016-05-171-1/+1
|
* anv/image: Add an aspects fieldJason Ekstrand2016-05-171-1/+2
| | | | | This makes several checks easier and allows us to avoid calling anv_format_for_vk_format in a number of cases.
* anv: Make format_for_descriptor return an isl_formatJason Ekstrand2016-05-171-2/+2
|
* anv/wsi: Make WSI per-physical-device rather than per-instanceJason Ekstrand2016-05-171-8/+8
| | | | | This better maps to the Vulkan object model and also allows WSI to at least know the hardware generation which is useful for format checks.
* i965/fs: Organize prog_data by ksp number rather than SIMD widthJason Ekstrand2016-05-141-5/+0
| | | | | | | | | | The hardware packets organize kernel pointers and GRF start by slots that don't map directly to dispatch width. This means that all of the state setup code has to re-arrange the data from prog_data into these slots. This logic has been duplicated 4 times in the GL driver and one more time in the Vulkan driver. Let's just put it all in brw_fs.cpp. Reviewed-by: Kenneth Graunke <[email protected]>
* anv: s/anv_batch_emit_blk/anv_batch_emit/Jason Ekstrand2016-04-201-1/+1
| | | | Acked-by: Kristian Høgsberg <[email protected]>
* anv: Remove the old emit macroJason Ekstrand2016-04-201-10/+0
| | | | Acked-by: Kristian Høgsberg <[email protected]>
* anv: Add a new block-based batch emit macroJason Ekstrand2016-04-201-0/+9
| | | | | | | | | This new macro uses a for loop to create an actual code block in which to place the macro setup code. One advantage of this is that you syntatically use braces instead of parentheses. Another is that the code in the block doesn't even get executed if anv_batch_emit_dwords fails. Acked-by: Kristian Høgsberg <[email protected]>
* anv: fix build without Wayland platformMarcin Ślusarz2016-04-201-3/+0
| | | | Reviewed-by: Jason Ekstrand <[email protected]>
* anv: Replace ::disable_scissor with ::use_rectlistsNanley Chery2016-04-131-1/+0
| | | | | | | | | Meta currently uses screenspace RECTLIST primitives that lie within the framebuffer rectangle. Since this behavior shouldn't change in the future, disable the scissor operation whenever rectlists are used. Signed-off-by: Nanley Chery <[email protected]> Reviewed-by: Kristian Høgsberg Kristensen <[email protected]>
* anv: Delete anv_graphics_pipeline_create_info::disable_viewportNanley Chery2016-04-131-1/+0
| | | | | | | There are no users of this field. Signed-off-by: Nanley Chery <[email protected]> Reviewed-by: Kristian Høgsberg Kristensen <[email protected]>
* anv/image: Remove the offset parameter from image_view_initJason Ekstrand2016-04-081-1/+0
| | | | | | | The only place we were using this was in meta_blit2d which always creates a new image anyway so we can just use the image offset. Reviewed-by: Nanley Chery <[email protected]>
* anv/image: Expose the guts of CreateBufferView for metaJason Ekstrand2016-04-081-0/+5
| | | | Reviewed-by: Nanley Chery <[email protected]>
* anv/blit2d: Refactor in preparation for different src/dst typesJason Ekstrand2016-04-081-3/+6
| | | | Reviewed-by: Nanley Chery <[email protected]>
* anv/blit2d: Add layouts for using a texel buffer sourceJason Ekstrand2016-04-081-2/+4
| | | | Reviewed-by: Nanley Chery <[email protected]>
* anv/blit2d: Rename the descriptor set and pipeline layoutsJason Ekstrand2016-04-081-2/+2
| | | | Reviewed-by: Nanley Chery <[email protected]>
* anv/gen7: Save kernel command parser versionJordan Justen2016-03-281-0/+1
| | | | Signed-off-by: Jordan Justen <[email protected]>
* anv: Add genxml register supportJordan Justen2016-03-241-0/+9
| | | | Signed-off-by: Jordan Justen <[email protected]>
* anv: Sanitize Image extents and offsetsNanley Chery2016-03-241-0/+33
| | | | | | | | | | | | | | | Prepare Image extents and offsets for internal consumption by assigning the default values implicitly defned by the spec. Fixes textures on several Vulkan demos in which the VkImageCopy depth is set to zero when copying a 2D image. v2 (Jason Ekstrand): Replace "prep" with "sanitize" Make function static inline Pass structs instead of pointers Reviewed-by: Jason Ekstrand <[email protected]> Signed-off-by: Nanley Chery <[email protected]>
* anv/batch_chain: Fall back to growing batches when chaining isn't availableJason Ekstrand2016-03-211-0/+2
|
* anv/allocator: Make the bo_pool dynamically sizedJason Ekstrand2016-03-181-5/+2
|
* anv/allocator: Add a size field to bo_pool_allocJason Ekstrand2016-03-181-1/+2
|
* anv/blit2d: Customize meta blit structs and functions for blit2d APINanley Chery2016-03-161-0/+10
| | | | | | | | | * Add fields in meta struct * Add support in meta init/teardown * Switch to custom meta_emit_blit2d() Signed-off-by: Nanley Chery <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* anv: Pull all of the genX_foo functions into anv_genX.hJason Ekstrand2016-03-081-141/+18
| | | | | This way we only have to declare them each once and we get it for all gens at a single go.
* anv: Compact render targetsJason Ekstrand2016-03-081-2/+9
| | | | | | | Previously, we would always emit all of the render targets in the subpass. This commit changes it so that we compact render targets just like we do with other resources. Render targets are represented in the surface map by using a descriptor set index of UINT16_MAX.
* anv: Emit null render targetsJason Ekstrand2016-03-051-0/+13
| | | | v2 (Francisco Jerez): Add the state_offset to the surface state offset
* anv: Always use point size from the shaderKristian Høgsberg Kristensen2016-03-051-1/+0
| | | | | | | | | | | | There is no API for setting the point size and the shader is always required to set it. Section 24.4: "If the value written to PointSize is less than or equal to zero, or if no value was written to PointSize, results are undefined." As such, we can just always program PointWidthSource to Vertex. This simplifies anv_pipeline a bit and avoids trouble when we enable the pipeline cache and don't have writes_point_size in the prog_data.
* anv: Also cache the struct anv_pipeline_binding mapsKristian Høgsberg Kristensen2016-03-051-2/+6
| | | | | This is state the we generate when compiling the shaders and we need it for mapping resources from descriptor sets to binding table indices.
* anv: Store prog data in pipeline cache streamKristian Høgsberg Kristensen2016-03-051-7/+28
| | | | | We have to keep it there for the cache to work, so let's not have an extra copy in struct anv_pipeline too.
* anv: Rename 'table' to 'hash_table' in anv_pipeline_cacheKristian Høgsberg Kristensen2016-03-051-1/+1
| | | | A little less ambiguous.
* anv: Implement VK_REMAINING_{MIP_LEVELS,ARRAY_LAYERS}Nanley Chery2016-03-041-0/+17
| | | | | | | v2: Subtract the baseMipLevel and baseArrayLayer (Jason) Signed-off-by: Nanley Chery <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* anv: Fill out image_param structs at view creation timeJason Ekstrand2016-02-271-0/+5
|
* anv/image: Add a ussage_mask field to image_view_initJason Ekstrand2016-02-271-1/+2
| | | | | | | | This allows us to avoid doing some unneeded work on the meta paths where we know that the image view will be used for exactly one thing. The meta paths also sometimes do things that aren't quite valid like setting the array slice on a 3-D texture and we want to limit the number of paths that need to be able to sensibly handle the lies.
* anv: Remove unneeded fiels from anv_image_viewJason Ekstrand2016-02-271-3/+0
|
* anv/device: Store the default MOCS in the deviceJason Ekstrand2016-02-271-7/+9
|
* anv: Emit 3DSTATE_PUSH_CONSTANT_ALLOC_* via a loop.Kenneth Graunke2016-02-241-0/+1
| | | | Now we're emitting HS and DS packets as well.