| /llvm-project-15.0.7/clang/test/SemaCXX/ |
| H A D | attr-noreturn.cpp | 7 __attribute__((noreturn)) void fail(); 21 __attribute__((noreturn)) void fail(); 24 ~A() __attribute__((noreturn)) { fail(); } in ~A() 28 ~B() __attribute__((noreturn)) { fail(); } in ~B() 131 __attribute__((noreturn)) void test31() { in test31() 134 __attribute__((noreturn)) void test32() { in test32() 141 __attribute__((noreturn)) void test33() { in test33() 147 __attribute__((noreturn)) void test34() { in test34() 156 __attribute__((noreturn)) ~T(); 199 int blah() __attribute__((noreturn)); [all …]
|
| H A D | cxx11-gnu-attrs.cpp | 59 int noreturn [[gnu::noreturn]]; // expected-warning {{'noreturn' only applies to function types}} variable 61 int noreturn_fn_2() [[gnu::noreturn]]; // expected-warning {{cannot be applied to a type}} 62 int noreturn_fn_3 [[gnu::noreturn]] (); 63 [[gnu::noreturn]] int noreturn_fn_4(); 64 int (*noreturn_fn_ptr_1 [[gnu::noreturn]])() = &noreturn_fn_1; // expected-error {{cannot initializ… 65 int (*noreturn_fn_ptr_2 [[gnu::noreturn]])() = &noreturn_fn_3; 66 [[gnu::noreturn]] int (*noreturn_fn_ptr_3)() = &noreturn_fn_1; // expected-error {{cannot initializ… 67 [[gnu::noreturn]] int (*noreturn_fn_ptr_4)() = &noreturn_fn_3;
|
| /llvm-project-15.0.7/clang/test/Sema/ |
| H A D | attr-noreturn.c | 3 static void (*fp0)(void) __attribute__((noreturn)); 7 static void __attribute__((noreturn)) f0(void) { in f0() 12 int f1() __attribute__((noreturn)); 18 void f3(void) __attribute__((noreturn)); 25 void f4(void) __attribute__((noreturn)); 40 __attribute__((noreturn)) void f(__attribute__((noreturn)) void (*x)(void)) { in f() 49 fn_t *fp __attribute__((noreturn)); 50 void __attribute__((noreturn)) f6(int i) { in f6() 54 fn_t *fps[4] __attribute__((noreturn)); 66 fn_t *fp[n] __attribute__((noreturn)); in f9() [all …]
|
| H A D | c2x-noreturn.c | 8 #if !__has_c_attribute(noreturn) 16 #if __has_c_attribute(noreturn) != __has_c_attribute(_Noreturn) || \ 17 __has_c_attribute(noreturn) != 202202L 27 [[noreturn]] int not_a_func; // all-error {{'noreturn' attribute only applies to functions}} 28 void func5(void) [[noreturn]]; // all-error {{'noreturn' attribute cannot be applied to types}} 32 [[noreturn]] void func2(void); 41 [[noreturn]] void func6(void); 43 void func7 [[noreturn]] (void); 45 noreturn void func8(void); 48 void noreturn func9(void); [all …]
|
| H A D | return.c | 36 void halt2(void) __attribute__((noreturn)); 63 int halt3(void) __attribute__((noreturn)); 161 void (*fptr)(void) __attribute__((noreturn)); 192 void test28() __attribute__((noreturn)); 203 extern void longjmp (struct __jmp_buf_tag __env[1], int __val) __attribute__ ((noreturn)); 204 extern void _longjmp (struct __jmp_buf_tag __env[1], int __val) __attribute__ ((noreturn)); 220 void test31(test31_t *callback __attribute__((noreturn))); 299 void abort(void) __attribute__((noreturn));
|
| H A D | initialize-noreturn.c | 4 typedef void (*Fn_noret)(void) __attribute__((noreturn)); 7 typedef void (*Fn_noret_noproto)() __attribute__((noreturn)); 11 void foo_noret(void) __attribute__((noreturn)); 14 void foo_noret_noproto() __attribute__((noreturn));
|
| /llvm-project-15.0.7/clang/test/CXX/dcl.dcl/dcl.attr/dcl.attr.noreturn/ |
| H A D | p1.cpp | 3 [[noreturn]] void a() { in a() 6 void a2 [[noreturn]] () { in a2() 10 template <typename T> void a3 [[noreturn]] () {} in a3() 17 [[noreturn, noreturn]] void b() { throw 0; } // ok in b() 18 [[noreturn]] [[noreturn]] void b2() { throw 0; } // ok in b2() 22 void d() [[noreturn]]; // expected-error {{'noreturn' attribute cannot be applied to types}} 23 int d2 [[noreturn]]; // expected-error {{'noreturn' attribute only applies to functions}} 25 [[noreturn]] int e() { b2(); } // ok in e() 31 [[noreturn]] int g(); 33 [[noreturn]] int g(); [all …]
|
| /llvm-project-15.0.7/llvm/test/Transforms/FunctionAttrs/ |
| H A D | noreturn.ll | 5 ; CHECK: Function Attrs: noreturn 6 ; CHECK-NEXT: @noreturn() 7 declare i32 @noreturn() noreturn 9 ; CHECK: Function Attrs: noreturn 12 %c = call i32 @noreturn() 16 ; CHECK: Function Attrs: noreturn 23 ; CHECK: Function Attrs: noreturn 29 %c = call i32 @noreturn() 47 %c = call i32 @noreturn() 57 %c = call i32 @noreturn() [all …]
|
| /llvm-project-15.0.7/clang/test/Parser/ |
| H A D | objcxx11-attributes.mm | 11 void f(X *noreturn) { 13 int a[ [noreturn getSize] ]; 16 int b[ [noreturn] ]; // expected-error {{'noreturn' attribute only applies to functions}} 18 int c[ [noreturn getSize] + 1 ]; 21 …int d[ [noreturn] { return 3; } () ]; // expected-error {{expected ']'}} expected-error {{'noretur… 28 [ [noreturn] { return noreturn; } () setSize: 4 ]; 29 [ [bitand] { return noreturn; } () setSize: 5 ]; 39 …[[bitand, noreturn]]; // expected-error {{'noreturn' attribute cannot be applied to a statement}} \ 46 // A function taking a noreturn function. 52 int(g)([[noreturn getSelf] getSize]); [all …]
|
| H A D | attr-order.cpp | 12 [[noreturn]] __attribute__((cdecl)) __declspec(dllexport) void a(); // ok 13 [[noreturn]] __declspec(dllexport) __attribute__((cdecl)) void b(); // ok 14 [[]] [[noreturn]] __attribute__((cdecl)) __declspec(dllexport) void c(); // ok 17 __declspec(dllexport) [[noreturn]] __attribute__((cdecl)) void d(); // expected-error {{an attribut… 18 __declspec(dllexport) __attribute__((cdecl)) [[noreturn]] void e(); // expected-error {{an attribut… 19 __attribute__((cdecl)) __declspec(dllexport) [[noreturn]] void f(); // expected-error {{an attribut… 20 __attribute__((cdecl)) [[noreturn]] __declspec(dllexport) void g(); // expected-error {{an attribut… 22 [[noreturn]] __attribute__((cdecl))
|
| H A D | cxx0x-attributes.cpp | 45 int & [[noreturn]] ref_attr_3 = after_attr; // expected-error {{'noreturn' attribute cannot be appl… 137 [[noreturn]] using namespace ns; // expected-error {{'noreturn' attribute only applies to functions… 174 using T [[noreturn]] = int; // expected-error {{'noreturn' attribute only applies to functions}} 209 friend int f1 [[noreturn]] (); //expected-error{{an attribute list cannot appear here}} 210 friend int f2 [[]] [[noreturn]] () {} 215 …friend int f6 [[noreturn]] (), f7 [[noreturn]] (), f8 [[noreturn]] (); // expected-error3 {{an att… 256 void bar [[noreturn]] ([[]] int i, [[]] int j); 264 …void bar [[noreturn...]] (); // expected-error {{attribute 'noreturn' cannot be used as an attribu… 285 …[] () [[gnu::noreturn]] { return; } (); // expected-warning {{attribute 'noreturn' ignored}} FIXME… 286 [] () [[gnu::noreturn]] { throw; } (); // expected-warning {{attribute 'noreturn' ignored}} [all …]
|
| H A D | cxx11-stmt-attributes.cpp | 31 [[noreturn]] { } // expected-error {{'noreturn' attribute cannot be applied to a statement}} in foo() 32 …[[noreturn]] if (0) { } // expected-error {{'noreturn' attribute cannot be applied to a statement}} in foo() 33 [[noreturn]] for (;;); // expected-error {{'noreturn' attribute cannot be applied to a statement}} in foo() 34 [[noreturn]] do { // expected-error {{'noreturn' attribute cannot be applied to a statement}} in foo()
|
| /llvm-project-15.0.7/llvm/include/llvm/TableGen/ |
| H A D | Error.h | 25 [[noreturn]] void PrintFatalNote(const Twine &Msg); 26 [[noreturn]] void PrintFatalNote(ArrayRef<SMLoc> ErrorLoc, const Twine &Msg); 27 [[noreturn]] void PrintFatalNote(const Record *Rec, const Twine &Msg); 28 [[noreturn]] void PrintFatalNote(const RecordVal *RecVal, const Twine &Msg); 40 [[noreturn]] void PrintFatalError(const Twine &Msg); 41 [[noreturn]] void PrintFatalError(ArrayRef<SMLoc> ErrorLoc, const Twine &Msg); 42 [[noreturn]] void PrintFatalError(const Record *Rec, const Twine &Msg); 43 [[noreturn]] void PrintFatalError(const RecordVal *RecVal, const Twine &Msg);
|
| /llvm-project-15.0.7/llvm/test/Transforms/HotColdSplit/ |
| H A D | noreturn.ll | 9 ; Don't outline noreturn calls which aren't explicitly marked cold. 26 ; Don't outline within a noreturn function. 30 define void @xpc_objc_main(i32) noreturn { 44 ; Do outline noreturn calls marked cold. 62 ; Do outline noreturn calls preceded by a cold call. 83 ; CHECK: attributes [[XPC_OBJC_MAIN_ATTRS]] = { noreturn } 87 declare void @llvm.trap() noreturn cold 91 declare void @longjmp(%struct.__jmp_buf_tag*, i32) noreturn nounwind
|
| /llvm-project-15.0.7/llvm/include/llvm/Support/ |
| H A D | ErrorHandling.h | 71 [[noreturn]] void report_fatal_error(const char *reason, 73 [[noreturn]] void report_fatal_error(StringRef reason, 75 [[noreturn]] void report_fatal_error(const Twine &reason, 114 [[noreturn]] void report_bad_alloc_error(const char *Reason, 120 [[noreturn]] void
|
| /llvm-project-15.0.7/flang/runtime/ |
| H A D | stop.cpp | 53 [[noreturn]] void RTNAME(StopStatement)( in RTNAME() 70 [[noreturn]] void RTNAME(StopStatementText)( in RTNAME() 129 [[noreturn]] void RTNAME(FailImageStatement)() { in RTNAME() 135 [[noreturn]] void RTNAME(ProgramEndStatement)() { in RTNAME() 140 [[noreturn]] void RTNAME(Exit)(int status) { in RTNAME() 145 [[noreturn]] void RTNAME(Abort)() { std::abort(); } in RTNAME() 147 [[noreturn]] void RTNAME(ReportFatalUserError)( in RTNAME()
|
| /llvm-project-15.0.7/llvm/test/Instrumentation/AddressSanitizer/ |
| H A D | instrument-no-return.ll | 3 ; before noreturn calls that aren't inserted by sanitizers. 9 declare void @NoReturnFunc() noreturn 11 ; Instrument noreturn callsites (regardless of function) 13 call void @NormalFunc() noreturn 20 ; Instrument calls to noreturn functions (regardless of callsite) 31 call void @NoReturnFunc() noreturn, !nosanitize !{} 40 call void @NoReturnFunc() noreturn
|
| /llvm-project-15.0.7/llvm/test/CodeGen/ARM/ |
| H A D | call-noret-minsize.ll | 5 define void @t1() noreturn minsize nounwind ssp { 12 tail call void @bar() noreturn nounwind 16 define void @t2() noreturn minsize nounwind ssp { 23 tail call void @t1() noreturn nounwind 27 declare void @bar() noreturn
|
| H A D | call-noret.ll | 5 define void @t1() noreturn nounwind ssp { 14 tail call void @bar() noreturn nounwind 18 define void @t2() noreturn nounwind ssp { 27 tail call void @t1() noreturn nounwind 31 declare void @bar() noreturn
|
| /llvm-project-15.0.7/llvm/test/DebugInfo/X86/ |
| H A D | noreturn_objc.ll | 5 ; __attribute__ ((noreturn)) void f() 21 ; Function Attrs: noreturn 31 ; Function Attrs: noreturn 34 attributes #0 = { noreturn } 41 !1 = !DIFile(filename: "test.m", directory: "/home/del/test/noreturn/objc") 47 !7 = !DIFile(filename: "./test.m", directory: "/home/del/test/noreturn/objc")
|
| /llvm-project-15.0.7/llvm/test/CodeGen/Hexagon/ |
| H A D | noreturn-stack-elim.ll | 2 ; RUN: llc -mtriple=hexagon-unknown--elf -hexagon-initial-cfg-cleanup=false -mattr=+noreturn-stack-… 4 ; Test the noreturn stack elimination feature. We've added a new flag/feature 5 ; that attempts to eliminate the local stack for noreturn nounwind functions. 11 ; Test the case when noreturn-stack-elim determins that both callee saved 31 ; Test that noreturn-stack-elim doesn't eliminate the local stack, when 49 ; Test that noreturn-stack-elim can elimnate the allocframe when no locals 89 attributes #0 = { noreturn nounwind } 90 attributes #2 = { noreturn } 92 attributes #4 = { noreturn nounwind }
|
| H A D | trap-crash.ll | 9 ; Function Attrs: noreturn nounwind 16 ; Function Attrs: cold noreturn nounwind 19 attributes #0 = { noreturn nounwind "target-cpu"="hexagonv60" } 20 attributes #1 = { cold noreturn nounwind }
|
| /llvm-project-15.0.7/clang/test/SemaObjC/ |
| H A D | return.m | 1 // RUN: %clang_cc1 -fsyntax-only -verify -Wmissing-noreturn -fobjc-exceptions -Wno-objc-root-class … 17 …est3(int a) { // expected-warning {{function 'test3' could be declared with attribute 'noreturn'}} 25 // issue a noreturn warning. 42 void exit(int) __attribute__((noreturn)); 47 - (void)method { // expected-warning{{method 'method' could be declared with attribute 'noreturn'}}
|
| /llvm-project-15.0.7/clang/test/CodeGenCXX/ |
| H A D | ubsan-unreachable.cpp | 3 void abort() __attribute__((noreturn)); 28 static void does_not_return1() __attribute__((noreturn)) { in does_not_return1() 42 typedef void (A::*MemFn)() __attribute__((noreturn)); 57 void does_not_return2() __attribute__((noreturn)) { in does_not_return2()
|
| /llvm-project-15.0.7/llvm/test/Transforms/SimplifyCFG/ |
| H A D | noreturn-call.ll | 5 declare void @Finisher(i32) noreturn 13 tail call void @Finisher(i32 %0) noreturn 14 tail call void @Finisher(i32 %0) noreturn 29 ; CHECK: attributes #0 = { noreturn } 30 attributes #0 = { noreturn }
|