aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorNicolai Hähnle <[email protected]>2019-05-07 22:38:20 +0200
committerMarek Olšák <[email protected]>2019-07-03 15:51:12 -0400
commit4a774ba893b460ab375d60a7479e5b6affdf32f4 (patch)
tree0e1586489858258218d36290bc5f7017adf6ff87 /src
parentc53e6ea05db490f8787255c03508a273ccabb9b8 (diff)
radeonsi: various si_translate_*format functions only apply to pre-gfx10
Acked-by: Bas Nieuwenhuizen <[email protected]>
Diffstat (limited to 'src')
-rw-r--r--src/gallium/drivers/radeonsi/si_state.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/gallium/drivers/radeonsi/si_state.c b/src/gallium/drivers/radeonsi/si_state.c
index 96eb46c00b6..77ecf08565d 100644
--- a/src/gallium/drivers/radeonsi/si_state.c
+++ b/src/gallium/drivers/radeonsi/si_state.c
@@ -1620,6 +1620,8 @@ static uint32_t si_translate_texformat(struct pipe_screen *screen,
bool uniform = true;
int i;
+ assert(sscreen->info.chip_class <= GFX9);
+
/* Colorspace (return non-RGB formats directly). */
switch (desc->colorspace) {
/* Depth stencil formats */
@@ -1996,6 +1998,8 @@ static uint32_t si_translate_buffer_dataformat(struct pipe_screen *screen,
{
int i;
+ assert(((struct si_screen *)screen)->info.chip_class <= GFX9);
+
if (desc->format == PIPE_FORMAT_R11G11B10_FLOAT)
return V_008F0C_BUF_DATA_FORMAT_10_11_11;
@@ -2071,6 +2075,8 @@ static uint32_t si_translate_buffer_numformat(struct pipe_screen *screen,
const struct util_format_description *desc,
int first_non_void)
{
+ assert(((struct si_screen *)screen)->info.chip_class <= GFX9);
+
if (desc->format == PIPE_FORMAT_R11G11B10_FLOAT)
return V_008F0C_BUF_NUM_FORMAT_FLOAT;