1
- // RUN: %clang_cc1 -std=c++11 -fsyntax-only -triple nvptx-unknown-unknown -target-cpu sm_90 -verify %s
1
+ // RUN: %clang_cc1 -std=c++11 -fsyntax-only -triple nvptx-unknown-unknown -target-cpu sm_90 -verify %s
2
2
3
3
#include " Inputs/cuda.h"
4
4
@@ -12,7 +12,19 @@ __launch_bounds__(1, 1, 0x10000000000000000) void TestWayTooBigArg(void); // exp
12
12
13
13
__launch_bounds__ (-128 , 7 ) void TestNegArg1(void ); // expected-warning {{'launch_bounds' attribute parameter 0 is negative and will be ignored}}
14
14
__launch_bounds__ (128 , -7 ) void TestNegArg2(void ); // expected-warning {{'launch_bounds' attribute parameter 1 is negative and will be ignored}}
15
+ __launch_bounds__ (-128 , 1 , 7 ) void TestNegArg2(void ); // expected-warning {{'launch_bounds' attribute parameter 0 is negative and will be ignored}}
16
+ __launch_bounds__ (128 , -1 , 7 ) void TestNegArg2(void ); // expected-warning {{'launch_bounds' attribute parameter 1 is negative and will be ignored}}
15
17
__launch_bounds__ (128 , 1 , -7 ) void TestNegArg2(void ); // expected-warning {{'launch_bounds' attribute parameter 2 is negative and will be ignored}}
18
+ // expected-warning@20 {{'launch_bounds' attribute parameter 0 is negative and will be ignored}}
19
+ // expected-warning@20 {{'launch_bounds' attribute parameter 1 is negative and will be ignored}}
20
+ __launch_bounds__ (-128 , -1 , 7 ) void TestNegArg2(void );
21
+ // expected-warning@23 {{'launch_bounds' attribute parameter 0 is negative and will be ignored}}
22
+ // expected-warning@23 {{'launch_bounds' attribute parameter 2 is negative and will be ignored}}
23
+ __launch_bounds__ (-128 , 1 , -7 ) void TestNegArg2(void );
24
+ // expected-warning@27 {{'launch_bounds' attribute parameter 0 is negative and will be ignored}}
25
+ // expected-warning@27 {{'launch_bounds' attribute parameter 1 is negative and will be ignored}}
26
+ // expected-warning@27 {{'launch_bounds' attribute parameter 2 is negative and will be ignored}}
27
+ __launch_bounds__ (-128 , -1 , -7 ) void TestNegArg2(void );
16
28
17
29
18
30
__launch_bounds__ (1 , 2 , 3 , 4 ) void Test4Args(void ); // expected-error {{'launch_bounds' attribute takes no more than 3 arguments}}
0 commit comments