summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSamuel Pitoiset <[email protected]>2019-03-21 10:14:30 +0100
committerSamuel Pitoiset <[email protected]>2019-03-21 12:13:07 +0100
commit0eb1478ac254e97d85b06f42b9aa474a8b829b07 (patch)
tree3c132591442f81e74fa0d21422b5df223b09e8f0
parentff11c9dcc74d28340cf0f042ebd0fdf11709e44a (diff)
ac: add 16-bit support fo fsign
Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
-rw-r--r--src/amd/common/ac_llvm_build.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/amd/common/ac_llvm_build.c b/src/amd/common/ac_llvm_build.c
index a9c6b4af958..a153b008594 100644
--- a/src/amd/common/ac_llvm_build.c
+++ b/src/amd/common/ac_llvm_build.c
@@ -2472,7 +2472,11 @@ LLVMValueRef ac_build_fsign(struct ac_llvm_context *ctx, LLVMValueRef src0,
LLVMValueRef cmp, val, zero, one;
LLVMTypeRef type;
- if (bitsize == 32) {
+ if (bitsize == 16) {
+ type = ctx->f16;
+ zero = ctx->f16_0;
+ one = ctx->f16_1;
+ } else if (bitsize == 32) {
type = ctx->f32;
zero = ctx->f32_0;
one = ctx->f32_1;