Wrong vector shift results on PowerPC #109777
Labels
module: POWER
Issues specific to the POWER/ppc architecture
module: vectorization
Related to SIMD vectorization, e.g., Vec256
triaged
This issue has been looked at a team member, and triaged and prioritized into an appropriate module
馃悰 Describe the bug
This is basically #70904 which is still present for PPC after #98511 added vector operations.
Basically: Shifting a vector with out-of-bounds values results in undefined behavior and sporadic wrong results.
E.g. test_non_contig_bitwise_right_shift_cpu_int32 fails because of right shifts with too-large values and test_shift_limits_cpu_int16 fails due to left shifts with negative values. The latter is very much understandable given that #98511 uses a
reinterpret_cast
to the unsigned vector typeReproduced with
python run_test.py -i test_binary_ufuncs
which failsVersions
Using PyTorch 2.0.1 with the above PRs applied as patches.
The text was updated successfully, but these errors were encountered: