Home
last modified time | relevance | path

Searched refs:deFloat16 (Results 1 – 25 of 51) sorted by relevance

123

/third_party/vk-gl-cts/framework/delibs/debase/
DdeFloat16.c28 deFloat16 deFloat32To16 (float val32) in deFloat32To16()
49 return (deFloat16) sign; in deFloat32To16()
64 return (deFloat16) (sign | mantissa); in deFloat32To16()
71 return (deFloat16) (sign | 0x7c00u); in deFloat32To16()
77 return (deFloat16) (sign | 0x7c00u | mantissa | (mantissa == 0u)); in deFloat32To16()
95 return (deFloat16) (sign | 0x7c00u); in deFloat32To16()
98 return (deFloat16) (sign | ((deUint32)expotent << 10u) | (mantissa >> 13u)); in deFloat32To16()
102 deFloat16 deFloat64To16 (double val64) in deFloat64To16()
123 return (deFloat16) sign; in deFloat64To16()
138 return (deFloat16) (sign | mantissa); in deFloat64To16()
[all …]
DdeFloat16.h31 typedef deUint16 deFloat16; typedef
34 typedef deFloat16 DEfloat16;
42 deFloat16 deFloat32To16 (float val32);
43 deFloat16 deFloat32To16Round (float val32, deRoundingMode mode);
46 deFloat16 deFloat64To16 (double val64);
47 deFloat16 deFloat64To16Round (double val64, deRoundingMode mode);
54 float deFloat16To32 (deFloat16 val16);
61 double deFloat16To64 (deFloat16 val16);
63 DE_INLINE deBool deHalfIsPositiveZero(deFloat16 x) in deHalfIsPositiveZero()
68 DE_INLINE deBool deHalfIsNegativeZero(deFloat16 x) in deHalfIsNegativeZero()
[all …]
DCMakeLists.txt10 deFloat16.c
11 deFloat16.h
DdeFloat16Test.c42 static deFloat16 getFloat16 (deUint16 sign, deUint16 biased_exponent, deUint16 mantissa) in getFloat16()
44 return (deFloat16) ((sign << 15) | (biased_exponent << 10) | mantissa); in getFloat16()
48 static deFloat16 deFloat32To16RTZ (float val32) in deFloat32To16RTZ()
53 static deFloat16 deFloat32To16RTE (float val32) in deFloat32To16RTE()
DBUILD.gn34 "//third_party/vk-gl-cts/framework/delibs/debase/deFloat16.c",
/third_party/vk-gl-cts/framework/delibs/decpp/
DdeMath.hpp31 DE_INLINE double deToDouble (deFloat16 x) { return deFloat16To64(x); } in deToDouble()
42 inline deFloat16 deToFloatType<deFloat16>(double x) in deToFloatType()
50 DE_INLINE deBool deIsPositiveZero (deFloat16 x) { return deHalfIsPositiveZero(x); } in deIsPositiveZero()
53 DE_INLINE deBool deIsNegativeZero (deFloat16 x) { return deHalfIsNegativeZero(x); } in deIsNegativeZero()
56 DE_INLINE deBool deIsIEEENaN (deFloat16 x) { return deHalfIsIEEENaN(x); } in deIsIEEENaN()
59 DE_INLINE deBool deIsSignalingNaN (deFloat16 x) { return deHalfIsSignalingNaN(x); } in deIsSignalingNaN()
62 DE_INLINE deBool deIsQuietNaN (deFloat16 x) { return deHalfIsQuietNaN(x); } in deIsQuietNaN()
73 inline deFloat16 deQuietNaN<deFloat16>() in deQuietNaN()
85 inline deFloat16 deSignalingNaN<deFloat16>() in deSignalingNaN()
/third_party/vk-gl-cts/external/vulkancts/modules_no_buildgn/vulkan/shaderexecutor/
DvktShaderBuiltinPrecisionTests.cpp79 typedef Vector<deFloat16, 1> Vec1_16Bit;
80 typedef Vector<deFloat16, 2> Vec2_16Bit;
81 typedef Vector<deFloat16, 3> Vec3_16Bit;
82 typedef Vector<deFloat16, 4> Vec4_16Bit;
580 float res0 = deFloat16To32((deFloat16)(iRep & 0xFFFF)); in doPrintValue16()
581 float res1 = deFloat16To32((deFloat16)(iRep >> 16)); in doPrintValue16()
607 float res0 = deFloat16To32((deFloat16)(iRep & 0xFFFF)); in doContains()
608 float res1 = deFloat16To32((deFloat16)(iRep >> 16)); in doContains()
630 double byte0 = deFloat16To64((deFloat16)((iRep ) & 0xffff)); in doPrintValue16()
631 double byte1 = deFloat16To64((deFloat16)((iRep >> 16) & 0xffff)); in doPrintValue16()
[all …]
/third_party/vk-gl-cts/external/vulkancts/modules/vulkan/shaderexecutor/
DvktShaderBuiltinPrecisionTests.cpp79 typedef Vector<deFloat16, 1> Vec1_16Bit;
80 typedef Vector<deFloat16, 2> Vec2_16Bit;
81 typedef Vector<deFloat16, 3> Vec3_16Bit;
82 typedef Vector<deFloat16, 4> Vec4_16Bit;
580 float res0 = deFloat16To32((deFloat16)(iRep & 0xFFFF)); in doPrintValue16()
581 float res1 = deFloat16To32((deFloat16)(iRep >> 16)); in doPrintValue16()
607 float res0 = deFloat16To32((deFloat16)(iRep & 0xFFFF)); in doContains()
608 float res1 = deFloat16To32((deFloat16)(iRep >> 16)); in doContains()
630 double byte0 = deFloat16To64((deFloat16)((iRep ) & 0xffff)); in doPrintValue16()
631 double byte1 = deFloat16To64((deFloat16)((iRep >> 16) & 0xffff)); in doPrintValue16()
[all …]
/third_party/vk-gl-cts/external/vulkancts/modules_no_buildgn/vulkan/spirv_assembly/
DvktSpvAsmInstructionTests.cpp7181 const vector<deFloat16> squarize(const vector<deFloat16>& inData, const deUint32 argNo) in squarize()
7184 vector<deFloat16> result; in squarize()
7198 const vector<deFloat16> tmp(inDataLength, inData[numIdx]); in squarize()
7207 const vector<deFloat16> squarizeVector(const vector<deFloat16>& inData, const deUint32 argNo) in squarizeVector()
7209 vector<deFloat16> vec; in squarizeVector()
7210 vector<deFloat16> result; in squarizeVector()
7281 const deFloat16 float16one = tcu::Float16(1.0f).bits(); in compareFP16Logical()
7282 const deFloat16 float16zero = tcu::Float16(0.0f).bits(); in compareFP16Logical()
7284 const deFloat16* const outputAsFP16 = static_cast<deFloat16*>(outputAllocs[0]->getHostPtr()); in compareFP16Logical()
7285 const deFloat16* const input1AsFP16 = reinterpret_cast<deFloat16* const>(&input1Bytes.front()); in compareFP16Logical()
[all …]
DvktSpvAsm16bitStorageTests.cpp386 vector<deFloat16> data16bitStd140 (de::Random& rnd) in data16bitStd140()
465 vector<deFloat16> data16bitStd430 (de::Random& rnd) in data16bitStd430()
1291 vector<deFloat16> float16Data = getFloat16s(rnd, numElements * inputStride); in addCompute16bitStorageUniform16To32Group()
1499 vector<deFloat16> inputDataFloat = getFloat16s(rnd, structSize * 4); in addCompute16bitStorageUniform16To32ChainAccessGroup()
1802 vector<deFloat16> float16Data = getFloat16s(rnd, numElements); in addCompute16bitStoragePushConstant16To32Group()
2238 const vector<deFloat16> float16Data = getFloat16s(rnd, numElements); in addCompute16bitStorageUniform16To16Group()
2239 const vector<deFloat16> float16UnusedData (numElements, 0); in addCompute16bitStorageUniform16To16Group()
2441 vector<deFloat16> float16UnusedData (numElements, 0); in addCompute16bitStorageUniform32To16Group()
2785 …vector<deFloat16> float16DData = (VK_DESCRIPTOR_TYPE_STORAGE_BUFFER == CAPABILITIES[capIdx].dtype… in addCompute16bitStorageUniform16StructTo32StructGroup()
2798 …TYPE_STORAGE_BUFFER == CAPABILITIES[capIdx].dtype) ? computeCheckStruct<deFloat16, float, SHADERTE… in addCompute16bitStorageUniform16StructTo32StructGroup()
[all …]
DvktSpvAsmGraphicsShaderTestUtil.cpp2714 bool compare16BitFloat (deFloat16 original, deFloat16 returned, std::string& error) in compare16BitFloat()
4516 …const deFloat16* actual = static_cast<const deFloat16*>(fragOutputBufferAccess.getPixelPtr(x, y)); in runAndVerifyDefaultPipeline()
4526 …const deFloat16* original = static_cast<const deFloat16*>(inputData) + posNdx * outputType.numElem… in runAndVerifyDefaultPipeline()
4527 …const deFloat16* actual = static_cast<const deFloat16*>(fragOutputBufferAccess.getPixelPtr(x, y)); in runAndVerifyDefaultPipeline()
4536 …const deFloat16* actual = static_cast<const deFloat16*>(fragOutputBufferAccess.getPixelPtr(x, y)); in runAndVerifyDefaultPipeline()
DvktSpvAsmUtils.hpp327 std::vector<deFloat16> getFloat16s (de::Random& rnd, deUint32 count);
DvktSpvAsmWorkgroupMemoryTests.cpp341 vector<deFloat16> inputData = getFloat16s(rnd, numElements); in addComputeWorkgroupMemoryTests()
342 vector<deFloat16> outputData; in addComputeWorkgroupMemoryTests()
DvktSpvAsmGraphicsShaderTestUtil.hpp635 bool compare16BitFloat (deFloat16 original, deFloat16 returned, std::string& error);
DvktSpvAsmFloatControlsTests.cpp458 TypeValues<deFloat16>::TypeValues() in TypeValues()
927 TypeSnippets<deFloat16>::TypeSnippets() in TypeSnippets()
1059 TypeTestResults<deFloat16>::TypeTestResults() in TypeTestResults()
2542 template<> double getFloatTypeAsDouble(deFloat16 param) in getFloatTypeAsDouble()
2782 { BufferDataType::DATA_FP16, compareBytes<Float16, deFloat16> }, in checkMixedFloats()
2897 m_typeData[FP16].values = TypeValuesSP(new TypeValues<deFloat16>); in TestGroupBuilderBase()
2898 m_typeData[FP16].snippets = TypeSnippetsSP(new TypeSnippets<deFloat16>); in TestGroupBuilderBase()
2899 m_typeData[FP16].testResults = TypeTestResultsSP(new TypeTestResults<deFloat16>); in TestGroupBuilderBase()
3459 checkFloats<Float16, deFloat16>, in fillShaderSpec()
3752 …inputData ((fp64Required * sizeof(double) + sizeof(float) + fp16Required * sizeof(deFloat16)) * 2); in fillShaderSpec()
[all …]
/third_party/vk-gl-cts/external/vulkancts/modules/vulkan/spirv_assembly/
DvktSpvAsmInstructionTests.cpp7181 const vector<deFloat16> squarize(const vector<deFloat16>& inData, const deUint32 argNo) in squarize()
7184 vector<deFloat16> result; in squarize()
7198 const vector<deFloat16> tmp(inDataLength, inData[numIdx]); in squarize()
7207 const vector<deFloat16> squarizeVector(const vector<deFloat16>& inData, const deUint32 argNo) in squarizeVector()
7209 vector<deFloat16> vec; in squarizeVector()
7210 vector<deFloat16> result; in squarizeVector()
7281 const deFloat16 float16one = tcu::Float16(1.0f).bits(); in compareFP16Logical()
7282 const deFloat16 float16zero = tcu::Float16(0.0f).bits(); in compareFP16Logical()
7284 const deFloat16* const outputAsFP16 = static_cast<deFloat16*>(outputAllocs[0]->getHostPtr()); in compareFP16Logical()
7285 const deFloat16* const input1AsFP16 = reinterpret_cast<deFloat16* const>(&input1Bytes.front()); in compareFP16Logical()
[all …]
DvktSpvAsm16bitStorageTests.cpp386 vector<deFloat16> data16bitStd140 (de::Random& rnd) in data16bitStd140()
465 vector<deFloat16> data16bitStd430 (de::Random& rnd) in data16bitStd430()
1291 vector<deFloat16> float16Data = getFloat16s(rnd, numElements * inputStride); in addCompute16bitStorageUniform16To32Group()
1499 vector<deFloat16> inputDataFloat = getFloat16s(rnd, structSize * 4); in addCompute16bitStorageUniform16To32ChainAccessGroup()
1802 vector<deFloat16> float16Data = getFloat16s(rnd, numElements); in addCompute16bitStoragePushConstant16To32Group()
2238 const vector<deFloat16> float16Data = getFloat16s(rnd, numElements); in addCompute16bitStorageUniform16To16Group()
2239 const vector<deFloat16> float16UnusedData (numElements, 0); in addCompute16bitStorageUniform16To16Group()
2441 vector<deFloat16> float16UnusedData (numElements, 0); in addCompute16bitStorageUniform32To16Group()
2785 …vector<deFloat16> float16DData = (VK_DESCRIPTOR_TYPE_STORAGE_BUFFER == CAPABILITIES[capIdx].dtype… in addCompute16bitStorageUniform16StructTo32StructGroup()
2798 …TYPE_STORAGE_BUFFER == CAPABILITIES[capIdx].dtype) ? computeCheckStruct<deFloat16, float, SHADERTE… in addCompute16bitStorageUniform16StructTo32StructGroup()
[all …]
DvktSpvAsmGraphicsShaderTestUtil.cpp2714 bool compare16BitFloat (deFloat16 original, deFloat16 returned, std::string& error) in compare16BitFloat()
4516 …const deFloat16* actual = static_cast<const deFloat16*>(fragOutputBufferAccess.getPixelPtr(x, y)); in runAndVerifyDefaultPipeline()
4526 …const deFloat16* original = static_cast<const deFloat16*>(inputData) + posNdx * outputType.numElem… in runAndVerifyDefaultPipeline()
4527 …const deFloat16* actual = static_cast<const deFloat16*>(fragOutputBufferAccess.getPixelPtr(x, y)); in runAndVerifyDefaultPipeline()
4536 …const deFloat16* actual = static_cast<const deFloat16*>(fragOutputBufferAccess.getPixelPtr(x, y)); in runAndVerifyDefaultPipeline()
DvktSpvAsmUtils.hpp327 std::vector<deFloat16> getFloat16s (de::Random& rnd, deUint32 count);
DvktSpvAsmWorkgroupMemoryTests.cpp341 vector<deFloat16> inputData = getFloat16s(rnd, numElements); in addComputeWorkgroupMemoryTests()
342 vector<deFloat16> outputData; in addComputeWorkgroupMemoryTests()
DvktSpvAsmGraphicsShaderTestUtil.hpp635 bool compare16BitFloat (deFloat16 original, deFloat16 returned, std::string& error);
DvktSpvAsmFloatControlsTests.cpp458 TypeValues<deFloat16>::TypeValues() in TypeValues()
927 TypeSnippets<deFloat16>::TypeSnippets() in TypeSnippets()
1059 TypeTestResults<deFloat16>::TypeTestResults() in TypeTestResults()
2542 template<> double getFloatTypeAsDouble(deFloat16 param) in getFloatTypeAsDouble()
2782 { BufferDataType::DATA_FP16, compareBytes<Float16, deFloat16> }, in checkMixedFloats()
2897 m_typeData[FP16].values = TypeValuesSP(new TypeValues<deFloat16>); in TestGroupBuilderBase()
2898 m_typeData[FP16].snippets = TypeSnippetsSP(new TypeSnippets<deFloat16>); in TestGroupBuilderBase()
2899 m_typeData[FP16].testResults = TypeTestResultsSP(new TypeTestResults<deFloat16>); in TestGroupBuilderBase()
3459 checkFloats<Float16, deFloat16>, in fillShaderSpec()
3752 …inputData ((fp64Required * sizeof(double) + sizeof(float) + fp16Required * sizeof(deFloat16)) * 2); in fillShaderSpec()
[all …]
DvktSpvAsmUtils.cpp655 std::vector<deFloat16> getFloat16s (de::Random& rnd, deUint32 count) in getFloat16s()
657 std::vector<deFloat16> float16; in getFloat16s()
/third_party/vk-gl-cts/modules/glshared/
DglsVertexArrayTests.hpp323 inline deFloat16 getValue (void) const { return m_value; } in getValue()
346 inline static deFloat16 floatToHalf (float f);
347 inline static float halfToFloat (deFloat16 h);
349 deFloat16 m_value;
493 inline deFloat16 GLValue::Half::floatToHalf (float f) in floatToHalf()
501 inline float GLValue::Half::halfToFloat (deFloat16 h) in halfToFloat()
/third_party/vk-gl-cts/framework/common/
DtcuAstcUtil.cpp98 inline bool isFloat16InfOrNan (deFloat16 v) in isFloat16InfOrNan()
522 if (isFloat16InfOrNan((deFloat16)rgba[c])) in decodeVoidExtentBlock()
528 dstF[i*4 + c] = deFloat16To32((deFloat16)rgba[c]); in decodeVoidExtentBlock()
1465 DE_STATIC_ASSERT((de::meta::TypesSame<deFloat16, deUint16>::Value)); in setTexelColors()
1475 const deFloat16 cf = (deFloat16)((e << 10) + (mt >> 3)); in setTexelColors()
1736 DE_STATIC_ASSERT((de::meta::TypesSame<deFloat16, deUint16>::Value));
2470 …const deFloat16 r = deFloat32To16(minValue + (float)rNdx * (maxValue - minValue) / (float)(numBl… in generateBlockCaseTestData()
2471 …const deFloat16 g = deFloat32To16(minValue + (float)gNdx * (maxValue - minValue) / (float)(numBl… in generateBlockCaseTestData()
2472 …const deFloat16 b = deFloat32To16(minValue + (float)bNdx * (maxValue - minValue) / (float)(numBl… in generateBlockCaseTestData()
2473 …const deFloat16 a = deFloat32To16(minValue + (float)aNdx * (maxValue - minValue) / (float)(numBl… in generateBlockCaseTestData()

123