diff options
author | Nicolai Hähnle <[email protected]> | 2017-11-13 16:35:59 +0100 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2019-06-03 20:05:20 -0400 |
commit | cd247cf45648159cb2676e88108ec8d8dc97095b (patch) | |
tree | 5c84086b1b22fc786a9218d0b813b38a1b20b7dd /src/amd/common | |
parent | ef6ef098af63ab26b1a050be14e76de6d0f48dd2 (diff) |
amd/common: cleanup DATA_FORMAT/NUM_FORMAT field names
The field layout wasn't actually changed in gfx9, so having the suffix
isn't very useful. The field *contents* were changed, but this is
reflected in the V_xxx_xxx definitions and is taken into account by
the ac_debug logic based on the register JSON.
This aligns the definitions with what will be generated from the
register JSON.
Diffstat (limited to 'src/amd/common')
-rw-r--r-- | src/amd/common/ac_nir_to_llvm.c | 2 | ||||
-rw-r--r-- | src/amd/common/gfx9d.h | 12 | ||||
-rw-r--r-- | src/amd/common/sid.h | 12 |
3 files changed, 13 insertions, 13 deletions
diff --git a/src/amd/common/ac_nir_to_llvm.c b/src/amd/common/ac_nir_to_llvm.c index 51f92a6b062..6b37cecebd5 100644 --- a/src/amd/common/ac_nir_to_llvm.c +++ b/src/amd/common/ac_nir_to_llvm.c @@ -1265,7 +1265,7 @@ static LLVMValueRef lower_gather4_integer(struct ac_llvm_context *ctx, LLVMConstInt(ctx->i32, 0x14000000, false), ""); /* replace the NUM FORMAT in the descriptor */ - tmp2 = LLVMBuildAnd(ctx->builder, tmp2, LLVMConstInt(ctx->i32, C_008F14_NUM_FORMAT_GFX6, false), ""); + tmp2 = LLVMBuildAnd(ctx->builder, tmp2, LLVMConstInt(ctx->i32, C_008F14_NUM_FORMAT, false), ""); tmp2 = LLVMBuildOr(ctx->builder, tmp2, tmp, ""); args->resource = LLVMBuildInsertElement(ctx->builder, args->resource, tmp2, ctx->i32_1, ""); diff --git a/src/amd/common/gfx9d.h b/src/amd/common/gfx9d.h index 2e790c54699..5d3de5842a1 100644 --- a/src/amd/common/gfx9d.h +++ b/src/amd/common/gfx9d.h @@ -1269,9 +1269,9 @@ #define S_008F14_MIN_LOD(x) (((unsigned)(x) & 0xFFF) << 8) #define G_008F14_MIN_LOD(x) (((x) >> 8) & 0xFFF) #define C_008F14_MIN_LOD 0xFFF000FF -#define S_008F14_DATA_FORMAT_GFX9(x) (((unsigned)(x) & 0x3F) << 20) -#define G_008F14_DATA_FORMAT_GFX9(x) (((x) >> 20) & 0x3F) -#define C_008F14_DATA_FORMAT_GFX9 0xFC0FFFFF +#define S_008F14_DATA_FORMAT(x) (((unsigned)(x) & 0x3F) << 20) +#define G_008F14_DATA_FORMAT(x) (((x) >> 20) & 0x3F) +#define C_008F14_DATA_FORMAT 0xFC0FFFFF #define V_008F14_IMG_DATA_FORMAT_INVALID 0x00 #define V_008F14_IMG_DATA_FORMAT_8 0x01 #define V_008F14_IMG_DATA_FORMAT_16 0x02 @@ -1336,9 +1336,9 @@ #define V_008F14_IMG_DATA_FORMAT_8_AS_32 0x3D #define V_008F14_IMG_DATA_FORMAT_8_AS_32_32 0x3E #define V_008F14_IMG_DATA_FORMAT_32_AS_32_32_32_32 0x3F -#define S_008F14_NUM_FORMAT_GFX9(x) (((unsigned)(x) & 0x0F) << 26) -#define G_008F14_NUM_FORMAT_GFX9(x) (((x) >> 26) & 0x0F) -#define C_008F14_NUM_FORMAT_GFX9 0xC3FFFFFF +#define S_008F14_NUM_FORMAT(x) (((unsigned)(x) & 0x0F) << 26) +#define G_008F14_NUM_FORMAT(x) (((x) >> 26) & 0x0F) +#define C_008F14_NUM_FORMAT 0xC3FFFFFF #define V_008F14_IMG_NUM_FORMAT_UNORM 0x00 #define V_008F14_IMG_NUM_FORMAT_SNORM 0x01 #define V_008F14_IMG_NUM_FORMAT_USCALED 0x02 diff --git a/src/amd/common/sid.h b/src/amd/common/sid.h index 3c0b7001d2b..6e818f9af1b 100644 --- a/src/amd/common/sid.h +++ b/src/amd/common/sid.h @@ -2129,9 +2129,9 @@ #define S_008F14_MIN_LOD(x) (((unsigned)(x) & 0xFFF) << 8) #define G_008F14_MIN_LOD(x) (((x) >> 8) & 0xFFF) #define C_008F14_MIN_LOD 0xFFF000FF -#define S_008F14_DATA_FORMAT_GFX6(x) (((unsigned)(x) & 0x3F) << 20) -#define G_008F14_DATA_FORMAT_GFX6(x) (((x) >> 20) & 0x3F) -#define C_008F14_DATA_FORMAT_GFX6 0xFC0FFFFF +#define S_008F14_DATA_FORMAT(x) (((unsigned)(x) & 0x3F) << 20) +#define G_008F14_DATA_FORMAT(x) (((x) >> 20) & 0x3F) +#define C_008F14_DATA_FORMAT 0xFC0FFFFF #define V_008F14_IMG_DATA_FORMAT_INVALID 0x00 #define V_008F14_IMG_DATA_FORMAT_8 0x01 #define V_008F14_IMG_DATA_FORMAT_16 0x02 @@ -2196,9 +2196,9 @@ #define V_008F14_IMG_DATA_FORMAT_32_AS_8 0x3D /* not on stoney */ #define V_008F14_IMG_DATA_FORMAT_32_AS_8_8 0x3E /* not on stoney */ #define V_008F14_IMG_DATA_FORMAT_32_AS_32_32_32_32 0x3F -#define S_008F14_NUM_FORMAT_GFX6(x) (((unsigned)(x) & 0x0F) << 26) -#define G_008F14_NUM_FORMAT_GFX6(x) (((x) >> 26) & 0x0F) -#define C_008F14_NUM_FORMAT_GFX6 0xC3FFFFFF +#define S_008F14_NUM_FORMAT(x) (((unsigned)(x) & 0x0F) << 26) +#define G_008F14_NUM_FORMAT(x) (((x) >> 26) & 0x0F) +#define C_008F14_NUM_FORMAT 0xC3FFFFFF #define V_008F14_IMG_NUM_FORMAT_UNORM 0x00 #define V_008F14_IMG_NUM_FORMAT_SNORM 0x01 #define V_008F14_IMG_NUM_FORMAT_USCALED 0x02 |