dawn-cmake/test/tint/builtins/gen
Antonio Maiorano ab4c035762 tint: fix HLSL countOneBits and reverseBits for i32 args
These two functions in HLSL only accept and return uint. Thus, if the
result of these calls is passed to a function that wants int, it will
fail, or call the uint overload if one exists. Fixed by casting the
result to int if the arg is int.

Bug: tint:1550
Change-Id: Id4c0970a29ac4c83ee5b78be8d2762e05e4a3f03
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/91001
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: Antonio Maiorano <amaiorano@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
2022-05-20 01:58:40 +00:00
..
abs tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
acos tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
all tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
any tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
arrayLength tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
asin tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
atan tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
atan2 tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
atomicAdd tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
atomicAnd tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
atomicCompareExchangeWeak tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
atomicExchange tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
atomicLoad tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
atomicMax tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
atomicMin tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
atomicOr tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
atomicStore tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
atomicSub tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
atomicXor tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
ceil tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
clamp tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
cos tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
cosh tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
countLeadingZeros tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
countOneBits tint: fix HLSL countOneBits and reverseBits for i32 args 2022-05-20 01:58:40 +00:00
countTrailingZeros tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
cross tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
degrees tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
determinant tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
distance tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
dot tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
dpdx tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
dpdxCoarse tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
dpdxFine tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
dpdy tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
dpdyCoarse tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
dpdyFine tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
exp tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
exp2 tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
extractBits tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
faceForward tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
firstLeadingBit tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
firstTrailingBit tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
floor tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
fma tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
fract tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
frexp tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
fwidth tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
fwidthCoarse tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
fwidthFine tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
insertBits tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
inverseSqrt tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
ldexp tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
length tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
log tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
log2 tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
max tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
min tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
mix tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
modf tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
normalize tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
pack2x16float tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
pack2x16snorm tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
pack2x16unorm tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
pack4x8snorm tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
pack4x8unorm tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
pow tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
radians tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
reflect tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
refract tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
reverseBits tint: fix HLSL countOneBits and reverseBits for i32 args 2022-05-20 01:58:40 +00:00
round tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
select tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
sign tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
sin tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
sinh tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
smoothstep tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
sqrt tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
step tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
storageBarrier tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
tan tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
tanh tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
textureDimensions tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
textureGather tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
textureGatherCompare tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
textureLoad tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
textureNumLayers tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
textureNumLevels tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
textureNumSamples tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
textureSample tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
textureSampleBias tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
textureSampleCompare tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
textureSampleCompareLevel tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
textureSampleGrad tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
textureSampleLevel tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
textureStore tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
transpose tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
trunc tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
unpack2x16float tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
unpack2x16snorm tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
unpack2x16unorm tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
unpack4x8snorm tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
unpack4x8unorm tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00
workgroupBarrier tint: Rename and move builtin_table and builtin-gen 2022-05-06 15:13:01 +00:00