summaryrefslogtreecommitdiffstats
path: root/src/gallium
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium')
-rw-r--r--src/gallium/auxiliary/gallivm/lp_bld_arit.c8
-rw-r--r--src/gallium/auxiliary/gallivm/lp_bld_arit.h4
2 files changed, 12 insertions, 0 deletions
diff --git a/src/gallium/auxiliary/gallivm/lp_bld_arit.c b/src/gallium/auxiliary/gallivm/lp_bld_arit.c
index bbce31f9eb2..f60a7a213ac 100644
--- a/src/gallium/auxiliary/gallivm/lp_bld_arit.c
+++ b/src/gallium/auxiliary/gallivm/lp_bld_arit.c
@@ -669,6 +669,14 @@ lp_build_abs(struct lp_build_context *bld,
LLVMValueRef
+lp_build_negate(struct lp_build_context *bld,
+ LLVMValueRef a)
+{
+ return LLVMBuildNeg(bld->builder, a, "");
+}
+
+
+LLVMValueRef
lp_build_sgn(struct lp_build_context *bld,
LLVMValueRef a)
{
diff --git a/src/gallium/auxiliary/gallivm/lp_bld_arit.h b/src/gallium/auxiliary/gallivm/lp_bld_arit.h
index da84b7ca02d..2d19ec06b43 100644
--- a/src/gallium/auxiliary/gallivm/lp_bld_arit.h
+++ b/src/gallium/auxiliary/gallivm/lp_bld_arit.h
@@ -117,6 +117,10 @@ lp_build_abs(struct lp_build_context *bld,
LLVMValueRef a);
LLVMValueRef
+lp_build_negate(struct lp_build_context *bld,
+ LLVMValueRef a);
+
+LLVMValueRef
lp_build_sgn(struct lp_build_context *bld,
LLVMValueRef a);