<feed xmlns='http://www.w3.org/2005/Atom'>
<title>slang.git/tests/hlsl-intrinsic/countbits.slang, branch master</title>
<subtitle>Making it easier to work with shaders</subtitle>
<id>https://git.yummers.dev/slang.git/atom?h=master</id>
<link rel='self' href='https://git.yummers.dev/slang.git/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/'/>
<updated>2025-05-16T00:01:08+00:00</updated>
<entry>
<title>Fix broken -emit-spirv-via-glsl test option (#7091)</title>
<updated>2025-05-16T00:01:08+00:00</updated>
<author>
<name>sricker-nvidia</name>
<email>115114531+sricker-nvidia@users.noreply.github.com</email>
</author>
<published>2025-05-16T00:01:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=b39ec87cccaadebbb9325dd2adb8c0b13b364805'/>
<id>urn:sha1:b39ec87cccaadebbb9325dd2adb8c0b13b364805</id>
<content type='text'>
Fixes issue #6898

The -emit-spirv-via-glsl slang-test option has been broken for
some amount of time. Tests that were using it were operating as
if using -emit-spirv-directly, leading to many duplicated tests.

After fixing the test option, there were an number of errors that
appeared as a result.

This change fixes the broken test option and the resulting test
errors. Some of the test errors revealed some legitimate issues,
such as:

-The GLSL bitCount instrinsic only supports 32-bit integers and
 requires emulation for other bit widths.
-Emitting GLSL 8-bit and 16-bit glsl integer types did not emit
 the proper extension requirements
-Emitting GLSL and casting for 16-bit integers was missing a
 closing parenthesis.
-Missing profile for GL_EXT_shader_explicit_arithmetic_types
-Missing toType cases for UInt8/Int8 for the kIROp_BitCast case
 in tryEmitInstExprImpl.</content>
</entry>
<entry>
<title>Add countbits 16-bit and 8-bit support (#6433) (#6897)</title>
<updated>2025-05-05T22:30:33+00:00</updated>
<author>
<name>sricker-nvidia</name>
<email>115114531+sricker-nvidia@users.noreply.github.com</email>
</author>
<published>2025-05-05T22:30:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=50d9781b7387b0f7f56d19c72afcf390cca72b72'/>
<id>urn:sha1:50d9781b7387b0f7f56d19c72afcf390cca72b72</id>
<content type='text'>
Change adds 16-bit and 8-bit support for countbits intrinsic. In
cases where a backend's native counbits lacks support, support
is emulated.

New tests are added for 16-bit and 8-bit support. Additional testing
added for 32-bit and minor updates made to 64-bit countbits.</content>
</entry>
<entry>
<title>Extend `countbits` intrinsic for vector types (#4499)</title>
<updated>2024-06-27T23:09:33+00:00</updated>
<author>
<name>venkataram-nv</name>
<email>vedavamadath@nvidia.com</email>
</author>
<published>2024-06-27T23:09:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=f5acb6b987609cc6c1d859120cd327c57c344803'/>
<id>urn:sha1:f5acb6b987609cc6c1d859120cd327c57c344803</id>
<content type='text'>
* Extend `countbits` intrinsic for vector types

This commit implements the overloading function for `countbits` function.
Because HLSL has following overloadings,
```
uint count_bits(uint value);
uint2 count_bits(uint2 value);
uint3 count_bits(uint3 value);
uint4 count_bits(uint4 value);
```
https://learn.microsoft.com/en-us/windows/win32/direct3dhlsl/countbits
</content>
</entry>
</feed>
