aboutsummaryrefslogtreecommitdiff
path: root/clang/test/CodeGen/builtin-count-zeros.c
AgeCommit message (Collapse)AuthorFilesLines
2012-01-26Make clz/ctz builtins defined for zero on ARM targets. rdar://10732455Bob Wilson1-2/+6
ARM supports clz and ctz directly and both operations have well-defined results for zero. There is no disadvantage in performance to using the defined-at-zero versions of llvm.ctlz/cttz intrinsics. We're running into ARM-specific code written with the assumption that __builtin_clz(0) == 32, even though that value is technically undefined. The code is failing now because of llvm optimizations that are taking advantage of the undef behavior (specifically svn r147255). There's nothing wrong with that optimization on x86 where any incorrect assumptions about __builtin_clz(0) will quickly be exposed. For ARM, though, optimizations based on that undef behavior are likely to cause subtle bugs. Other targets with defined-at-zero clz/ctz support may want to override the default behavior as well. llvm-svn: 149086
2009-12-15Update tests to use %clang_cc1 instead of 'clang-cc' or 'clang -cc1'.Daniel Dunbar1-2/+2
- This is designed to make it obvious that %clang_cc1 is a "test variable" which is substituted. It is '%clang_cc1' instead of '%clang -cc1' because it can be useful to redefine what gets run as 'clang -cc1' (for example, to set a default target). llvm-svn: 91446
2009-11-08Eliminate &&s in tests.Daniel Dunbar1-1/+1
- 'for i in $(find . -type f); do sed -e 's#\(RUN:.*[^ ]\) *&& *$#\1#g' $i | FileUpdate $i; done', for the curious. llvm-svn: 86430
2009-03-24Rename clang to clang-cc.Daniel Dunbar1-2/+2
Tests and drivers updated, still need to shuffle dirs. llvm-svn: 67602
2008-06-12Multiple tests in a single test file must be linked with '&&'.Argyrios Kyrtzidis1-1/+1
Otherwise, failing tests other than the last one will not be reported. llvm-svn: 52231
2008-05-27Implementation of __builtin_ctlz.Eli Friedman1-0/+4
llvm-svn: 51595