/*
 * [config]
 * expect_result: fail
 * glsl_version: 1.50
 * require_extensions: GL_ARB_shader_image_load_store
 * [end config]
 */
#version 150
#extension GL_ARB_shader_image_load_store: require

/*
 * From the ARB_shader_image_load_store spec:
 *
 * "Atomic memory operations are supported on only [...]: an image
 *  variable with signed integer components (iimage*) format qualifier
 *  of 'r32i', or an image variable with unsigned integer components
 *  (uimage*) and format qualifier of 'r32ui'."
 *
 * Call an atomic built-in with a floating point image data type.
 */
layout(r32f) uniform image1D img;

void main()
{
    imageAtomicCompSwap(img , int(0) , float(0), float(0));
}
