Lines Matching defs:result
2197 // store the result
2341 spv::Id result = createShortCircuit(node->getOp(), *node->getLeft()->getAsTyped(),
2344 builder.setAccessChainRValue(result);
2363 // get result
2367 spv::Id result = createBinaryOperation(node->getOp(), decorations,
2372 if (! result) {
2374 return true; // pick up a child as the place-holder result
2376 builder.setAccessChainRValue(result);
2515 spv::Id result = spv::NoResult;
2518 result = createImageTextureFunctionCall(node);
2519 if (result != spv::NoResult) {
2521 builder.setAccessChainRValue(result);
2559 // GLSL semantics say the result of .length() is an int, while SPIR-V says
2561 // AST expectation of a signed result.
2666 if (! result)
2667 result = createConversion(node->getOp(), decorations, resultType(), operand,
2671 if (! result)
2672 result = createUnaryOperation(node->getOp(), decorations, resultType(), operand,
2676 if (!result) {
2693 result = builder.createOp(static_cast<spv::Op>(spirvInst.id), resultType(), {idImmOp});
2695 result = builder.createBuiltinCall(
2705 if (result) {
2707 result = createInvertedSwizzle(decorations.precision, *node->getOperand(), result);
2708 decorations.addNonUniform(builder, result);
2712 builder.setAccessChainRValue(result);
2747 spv::Id result = createBinaryOperation(op, decorations,
2750 assert(result != spv::NoResult);
2752 // The result of operation is always stored, but conditionally the
2753 // consumed result. The consumed result is always an r-value.
2754 builder.accessChainStore(result,
2759 builder.setAccessChainRValue(result);
2787 return true; // pick up operand as placeholder result
2831 spv::Id result = spv::NoResult;
2842 result = createImageTextureFunctionCall(node);
2843 if (result != spv::NoResult) {
2845 builder.setAccessChainRValue(result);
2851 // "imageStore" is a special case, which has no result
2959 result = handleUserFunctionCall(node);
2960 if (result) {
2962 builder.setAccessChainRValue(result);
3088 // and textureBuffer is the result going forward
3116 // Forward on to createBinaryOperation(), requesting a vector result.
3368 result = createBinaryOperation(binOp, decorations,
3373 assert(result != spv::NoResult);
3375 builder.setAccessChainRValue(result);
3586 // receive the result, and must later swizzle that into the original
3669 spv::Id result = node->getOp() == glslang::EOpCooperativeMatrixLoad
3672 // store the result to the pointer (out param 'm')
3673 builder.createStore(result, operands[0]);
3674 result = 0;
3694 result = 0;
3707 spv::Id result = builder.createOp(spvOp, typeId, idImmOps);
3708 // store the result to the pointer (out param 'm')
3709 builder.createStore(result, operands[2]);
3710 result = 0;
3736 result = builder.createOp(spv::OpCooperativeMatrixMulAddKHR, resultType(), idImmOps);
3741 result = createAtomicOperation(node->getOp(), precision, resultType(), operands, typeProxy,
3762 result = builder.createOp(static_cast<spv::Op>(spirvInst.id), resultType(), idImmOps);
3764 result = builder.createBuiltinCall(
3773 result = builder.createBuiltinCall(builder.makeVoidType(), nonSemanticDebugPrintf, spv::NonSemanticDebugPrintfDebugPrintf, operands);
3779 result = createNoArgOperation(node->getOp(), precision, resultType());
3786 result = createUnaryOperation(
3793 result = createMiscOperation(node->getOp(), precision, resultType(), operands, node->getBasicType());
3798 result = createInvertedSwizzle(precision, *glslangOperands[0]->getAsBinaryNode(), result);
3810 if (! result) {
3815 builder.setAccessChainRValue(result);
3824 // Leaving the result, when not void:
3825 // GLSL only has r-values as the result of a :?, but
3877 spv::Id result = spv::NoResult; // upcoming result selecting between trueValue and falseValue
3882 // Find a way of executing both sides and selecting the right result.
3898 // see if OpSelect can handle the result type, and that the SPIR-V types
3899 // of the inputs match the result type.
3922 result = builder.createTriOp(spv::OpSelect, resultType, condition, trueValue, falseValue);
3925 builder.setAccessChainRValue(result);
3927 // We need control flow to select the result.
3929 result = builder.createVariable(TranslatePrecisionDecoration(node->getType()),
3940 builder.setAccessChainLValue(result);
3946 builder.setAccessChainLValue(result);
3953 builder.setAccessChainLValue(result);
3961 result = builder.createVariable(TranslatePrecisionDecoration(node->getType()), spv::StorageClassFunction,
3974 if (result != spv::NoResult) {
3978 builder.setAccessChainLValue(result);
3987 if (result != spv::NoResult) {
3991 builder.setAccessChainLValue(result);
3999 if (result != spv::NoResult) {
4001 builder.setAccessChainLValue(result);
4231 spv::Id result = createSpvConstant(*node);
4232 if (result != spv::NoResult)
4233 return result;
5861 spv::Id result = builder.createOp(spv::OpImageRead, resultType(), operands);
5862 builder.setPrecision(result, precision);
5863 return result;
5871 spv::Id result = builder.createOp(spv::OpColorAttachmentReadEXT, resultType(), operands);
5873 builder.setPrecision(result, precision);
5874 return result;
5913 std::vector<spv::Id> result(1, builder.createOp(spv::OpImageRead, resultType(), operands));
5914 builder.setPrecision(result[0], precision);
5918 result[0] = builder.createConstructor(precision, result, convertGlslangToSpvType(node->getType()));
5920 return result[0];
6307 std::vector<spv::Id> result( 1,
6313 result[0] = builder.createConstructor(precision, result, convertGlslangToSpvType(node->getType()));
6315 return result[0];
6400 spv::Id result = builder.createFunctionCall(function, spvArgs);
6401 builder.setPrecision(result, TranslatePrecisionDecoration(node->getType()));
6402 builder.addDecoration(result, TranslateNonUniformDecoration(node->getType().getQualifier()));
6420 return result;
6594 spv::Id result = builder.createBinOp(binOp, typeId, left, right);
6595 decorations.addNoContraction(builder, result);
6596 decorations.addNonUniform(builder, result);
6597 return builder.setPrecision(result, decorations.precision);
6607 spv::Id result = builder.createCompositeCompare(decorations.precision, left, right, op == glslang::EOpEqual);
6608 decorations.addNonUniform(builder, result);
6609 return result;
6668 spv::Id result = builder.createBinOp(binOp, typeId, left, right);
6669 decorations.addNoContraction(builder, result);
6670 decorations.addNonUniform(builder, result);
6671 return builder.setPrecision(result, decorations.precision);
6733 spv::Id result = builder.createBinOp(op, typeId, left, right);
6734 decorations.addNoContraction(builder, result);
6735 decorations.addNonUniform(builder, result);
6736 return builder.setPrecision(result, decorations.precision);
6740 // The result type of all of them is the same type as the (a) matrix operand.
6773 spv::Id result = builder.createBinOp(op, vecType, leftVec, rightVec);
6774 decorations.addNoContraction(builder, result);
6775 decorations.addNonUniform(builder, result);
6776 results.push_back(builder.setPrecision(result, decorations.precision));
6780 spv::Id result = builder.setPrecision(builder.createCompositeConstruct(typeId, results), decorations.precision);
6781 decorations.addNonUniform(builder, result);
6782 return result;
7327 // The result type is the same type as the original type.
7352 spv::Id result = builder.setPrecision(builder.createCompositeConstruct(typeId, results), decorations.precision);
7353 decorations.addNonUniform(builder, result);
7354 return result;
7364 // Get the result type width, based on the type to convert to.
7405 // Get the conversion operation and result type,
7764 spv::Id result = 0;
7766 return result;
7771 result = builder.createTriOp(convOp, destType, operand, one, zero);
7773 result = builder.createUnaryOp(convOp, destType, operand);
7775 result = builder.setPrecision(result, decorations.precision);
7776 decorations.addNonUniform(builder, result);
7777 return result;
8095 // NOTE: According to the spec, the result type of "OpSubgroupBallotKHR" must be a 4 component vector of 32
8099 // result = Bitcast(SubgroupBallotKHR(Predicate).xy)
8103 spv::Id result = builder.createOp(spv::OpSubgroupBallotKHR, uvec4Type, spvGroupOperands);
8106 components.push_back(builder.createCompositeExtract(result, uintType, 0));
8107 components.push_back(builder.createCompositeExtract(result, uintType, 1));
8224 // The result type is the same type as the original type.
9437 spv::Id result = builder.createOp(spv_op, typeId, args);
9438 return builder.setPrecision(result, precision);
9758 spv::Id result;
9764 result = accessChainLoad(sub_tree->getType());
9767 result = createSpvConstantFromConstUnionArray(sn->getType(), *const_union_array, nextConst, true);
9772 builder.addName(result, sn->getName().c_str());
9773 return result;
10033 // || => emit "if (! left) result = right"
10034 // && => emit "if ( left) result = right"
10095 // return 5; // make OpArrayLength result type be an int with signedness of 0