Will be useful for testing the legacy path.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
RADV_DEBUG_NOTHREADLLVM = 0x400000,
RADV_DEBUG_NOBINNING = 0x800000,
RADV_DEBUG_NO_LOAD_STORE_OPT = 0x1000000,
+ RADV_DEBUG_NO_NGG = 0x2000000,
};
enum {
{"nothreadllvm", RADV_DEBUG_NOTHREADLLVM},
{"nobinning", RADV_DEBUG_NOBINNING},
{"noloadstoreopt", RADV_DEBUG_NO_LOAD_STORE_OPT},
+ {"nongg", RADV_DEBUG_NO_NGG},
{NULL, 0}
};
if (device->instance->debug_flags & RADV_DEBUG_UNSAFE_MATH)
hash_flags |= RADV_HASH_SHADER_UNSAFE_MATH;
+ if (device->instance->debug_flags & RADV_DEBUG_NO_NGG)
+ hash_flags |= RADV_HASH_SHADER_NO_NGG;
if (device->instance->perftest_flags & RADV_PERFTEST_SISCHED)
hash_flags |= RADV_HASH_SHADER_SISCHED;
return hash_flags;
keys[MESA_SHADER_VERTEX].vs_common_out.as_es = true;
}
- if (device->physical_device->rad_info.chip_class >= GFX10) {
+ if (device->physical_device->rad_info.chip_class >= GFX10 &&
+ !(device->instance->debug_flags & RADV_DEBUG_NO_NGG)) {
if (nir[MESA_SHADER_TESS_CTRL]) {
keys[MESA_SHADER_TESS_EVAL].vs_common_out.as_ngg = true;
} else {
#define RADV_HASH_SHADER_IS_GEOM_COPY_SHADER (1 << 0)
#define RADV_HASH_SHADER_SISCHED (1 << 1)
#define RADV_HASH_SHADER_UNSAFE_MATH (1 << 2)
+#define RADV_HASH_SHADER_NO_NGG (1 << 3)
+
void
radv_hash_shaders(unsigned char *hash,
const VkPipelineShaderStageCreateInfo **stages,