1#version 100
2
3// Copyright Alastair F. Donaldson and Hugues Evrard, Imperial College London, 2017
4// Defect found using GLFuzz - https://www.graphicsfuzz.com/
5//
6// Gives compile error on:
7// NVIDIA SHIELD Android TV
8// Model number: P2571
9// GL_VERSION: OpenGL ES 3.2 NVIDIA 361.00
10// GL_VENDOR: NVIDIA Corporation
11// GL_RENDERER: NVIDIA Tegra
12// Android version: 7.0
13
14#ifdef GL_ES
15#ifdef GL_FRAGMENT_PRECISION_HIGH
16precision highp float;
17precision highp int;
18#else
19precision mediump float;
20precision mediump int;
21#endif
22#endif
23
24uniform vec2 injectionSwitch;
25
26void main()
27{
28    int r;
29    int g;
30    int b;
31    int a;
32    r = 100 * int(injectionSwitch.y);
33    g = int(injectionSwitch.x) * int(injectionSwitch.y);
34    b = 2 * int(injectionSwitch.x);
35    a = g - int(injectionSwitch.x);
36    for(
37        int i = 0;
38        i < 10;
39        i ++
40    )
41        {
42            r --;
43            g ++;
44            b ++;
45            a ++;
46            for(
47                int j = 1;
48                j < 10;
49                j ++
50            )
51                {
52                    a ++;
53                    b ++;
54                    g ++;
55                    r --;
56                }
57        }
58    float fr;
59    float fg;
60    float fb;
61    float fa;
62    fr = float(r / 100);
63    fg = float(g / 100);
64    fb = float(b / 100);
65    fa = float(a / 100);
66    gl_FragColor = vec4(r, g, b, a) * ((false ? 1.0 : 1.0) * vec4(1.0));
67}
68