clang/test/CodeGen/PowerPC/musttail-inline.c
raw| 1 | // RUN: %clang_cc1 %s -triple powerpc64-unknown-linux-gnu -o /dev/null -emit-llvm -verify |
| 2 | // RUN: %clang_cc1 %s -triple powerpc64le-unknown-linux-gnu -o /dev/null -emit-llvm -verify |
| 3 | |
| 4 | inline int foo(int x) { |
| 5 | return x; |
| 6 | } |
| 7 | |
| 8 | int bar(int x) |
| 9 | { |
| 10 | // expected-error@+1 {{'musttail' attribute for this call is impossible because external calls cannot be tail called on PPC}} |
| 11 | [[clang::musttail]] return foo(1); |
| 12 | } |