Bug report
Johan
j at j.nl
Sun Apr 30 17:18:05 UTC 2023
On Sunday, 30 April 2023 at 16:25:53 UTC, Cecil Ward wrote:
>
> ldc2 internal assert failure during compile:
>
...
>
> alias uint64_256_t = ulong4;
> alias uint64x4_t = uint64_256_t;
> alias uint64_32_t = uint64_256_t;
>
> uint64_t hashv( const uint64_256_t * p, size_t len )
> {
> uint64_256_t s1 = [0, 0, 0, 0];
> for ( size_t i = 0; i < len; i++ )
> {
> const x = p[i];
> s1 ^= (x * 509) ^ (x >>> 9);
This is a known issue:
https://github.com/ldc-developers/ldc/issues/3606
The workaround for now is to manually change the type of the
shift operand to a vector:
`s1 ^= (x * 509) ^ (x >>> uint64_256_t(9));`
-Johan
More information about the digitalmars-d-ldc
mailing list