[libclc] r184993 - libclc: Fix abs_diff builtin integer function

Tom Stellard thomas.stellard at amd.com
Wed Jun 26 11:20:50 PDT 2013


Author: tstellar
Date: Wed Jun 26 13:20:50 2013
New Revision: 184993

URL: http://llvm.org/viewvc/llvm-project?rev=184993&view=rev
Log:
libclc: Fix abs_diff builtin integer function

Patch by: Aaron Watry

Modified:
    libclc/trunk/generic/lib/SOURCES
    libclc/trunk/generic/lib/integer/abs_diff.inc

Modified: libclc/trunk/generic/lib/SOURCES
URL: http://llvm.org/viewvc/llvm-project/libclc/trunk/generic/lib/SOURCES?rev=184993&r1=184992&r2=184993&view=diff
==============================================================================
--- libclc/trunk/generic/lib/SOURCES (original)
+++ libclc/trunk/generic/lib/SOURCES Wed Jun 26 13:20:50 2013
@@ -4,6 +4,7 @@ geometric/dot.cl
 geometric/length.cl
 geometric/normalize.cl
 integer/abs.cl
+integer/abs_diff.cl
 integer/add_sat.cl
 integer/add_sat.ll
 integer/add_sat_impl.ll

Modified: libclc/trunk/generic/lib/integer/abs_diff.inc
URL: http://llvm.org/viewvc/llvm-project/libclc/trunk/generic/lib/integer/abs_diff.inc?rev=184993&r1=184992&r2=184993&view=diff
==============================================================================
--- libclc/trunk/generic/lib/integer/abs_diff.inc (original)
+++ libclc/trunk/generic/lib/integer/abs_diff.inc Wed Jun 26 13:20:50 2013
@@ -1,3 +1,3 @@
-_CLC_OVERLOAD _CLC_DEF UGENTYPE abs_diff(GENTYPE x) {
+_CLC_OVERLOAD _CLC_DEF UGENTYPE abs_diff(GENTYPE x, GENTYPE y) {
   return __builtin_astype((GENTYPE)(x > y ? x-y : y-x), UGENTYPE);
 }





More information about the cfe-commits mailing list