mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-25 00:00:11 +01:00
radeonsi: fail compilation if non-GS non-CS shaders have rodata
Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
This commit is contained in:
parent
09408764c1
commit
9d5bf1a3ef
1 changed files with 13 additions and 0 deletions
|
|
@ -4239,6 +4239,19 @@ int si_compile_llvm(struct si_screen *sscreen,
|
|||
FREE(binary->global_symbol_offsets);
|
||||
binary->config = NULL;
|
||||
binary->global_symbol_offsets = NULL;
|
||||
|
||||
/* Some shaders can't have rodata because their binaries can be
|
||||
* concatenated.
|
||||
*/
|
||||
if (binary->rodata_size &&
|
||||
(processor == TGSI_PROCESSOR_VERTEX ||
|
||||
processor == TGSI_PROCESSOR_TESS_CTRL ||
|
||||
processor == TGSI_PROCESSOR_TESS_EVAL ||
|
||||
processor == TGSI_PROCESSOR_FRAGMENT)) {
|
||||
fprintf(stderr, "radeonsi: The shader can't have rodata.");
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
return r;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue