blob: 8f4bfdcebe19af19465791057e65912eddf31081 [file] [log] [blame]
David Neto8c3d5b42019-10-21 14:50:31 -04001void f0() {
2 [unroll] do {} while (false);
3}
4
5void f1() {
6 [unroll] do {;} while (false);
7}
8
9float f2(float input) {
10 do { return (float4)input; } while (input > 2.0);
11}
12
13void f3(float input) {
14 do ++input; while (input < 10.0);
15}
16
17void f4(float input) {
18 do while (++input < 10.0); while (++input < 10.0); // nest while inside do-while
19}
20
John Kessenich0c6f9362017-04-20 11:08:24 -060021float4 PixelShaderFunction(float input) : COLOR0
John Kessenich119f8f62016-06-05 15:44:07 -060022{
David Neto8c3d5b42019-10-21 14:50:31 -040023 f0();
24 f1();
25 f2(input);
26 f3(input);
27 f4(input);
John Kessenich0c6f9362017-04-20 11:08:24 -060028 return (float4)input;
John Kessenich119f8f62016-06-05 15:44:07 -060029}