Commit 2ed9eb1b authored by Marek Olšák's avatar Marek Olšák Committed by Marge Bot
Browse files

radeonsi/gfx11: enable shader prefetch except for initial chip revisions



Reviewed-by: Pierre-Eric Pelloux-Prayer's avatarPierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <!17864>
parent a09d9710
......@@ -873,6 +873,7 @@ bool ac_query_gpu_info(int fd, void *dev_p, struct radeon_info *info)
info->family_id = device_info.family;
info->chip_external_rev = device_info.external_rev;
info->chip_rev = device_info.chip_rev;
info->marketing_name = amdgpu_get_marketing_name(dev);
info->is_pro_graphics = info->marketing_name && (strstr(info->marketing_name, "Pro") ||
strstr(info->marketing_name, "PRO") ||
......@@ -1451,6 +1452,7 @@ void ac_print_gpu_info(struct radeon_info *info, FILE *f)
fprintf(f, " gfx_level = %i\n", info->gfx_level);
fprintf(f, " family_id = %i\n", info->family_id);
fprintf(f, " chip_external_rev = %i\n", info->chip_external_rev);
fprintf(f, " chip_rev = %i\n", info->chip_rev);
fprintf(f, "Flags:\n");
fprintf(f, " is_pro_graphics = %u\n", info->is_pro_graphics);
......
......@@ -82,6 +82,7 @@ struct radeon_info {
enum amd_gfx_level gfx_level;
uint32_t family_id;
uint32_t chip_external_rev;
uint32_t chip_rev; /* 0 = A0, 1 = A1, etc. */
/* Flags. */
bool is_pro_graphics;
......
......@@ -668,8 +668,11 @@ static unsigned si_get_vs_vgpr_comp_cnt(struct si_screen *sscreen, struct si_sha
unsigned si_get_shader_prefetch_size(struct si_shader *shader)
{
/* TODO: Disable for now. */
if (shader->selector->screen->info.gfx_level == GFX11)
/* Return 0 for some A0 chips only. Other chips don't need it. */
if ((shader->selector->screen->info.family == CHIP_GFX1100 ||
shader->selector->screen->info.family == CHIP_GFX1102 ||
shader->selector->screen->info.family == CHIP_GFX1103) &&
shader->selector->screen->info.chip_rev == 0)
return 0;
/* inst_pref_size is calculated in cache line size granularity */
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment