summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2013-04-12Initial mad_sat implementation... It's wrong.mad_satAaron Watry6-0/+14
Currently, it just returns x * y + z... no saturation checking is done, but at least the test no longer crashes.
2013-04-11Merge branch 'master' of git://people.freedesktop.org/~awatry/libclcAaron Watry0-0/+0
2013-04-11libclc: Fix libclc build for LLVM 3.3Aaron Watry1-0/+12
LLVM moved a bunch of IR-related headers for version 3.3. This fixes the libclc build to follow suit.
2013-04-08Add a another TODO note.Aaron Watry1-0/+3
2013-04-08Add a TODO note.Aaron Watry1-0/+4
2013-04-08Simplify rotate implementation a bit..Aaron Watry2-21/+37
Much more understandable/readable as a result, and probably more efficient.
2013-04-08libclc: implement rotate builtinAaron Watry7-0/+55
This implementation does a lot of bit shifting and masking. Suffice to say, this is somewhat suboptimal... but it does look to produce correct results (after the piglit tests were corrected for sign extension issues). Someone who knows LLVM better than I could re-write this more efficiently.
2013-04-08libclc: Move max builtin to shared/Aaron Watry11-16/+10
Max(x,y) is available for all integer/floating types.
2013-04-08libclc: Add clamp() builtin for integer/floating pointAaron Watry6-0/+24
Created under a new shared/ directory for functions which are available for both integer and floating point types.
2013-04-08libclc: Fix abs_diff builtin integer functionAaron Watry2-1/+2
2013-04-08libclc: Add max() builtin functionAaron Watry10-0/+28
Adds this function for both int and floating data types.
2013-04-05configure: Enable building separate libraries for target variantsTom Stellard1-44/+75
2013-03-20libclc: Move max builtin to shared/Aaron Watry11-16/+10
Max(x,y) is available for all integer/floating types.
2013-03-20libclc: Add clamp() builtin for integer/floating pointAaron Watry6-0/+24
Created under a new shared/ directory for functions which are available for both integer and floating point types.
2013-03-20libclc: Fix abs_diff builtin integer functionAaron Watry2-1/+2
2013-03-20libclc: Add max() builtin functionAaron Watry10-0/+28
Adds this function for both int and floating data types.
2013-03-20configure: Enable building separate libraries for target variantsAaron Watry1-44/+75
From: Tom Stellard <thomas.stellard at amd.com>
2013-03-20configure: fix out-of-source buildAaron Watry1-2/+3
From: Niels Ole Salscheider <niels_ole@salscheider-online.de>
2013-03-20libclc: Fix libclc build for LLVM 3.3Aaron Watry1-0/+12
LLVM moved a bunch of IR-related headers for version 3.3. This fixes the libclc build to follow suit.
2013-03-08configure: fix out-of-source buildNiels Ole Salscheider1-2/+3
2013-03-08Fix build with LLVM 3.3Niels Ole Salscheider1-4/+4
2013-02-11Implement ceil() builtinTom Stellard2-0/+7
2013-02-11Implement fmax() and fmin() builtinsTom Stellard9-0/+76
2013-02-11Remove the static keyword from the _CLC_INLINE macroTom Stellard1-1/+1
static functions are not allowed in OpenCL C
2013-02-11Use brackets around include files in length.cl and normalize.clTom Stellard2-2/+2
These functions were not being compiled
2013-02-11Fix typo in include/clc/geometric/length.incTom Stellard1-1/+1
2013-01-11r600: Add overrides fileTom Stellard1-0/+2
2013-01-11Allow targets to override generic implementationsTom Stellard1-0/+8
Targets can override generic implementations by adding a file called OVERRIDES in $(TARGET_DIR)/lib and listing the generic implementations that it wants to override. For example, to override get_group_id() and get_global_size() you would add these lines to the OVERRIDES file: workitem/get_group_id.cl workitem/get_global_size.cl
2013-01-11Revert "configure: Allow targets to override generic cl implementations with ↵Tom Stellard1-6/+2
LLVM IR" This reverts commit 327f78fd8474eb5e0bd13aaba6c9c4dcc9cd1f1d.
2013-01-08Make libclc more Linux FHS conform.Johannes Obermayr1-14/+51
- First introducing a versioning scheme - Add --libexecdir, --includedir and --pkgconfigdir and prefill them as well as --prefix - Build all targets by default - Create clc.pc and install it in $pkgconfigdir - Use clang++ instead of c++ - Rename builtins.bc to built_libs/$triple.bc and install them in $libexecdir - Includes are installed recursively to $includedir - Finally add $(DESTDIR) for 'make install'
2012-11-13s/-ccc-host-triple/-target/Tom Stellard2-2/+2
2012-11-13configure: Disable NVPTX target by defaultTom Stellard1-1/+1
2012-10-16R600: Replace cl implementations with LLVM IR implementationTom Stellard7-22/+76
This allows libclc to be built for R600 with upstream clang and LLVM.
2012-10-16configure: Allow targets to override generic cl implementations with LLVM IRTom Stellard1-2/+6
2012-10-09Merge branch 'master' of http://llvm.org/git/libclcTom Stellard39-72/+439
Conflicts: generic/include/clc/synchronization/barrier.h generic/include/clc/workitem/get_global_id.h generic/include/clc/workitem/get_global_size.h generic/include/clc/workitem/get_group_id.h generic/include/clc/workitem/get_local_id.h generic/include/clc/workitem/get_local_size.h generic/include/clc/workitem/get_num_groups.h
2012-10-09Revert "Remove NVPTX from default targets, so libclc will work with LLVM 3.1"Tom Stellard1-1/+1
This reverts commit 2713c4ebaf42a1def1141005ff61eb2074ef0097.
2012-10-08Implement any() builtin. Patch by Tom Stellard!Peter Collingbourne4-0/+48
git-svn-id: https://llvm.org/svn/llvm-project/libclc/trunk@165386 91177308-0d34-0410-b5e6-96231b3b80d8
2012-10-08Add native_powr builtin. Patch by Tom Stellard!Peter Collingbourne2-0/+2
git-svn-id: https://llvm.org/svn/llvm-project/libclc/trunk@165385 91177308-0d34-0410-b5e6-96231b3b80d8
2012-09-05Add barrier.cl to SOURCES, spotted by Jin Wang.Peter Collingbourne1-0/+1
git-svn-id: https://llvm.org/svn/llvm-project/libclc/trunk@163227 91177308-0d34-0410-b5e6-96231b3b80d8
2012-08-21Add rsqrt builtin. Based on patch by Cassie Epps!Peter Collingbourne3-0/+8
git-svn-id: https://llvm.org/svn/llvm-project/libclc/trunk@162274 91177308-0d34-0410-b5e6-96231b3b80d8
2012-08-21Add floor builtin. Patch by Cassie Epps!Peter Collingbourne2-0/+7
git-svn-id: https://llvm.org/svn/llvm-project/libclc/trunk@162273 91177308-0d34-0410-b5e6-96231b3b80d8
2012-08-05Do not use linkonce_odr linkage in .ll files. This prevented themPeter Collingbourne6-48/+48
from being linked into the library under lazy linkage. git-svn-id: https://llvm.org/svn/llvm-project/libclc/trunk@161314 91177308-0d34-0410-b5e6-96231b3b80d8
2012-08-05PTX: move implementations of work-item and synchronisation functionsPeter Collingbourne18-21/+38
to lib, and add header files in generic. Incorporates a patch by Tom Stellard! git-svn-id: https://llvm.org/svn/llvm-project/libclc/trunk@161313 91177308-0d34-0410-b5e6-96231b3b80d8
2012-08-05Implement sub_sat builtin. Patch by Lei Mou!Peter Collingbourne10-0/+272
git-svn-id: https://llvm.org/svn/llvm-project/libclc/trunk@161312 91177308-0d34-0410-b5e6-96231b3b80d8
2012-08-05Fix declarations of __clc_add_sat_*. Patch by Lei Mou!Peter Collingbourne1-8/+8
git-svn-id: https://llvm.org/svn/llvm-project/libclc/trunk@161311 91177308-0d34-0410-b5e6-96231b3b80d8
2012-06-01configure.py: Add an install rule.Peter Collingbourne2-12/+31
git-svn-id: https://llvm.org/svn/llvm-project/libclc/trunk@157821 91177308-0d34-0410-b5e6-96231b3b80d8
2012-06-01Remove NVPTX from default targets, so libclc will work with LLVM 3.1Tom Stellard1-1/+1
2012-06-01Move R600 headers into generic directoryTom Stellard12-14/+5
2012-06-01r600: Add get_global_size() implementationTom Stellard3-3/+12
2012-06-01r600: Fix get_global_id implementationTom Stellard1-3/+3