Adjust the testsuite after various changes (rpass, libclang, polly lib, etc)

This commit is contained in:
Sylvestre Ledru 2021-10-04 09:20:07 +02:00
parent b2438aba01
commit 8380a94581
2 changed files with 13 additions and 2 deletions

2
debian/changelog vendored
View File

@ -2,6 +2,8 @@ llvm-toolchain-13 (1:13.0.0-2) unstable; urgency=medium
* Fix the libclang detection in cmake
(Closes: #994827)
* Adjust the testsuite after various changes
(rpass, libclang, polly lib, etc)
-- Sylvestre Ledru <sylvestre@debian.org> Sun, 03 Oct 2021 22:38:18 +0200

View File

@ -1250,9 +1250,18 @@ fi
echo "
int foo(int x, int y) __attribute__((always_inline));
int foo(int x, int y) { return x + y; }
int bar(int j) { return foo(j, j - 2); }" > foo.cc
int bar(int j) { return foo(j, j - 2); }
int sum = 0;
int main(int argc, const char *argv[]) {
for (int i = 0; i < 30; i++)
bar(argc);
return sum;
}
" > foo.cc
clang-$VERSION -O2 -Rpass=inline foo.cc -c &> foo.log
if ! grep -q "cost=always" foo.log; then
if ! grep -q -E "(inlined into main with|cost=always)" foo.log; then
echo "-Rpass fails"
cat foo.log
exit 1