diff options
author | Victor Do Nascimento <victor.donascimento@arm.com> | 2024-07-05 15:18:32 +0100 |
---|---|---|
committer | Victor Do Nascimento <victor.donascimento@arm.com> | 2024-09-30 15:59:43 +0100 |
commit | 8398ef96cc503cffb1447c5b02741e24423ec120 (patch) | |
tree | 9d208c944a8ed582e229a25c9804925b036e496e /libgo/go/net/cgo_netbsd.go | |
parent | fd35d99914051c9c58b91b167f4802c8db460038 (diff) | |
download | gcc-master.zip gcc-master.tar.gz gcc-master.tar.bz2 |
Given the novel treatment of the dot product optab as a conversion, we
are now able to target different relationships between output modes and
input modes.
This is made clearer by way of example. Previously, on AArch64, the
following loop was vectorizable:
uint32_t udot4(int n, uint8_t* data) {
uint32_t sum = 0;
for (int i=0; i<n; i+=1)
sum += data[i] * data[i];
return sum;
}
while the following was not:
uint32_t udot2(int n, uint16_t* data) {
uint32_t sum = 0;
for (int i=0; i<n; i+=1)
sum += data[i] * data[i];
return sum;
}
Under the new treatment of the dot product optab, they are both now
vectorizable.
This adds the relevant target-agnostic check to ensure this behavior
in the autovectorizer, gated behind the new check_effective_target
`vect_dotprod_hisi' as well a runtime check targeting aarch64.
gcc/testsuite/ChangeLog:
* lib/target-supports.exp (check_effective_target_vect_dotprod_hisi):
New.
* gcc.dg/vect/vect-dotprod-conv-optab.c: Likewise.
* gcc.target/aarch64/vect-dotprod-twoway-hisi.c: Likewise.
Diffstat (limited to 'libgo/go/net/cgo_netbsd.go')
0 files changed, 0 insertions, 0 deletions