summaryrefslogtreecommitdiffstats
path: root/src/vulkan/gen7_state.c
Commit message (Collapse)AuthorAgeFilesLines
* anv/state: Fix reversed MIN vs. MAX in levelCount handling.Kenneth Graunke2015-12-291-2/+2
| | | | | The point is to promote a levelCount of 0 to 1 before subtracting 1. This needs MAX, not MIN.
* anv/state: Allow levelCount to be 0Jason Ekstrand2015-12-161-2/+2
| | | | | This can happen if the client is creating an image view of a textureable surface and they only ever intend to render to that view.
* anv: Fix CUBE storage imagesJason Ekstrand2015-12-141-3/+7
|
* anv: Pass an isl_format into fill_buffer_surface_stateJason Ekstrand2015-12-141-2/+2
|
* anv: Add initial support for cube mapsJason Ekstrand2015-12-141-2/+2
| | | | This fixes 486 cubemap CTS tests.
* anv: Remove anv_image::surface_typeChad Versace2015-12-141-1/+25
| | | | | | | | | | | | | | When building RENDER_SURFACE_STATE, the driver set SurfaceType = anv_image::surface_type, which was calculated during anv_image_init(). This was bad because the value of anv_image::surface_type was taken from a gen-specific header, gen8_pack.h, even though the anv_image structure is used for all gens. Replace anv_image::surface_type with a gen-specific lookup function, anv_surftype(), defined in gen${x}_state.c. The lookup function contains some useful asserts that caught some nasty bugs in anv meta, which were fixed in the previous commit.
* isl: Rename s/lod_align/image_align/ for consistencyChad Versace2015-12-141-4/+4
| | | | | | | | | | | | Regarding the subimages within a surface, sometimes isl called them "images" and sometimes "LODs". This patch make isl consistently refer to them as "images". I choose the term "image" over "LOD" because LOD is an misnomer when applied to 3D surfaces. The alignment applies to each individual 2D subimage, not to the LOD as a whole. This patch changes no behavior. It's just a manually performed, case-insensitive, replacement s/lod/image/ that maintains correct indentation. any behavior.
* anv/image: Add a separate storage image surface stateJason Ekstrand2015-12-071-0/+14
| | | | | Thanks to hardware limitations, storage images may need a different surface format and/or other bits in the surface state.
* vk: clflush all state for non-LLC GPUsKristian Høgsberg2015-12-041-0/+5
|
* anv: Embed isl_surf into anv_surfaceChad Versace2015-12-031-5/+8
| | | | | This reduces struct anv_surface to just two members: an offset and the embedded isl_surf.
* isl: Rename legacy Y tiling to ISL_TILING_Y0Chad Versace2015-12-031-1/+1
| | | | | | | Rename legacy Y tiling from ISL_TILING_Y to ISL_TILING_Y0 in order to clearly distinguish it from Yf and Ys. Using ISL_TILING_Y to denote legacy Y tiling would lead to confusion with i965, because i965 uses I195_TILE_Y to denote *any* Y tiling.
* vk/0.210.0: Rework allocation to use the new pAllocator'sJason Ekstrand2015-12-031-2/+3
|
* vk/0.210.0: More structure field renamingJason Ekstrand2015-12-031-3/+3
|
* vk/0.210.0: Rework sampler filtering and mode enumsJason Ekstrand2015-12-031-11/+11
|
* vk/0.210.0: Rework color blending enumsJason Ekstrand2015-11-301-2/+2
|
* gen7/8/cmd_buffer: Inline vk_to_gen_swizzleJason Ekstrand2015-11-301-1/+1
| | | | It's currently unused on IVB so we get compiler warnings.
* vk/0.210.0: Rework texture view component mappingJason Ekstrand2015-11-301-11/+24
|
* anv: Add initial Haswell supportJason Ekstrand2015-11-171-24/+46
|
* anv: Only include the pack headers where neededJason Ekstrand2015-11-161-1/+3
| | | | | | | Previously, we were including gen7_pack.h, gen75_pack.h, and gen8_pack.h in anv_private.h. As we add more gens, this is going to become untenable. This commit moves things around so that we only use the pack headers when and if we need them.
* anv: Use enum isl_tiling everywhereChad Versace2015-11-131-2/+3
| | | | | | | | | In anv_surface and anv_image_create_info, replace member 'uint8_t tile_mode' with 'enum isl_tiling'. As a nice side-effect, this patch also reduces bug potential because the hardware enum values for tile modes are unstable across hardware generations.
* anv/cmd_buffer: Rework the way we emit UBO surface stateJason Ekstrand2015-11-061-7/+1
| | | | | | The new mechanism should be able to handle SSBOs as well as properly handle emitting surface state on gen7 where we need different strides depending on shader stage.
* anv: Remove all support for BufferViewsJason Ekstrand2015-11-061-24/+0
| | | | | | We never *actually* supported them, we just used them for binding UBOs. Now that we have BufferInfo and we aren't supporting texture buffers yet, we should get rid of them until we can do them properly.
* anv/cmd_buffer: Add an alloc_surface_state helperJason Ekstrand2015-10-151-2/+1
|
* vk/0.170.2: Switch to the new dynamic state modelJason Ekstrand2015-10-071-72/+0
|
* vk: Embed two surface states in anv_image_viewChad Versace2015-10-061-100/+40
| | | | | | | | | | | | | This prepares for merging VkAttachmentView into VkImageView. The two surface states are: anv_image_view::color_rt_surface_state: RENDER_SURFACE_STATE when using image as a color render target. anv_image_view::nonrt_surface_state; RENDER_SURFACE_STATE when using image as a non render target. No Crucible regressions.
* vk: Add anv_image::usageChad Versace2015-10-061-0/+1
| | | | | It's a copy of VkImageCreateInfo::usage. Will be used for the VkAttachmentView/VkImageView merge.
* vk/0.170.2: s/baseArraySlice/baseArrayLayer/Jason Ekstrand2015-10-061-1/+1
|
* vk: Merge anv_attachment_view into anv_image_viewChad Versace2015-10-061-4/+1
| | | | This prepares for merging VkAttachmentView into VkImageView.
* vk/0.170.2: Add unnormalizedCoordinates to VkSamplerCreateInfoJason Ekstrand2015-10-051-1/+1
|
* vk/0.170.2: Rename VkTexAddress to VkTexAddressModeJason Ekstrand2015-10-051-8/+8
|
* vk: Merge anv_*_attachment_view into anv_attachment_viewChad Versace2015-10-051-3/+2
| | | | | | Remove anv_color_attachment_view and anv_depth_stencil_view, merging them into anv_attachment_view. This prepares for merging VkAttachmentView into VkImageView.
* vk: Drop anv_attachment_view::extentChad Versace2015-10-051-1/+1
| | | | It's duplicated by anv_attachment_view::image_view::extent.
* vk: Drop anv_surface_viewChad Versace2015-10-051-20/+18
| | | | | | | | | | | Push the members of struct anv_surface_view into anv_image_view and anv_buffer_view, then remove struct anv_surface_view. Observe that anv_surface_view::range is not needed for anv_image_view, and so was dropped there. This prepares for the merge of VkAttachmentView into VkImageView. Remove the common parent of anv_buffer_view and anv_image_view (that is, anv_surface_view) will make the merge easier.
* vk: Use consistent names for anv_*_view variablesChad Versace2015-10-051-25/+29
| | | | | | | | | | | | | Rename all anv_*_view variables to follow this convention: - sview -> anv_surface_view - bview -> anv_buffer_view - iview -> anv_image_view - aview -> anv_attachment_view - cview -> anv_color_attachment_view - ds_view -> anv_depth_stencil_attachment_view This clarifies existing code. And it will reduce noise in the upcoming commits that merge VkAttachmentView into VkImageView.
* vk: Return anv_image_view_info by valueChad Versace2015-10-051-2/+2
| | | | | The struct is only 2 bytes. Returning it on the stack is better than returning a reference into the ELF .data segment.
* vk/0.170.2: Update VkImageSubresourceRangeChad Versace2015-10-051-1/+1
| | | | Replace 'aspect' with 'aspectMask'.
* vk/image: Let anv_image have one anv_surface per aspectChad Versace2015-08-281-17/+4
| | | | | Split anv_image::primary_surface into two: anv_image::color_surface and depth_surface.
* vk: Use true/false for RenderCacheReadWriteModeKristian Høgsberg Kristensen2015-08-251-1/+1
| | | | | | | This field in surface state is a bool, WriteOnlyCache is an enum from GEN8. Signed-off-by: Kristian Høgsberg Kristensen <[email protected]>
* vk/gen7: Use TILEWALK_XMAJOR for linear surfacesKristian Høgsberg Kristensen2015-08-251-2/+12
| | | | | | | You wouldn't think the TileWalk mode matters when TiledSurface is false. However, it has to be TILEWALK_XMAJOR. Make it so. Signed-off-by: Kristian Høgsberg Kristensen <[email protected]>
* vk: Add gen7 supportKristian Høgsberg Kristensen2015-08-241-0/+455
With all the previous commits in place, we can now drop in support for multiple platforms. First up is gen7 (Ivybridge). Signed-off-by: Kristian Høgsberg Kristensen <[email protected]>