" result |= 0x4;\n"
: (OPTYPE_ALLEQUAL == caseDef.opType || OPTYPE_ALLEQUAL_ARB == caseDef.opType) ?
" " + subgroups::getFormatNameForGLSL(caseDef.format) + " valueEqual = " + subgroups::getFormatNameForGLSL(caseDef.format) + "(1.25 * float(data[gl_SubgroupInvocationID]) + 5.0);\n" +
- " " + subgroups::getFormatNameForGLSL(caseDef.format) + " valueNoEqual = " + subgroups::getFormatNameForGLSL(caseDef.format) + "(gl_SubgroupInvocationID);\n" +
- " result = " + getOpTypeName(caseDef.opType) + "("+ (arbFunctions ? "bool(" : "")
- + subgroups::getFormatNameForGLSL(caseDef.format) + "(1))" + (arbFunctions ? ")" : "") + " ? 0x1 : 0;\n"
- " " + subgroups::getFormatNameForGLSL(caseDef.format) + " valueNoEqual = " + subgroups::getFormatNameForGLSL(caseDef.format) + (formatIsBoolean ? "(subgroupElect())\n;" : "(12.0 * float(data[gl_SubgroupInvocationID]) + gl_SubgroupInvocationID);\n") +
++ " " + subgroups::getFormatNameForGLSL(caseDef.format) + " valueNoEqual = " + subgroups::getFormatNameForGLSL(caseDef.format) + (formatIsBoolean ? "(subgroupElect())\n;" : "(gl_SubgroupInvocationID);\n") +
+ " result = " + getOpTypeName(caseDef.opType) + "(" +
+ subgroups::getFormatNameForGLSL(caseDef.format) + "(1)) ? 0x1 : 0;\n"
" result |= " + getOpTypeName(caseDef.opType) + (arbFunctions ? "(bool" : "") +
"(gl_SubgroupInvocationID)" + (arbFunctions ? ")" : "") + " ? 0 : 0x2;\n"
- " result |= " + getOpTypeName(caseDef.opType) + (arbFunctions ? "(bool" : "") +
- "(data[0])" + (arbFunctions ? ")" : "") + " ? 0x4 : 0;\n"
- " result |= " + getOpTypeName(caseDef.opType) + (arbFunctions ? "(bool" : "") +
- "(valueEqual)" + (arbFunctions ? ")" : "") + " ? 0x8 : 0x0;\n"
- " result |= " + getOpTypeName(caseDef.opType) + (arbFunctions ? "(bool" : "") +
- "(valueNoEqual)" + (arbFunctions ? ")" : "") + " ? 0x0 : 0x10;\n"
+ " result |= " + getOpTypeName(caseDef.opType) + "(data[0]) ? 0x4 : 0;\n"
+ " result |= " + getOpTypeName(caseDef.opType) + "(valueEqual) ? 0x8 : 0x0;\n"
+ " result |= " + getOpTypeName(caseDef.opType) + "(valueNoEqual) ? 0x0 : 0x10;\n"
" if (subgroupElect()) result |= 0x2 | 0x10;\n"
: "";
" result |= 0x4;\n"
: (OPTYPE_ALLEQUAL == caseDef.opType || OPTYPE_ALLEQUAL_ARB == caseDef.opType) ?
" " + subgroups::getFormatNameForGLSL(caseDef.format) + " valueEqual = " + subgroups::getFormatNameForGLSL(caseDef.format) + "(1.25 * float(data[gl_SubgroupInvocationID]) + 5.0);\n" +
- " " + subgroups::getFormatNameForGLSL(caseDef.format) + " valueNoEqual = " + subgroups::getFormatNameForGLSL(caseDef.format) + "(gl_SubgroupInvocationID);\n" +
- " result |= " + getOpTypeName(caseDef.opType) + "("+ (arbFunctions ? "bool(" : "")
- + subgroups::getFormatNameForGLSL(caseDef.format) + "(1))" + (arbFunctions ? ")" : "") + " ? 0x10 : 0;\n"
- " " + subgroups::getFormatNameForGLSL(caseDef.format) + " valueNoEqual = " + subgroups::getFormatNameForGLSL(caseDef.format) + (formatIsBoolean ? "(subgroupElect());\n" : "(12.0 * float(data[gl_SubgroupInvocationID]) + int(gl_FragCoord.x*gl_SubgroupInvocationID));\n") +
++ " " + subgroups::getFormatNameForGLSL(caseDef.format) + " valueNoEqual = " + subgroups::getFormatNameForGLSL(caseDef.format) + (formatIsBoolean ? "(subgroupElect());\n" : "(gl_SubgroupInvocationID);\n") +
+ " result |= " + getOpTypeName(caseDef.opType) + "("
+ + subgroups::getFormatNameForGLSL(caseDef.format) + "(1)) ? 0x10 : 0;\n"
" result |= " + getOpTypeName(caseDef.opType) + (arbFunctions ? "(bool" : "") +
"(gl_SubgroupInvocationID)" + (arbFunctions ? ")" : "") + " ? 0 : 0x2;\n"
- " result |= " + getOpTypeName(caseDef.opType) + (arbFunctions ? "(bool" : "") +
- "(data[0])" + (arbFunctions ? ")" : "") + " ? 0x4 : 0;\n"
- " result |= " + getOpTypeName(caseDef.opType) + (arbFunctions ? "(bool" : "") +
- "(valueEqual)" + (arbFunctions ? ")" : "") + " ? 0x8 : 0x0;\n"
- " result |= " + getOpTypeName(caseDef.opType) +
- "(gl_HelperInvocation) ? 0x0 : 0x1;\n"
+ " result |= " + getOpTypeName(caseDef.opType) + "(data[0]) ? 0x4 : 0;\n"
+ " result |= " + getOpTypeName(caseDef.opType) + "(valueEqual) ? 0x8 : 0x0;\n"
+ " result |= " + getOpTypeName(caseDef.opType) + "(gl_HelperInvocation) ? 0x0 : 0x1;\n"
" if (subgroupElect()) result |= 0x2 | 0x10;\n"
: "";
else if (OPTYPE_ALLEQUAL == caseDef.opType || OPTYPE_ALLEQUAL_ARB == caseDef.opType)
{
- src << " " << subgroups::getFormatNameForGLSL(caseDef.format) <<" valueEqual = " << subgroups::getFormatNameForGLSL(caseDef.format) << "(1.25 * float(data[gl_SubgroupInvocationID]) + 5.0);\n"
- << " " << subgroups::getFormatNameForGLSL(caseDef.format) <<" valueNoEqual = " << subgroups::getFormatNameForGLSL(caseDef.format) << (formatIsBoolean ? "(subgroupElect());\n" : "(12.0 * float(data[gl_SubgroupInvocationID]) + offset);\n")
+ src << " " << subgroups::getFormatNameForGLSL(caseDef.format) << " valueEqual = " << subgroups::getFormatNameForGLSL(caseDef.format) << "(1.25 * float(data[gl_SubgroupInvocationID]) + 5.0);\n"
- << " " << subgroups::getFormatNameForGLSL(caseDef.format) << " valueNoEqual = " << subgroups::getFormatNameForGLSL(caseDef.format) << "(gl_SubgroupInvocationID);\n"
- <<" result[offset] = " << getOpTypeName(caseDef.opType) << "(" << (arbFunctions ? "bool(" : "")
- << subgroups::getFormatNameForGLSL(caseDef.format) << "(1))" << (arbFunctions ? ")" : "") << " ? 0x1 : 0;\n"
++ << " " << subgroups::getFormatNameForGLSL(caseDef.format) << " valueNoEqual = " << subgroups::getFormatNameForGLSL(caseDef.format) << (formatIsBoolean ? "(subgroupElect());\n" : "(gl_SubgroupInvocationID);\n")
+ <<" result[offset] = " << getOpTypeName(caseDef.opType) << "("
+ << subgroups::getFormatNameForGLSL(caseDef.format) << "(1)) ? 0x1 : 0;\n"
<< " result[offset] |= " << getOpTypeName(caseDef.opType) << (arbFunctions ? "(bool" : "")
<< "(gl_SubgroupInvocationID)" << (arbFunctions ? ")" : "") << " ? 0x0 : 0x2;\n"
- << " result[offset] |= " << getOpTypeName(caseDef.opType) << (arbFunctions ? "(bool" : "")
- << "(data[0])" << (arbFunctions ? ")" : "") << " ? 0x4 : 0x0;\n"
- << " result[offset] |= "<< getOpTypeName(caseDef.opType) << (arbFunctions ? "(bool" : "")
- << "(valueEqual)" << (arbFunctions ? ")" : "") << " ? 0x8 : 0x0;\n"
- << " result[offset] |= "<< getOpTypeName(caseDef.opType) << (arbFunctions ? "(bool" : "")
- << "(valueNoEqual)" << (arbFunctions ? ")" : "") << " ? 0x0 : 0x10;\n"
+ << " result[offset] |= " << getOpTypeName(caseDef.opType) << "(data[0]) ? 0x4 : 0x0;\n"
+ << " result[offset] |= "<< getOpTypeName(caseDef.opType) << "(valueEqual) ? 0x8 : 0x0;\n"
+ << " result[offset] |= "<< getOpTypeName(caseDef.opType) << "(valueNoEqual) ? 0x0 : 0x10;\n"
<< " if (subgroupElect()) result[offset] |= 0x2 | 0x10;\n";
}
" result[offset] |= 0x4;\n"
: (OPTYPE_ALLEQUAL == caseDef.opType || OPTYPE_ALLEQUAL_ARB == caseDef.opType) ?
" " + subgroups::getFormatNameForGLSL(caseDef.format) + " valueEqual = " + subgroups::getFormatNameForGLSL(caseDef.format) + "(1.25 * float(data[gl_SubgroupInvocationID]) + 5.0);\n" +
- " " + subgroups::getFormatNameForGLSL(caseDef.format) + " valueNoEqual = " + subgroups::getFormatNameForGLSL(caseDef.format) + (formatIsBoolean ? "(subgroupElect());\n" : "(12.0 * float(data[gl_SubgroupInvocationID]) + gl_SubgroupInvocationID);\n") +
+ " " + subgroups::getFormatNameForGLSL(caseDef.format) + " valueNoEqual = " + subgroups::getFormatNameForGLSL(caseDef.format) + "(gl_SubgroupInvocationID);\n" +
- " result[offset] = " + getOpTypeName(caseDef.opType) + "("+ (arbFunctions ? "bool(" : "")
- + subgroups::getFormatNameForGLSL(caseDef.format) + "(1))" + (arbFunctions ? ")" : "") + " ? 0x1 : 0;\n"
+ " result[offset] = " + getOpTypeName(caseDef.opType) + "("
+ + subgroups::getFormatNameForGLSL(caseDef.format) + "(1)) ? 0x1 : 0;\n"
" result[offset] |= " + getOpTypeName(caseDef.opType) + (arbFunctions ? "(bool" : "") +
"(gl_SubgroupInvocationID)" + (arbFunctions ? ")" : "") + " ? 0 : 0x2;\n"
- " result[offset] |= " + getOpTypeName(caseDef.opType) + (arbFunctions ? "(bool" : "") +
- "(data[0])" + (arbFunctions ? ")" : "") + " ? 0x4 : 0;\n"
- " result[offset] |= " + getOpTypeName(caseDef.opType) + (arbFunctions ? "(bool" : "") +
- "(valueEqual)" + (arbFunctions ? ")" : "") + " ? 0x8 : 0x0;\n"
- " result[offset] |= " + getOpTypeName(caseDef.opType) + (arbFunctions ? "(bool" : "") +
- "(valueNoEqual)" + (arbFunctions ? ")" : "") + " ? 0x0 : 0x10;\n"
+ " result[offset] |= " + getOpTypeName(caseDef.opType) + "(data[0]) ? 0x4 : 0;\n"
+ " result[offset] |= " + getOpTypeName(caseDef.opType) + "(valueEqual) ? 0x8 : 0x0;\n"
+ " result[offset] |= " + getOpTypeName(caseDef.opType) + "(valueNoEqual) ? 0x0 : 0x10;\n"
" if (subgroupElect()) result[offset] |= 0x2 | 0x10;\n"
: "";
" result |= 0x4;\n"
: (OPTYPE_ALLEQUAL == caseDef.opType || OPTYPE_ALLEQUAL_ARB == caseDef.opType) ?
" " + subgroups::getFormatNameForGLSL(caseDef.format) + " valueEqual = " + subgroups::getFormatNameForGLSL(caseDef.format) + "(1.25 * float(data[gl_SubgroupInvocationID]) + 5.0);\n" +
- " " + subgroups::getFormatNameForGLSL(caseDef.format) + " valueNoEqual = " + subgroups::getFormatNameForGLSL(caseDef.format) + "(gl_SubgroupInvocationID);\n" +
- " result = " + getOpTypeName(caseDef.opType) + "("+ (arbFunctions ? "bool(" : "")
- + subgroups::getFormatNameForGLSL(caseDef.format) + "(1))" + (arbFunctions ? ")" : "") + " ? 0x1 : 0;\n"
- " " + subgroups::getFormatNameForGLSL(caseDef.format) + " valueNoEqual = " + subgroups::getFormatNameForGLSL(caseDef.format) + (formatIsBoolean ? "(subgroupElect());\n" : "(12.0 * float(data[gl_SubgroupInvocationID]) + int(gl_FragCoord.x*gl_SubgroupInvocationID));\n") +
++ " " + subgroups::getFormatNameForGLSL(caseDef.format) + " valueNoEqual = " + subgroups::getFormatNameForGLSL(caseDef.format) + (formatIsBoolean ? "(subgroupElect());\n" : "(gl_SubgroupInvocationID);\n") +
+ " result = " + getOpTypeName(caseDef.opType) + "("
+ + subgroups::getFormatNameForGLSL(caseDef.format) + "(1)) ? 0x1 : 0;\n"
" result |= " + getOpTypeName(caseDef.opType) + (arbFunctions ? "(bool" : "") +
"(gl_SubgroupInvocationID)" + (arbFunctions ? ")" : "") + " ? 0 : 0x2;\n"
- " result |= " + getOpTypeName(caseDef.opType) + (arbFunctions ? "(bool" : "") +
- "(data[0])" + (arbFunctions ? ")" : "") + " ? 0x4 : 0;\n"
- " result |= " + getOpTypeName(caseDef.opType) + (arbFunctions ? "(bool" : "") +
- "(valueEqual)" + (arbFunctions ? ")" : "") + " ? 0x8 : 0x0;\n"
- " result |= " + getOpTypeName(caseDef.opType) + (arbFunctions ? "(bool" : "") +
- "(valueNoEqual)" + (arbFunctions ? ")" : "") + " ? 0x0 : 0x10;\n"
+ " result |= " + getOpTypeName(caseDef.opType) + "(data[0]) ? 0x4 : 0;\n"
+ " result |= " + getOpTypeName(caseDef.opType) + "(valueEqual) ? 0x8 : 0x0;\n"
+ " result |= " + getOpTypeName(caseDef.opType) + "(valueNoEqual) ? 0x0 : 0x10;\n"
" if (subgroupElect()) result |= 0x2 | 0x10;\n"
: "";
const string fragment =