ac: Add has_zero_index_buffer_bug to ac_gpu_info
authorTony Wasserka <tony.wasserka@gmx.de>
Wed, 10 Mar 2021 10:22:34 +0000 (11:22 +0100)
committerTony Wasserka <tony.wasserka@gmx.de>
Mon, 22 Mar 2021 10:47:22 +0000 (11:47 +0100)
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9429>

src/amd/common/ac_gpu_info.c
src/amd/common/ac_gpu_info.h

index 19bbcf2..8dadb41 100644 (file)
@@ -805,6 +805,9 @@ bool ac_query_gpu_info(int fd, void *dev_p, struct radeon_info *info,
 
    info->has_ls_vgpr_init_bug = info->family == CHIP_VEGA10 || info->family == CHIP_RAVEN;
 
+   /* Drawing from 0-sized index buffers causes hangs on Navi10/14. */
+   info->has_zero_index_buffer_bug = info->family == CHIP_NAVI10 || info->family == CHIP_NAVI14;
+
    /* Support for GFX10.3 was added with F32_ME_FEATURE_VERSION_31 but the
     * firmware version wasn't bumped.
     */
index 9a4f1b3..17ea2d6 100644 (file)
@@ -75,6 +75,7 @@ struct radeon_info {
    bool has_tc_compat_zrange_bug;
    bool has_msaa_sample_loc_bug;
    bool has_ls_vgpr_init_bug;
+   bool has_zero_index_buffer_bug;
    bool has_32bit_predication;
    bool has_3d_cube_border_color_mipmap;