diff options
| author | Chris Lattner <sabre@nondot.org> | 2006-01-17 06:24:01 +0000 |
|---|---|---|
| committer | Chris Lattner <sabre@nondot.org> | 2006-01-17 06:24:01 +0000 |
| commit | 514a8f89d01e063451e75be2a6c66a019c321502 (patch) | |
| tree | bce426b9eb4e6610427e2da223d1a30421ffb161 | |
| parent | 234e0789476c50c6285b61ca3c71f6174bcda029 (diff) | |
| download | bcm5719-llvm-514a8f89d01e063451e75be2a6c66a019c321502.tar.gz bcm5719-llvm-514a8f89d01e063451e75be2a6c66a019c321502.zip | |
Ensure that the CFE always emits intrinsics in their unsigned version, not with signed operands
llvm-svn: 25390
| -rw-r--r-- | llvm/test/Regression/CFrontend/2006-01-16-BitCountIntrinsicsUnsigned.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/llvm/test/Regression/CFrontend/2006-01-16-BitCountIntrinsicsUnsigned.c b/llvm/test/Regression/CFrontend/2006-01-16-BitCountIntrinsicsUnsigned.c new file mode 100644 index 00000000000..87909764ab9 --- /dev/null +++ b/llvm/test/Regression/CFrontend/2006-01-16-BitCountIntrinsicsUnsigned.c @@ -0,0 +1,9 @@ +// RUN: %llvmgcc -S %s -o - | grep 'llvm.ctlz.i32(uint' && +// RUN: %llvmgcc -S %s -o - | not grep 'llvm.ctlz.i32(int' + +unsigned t2(unsigned X) { + return __builtin_clz(X); +} +int t1(int X) { + return __builtin_clz(X); +} |

