aboutsummaryrefslogtreecommitdiff
path: root/gcc/errors.h
diff options
context:
space:
mode:
authorMaciej W. Rozycki <macro@linux-mips.org>2020-12-05 18:26:25 +0000
committerMaciej W. Rozycki <macro@linux-mips.org>2020-12-05 18:26:25 +0000
commitb9240a4abcd1e194dbd80460a9a7632e63fb7f49 (patch)
tree325563920c978c0f1be2eec6fcf273c8d6336810 /gcc/errors.h
parent273ffa3a6fef82738dd86522374fae69ab0e2651 (diff)
downloadgcc-b9240a4abcd1e194dbd80460a9a7632e63fb7f49.zip
gcc-b9240a4abcd1e194dbd80460a9a7632e63fb7f49.tar.gz
gcc-b9240a4abcd1e194dbd80460a9a7632e63fb7f49.tar.bz2
VAX: Actually produce QImode and HImode `ctz' operations
The middle end does not refer to `ctzqi2'/`ctzhi2' or `ffsqi2'/`ffshi2' patterns by name where `__builtin_ctz' or `__builtin_ffs' respectively is invoked for an argument of the QImode or HImode type, and instead it extends the data type before passing it to `ctzsi2' or `ffssi2'. Avoid the redundant operation and use a peephole2 to convert it to the right RTL expression that will collapse the two operations into a single machine instruction instead unless we need the extended intermediate result for another purpose. gcc/ * config/vax/builtins.md: Add a peephole2 for QImode and HImode `ctz' operations. (any_extend): New code iterator. gcc/testsuite/ * gcc.target/vax/ctzhi.c: New test. * gcc.target/vax/ctzqi.c: New test. * gcc.target/vax/ffshi.c: New test. * gcc.target/vax/ffsqi.c: New test.
Diffstat (limited to 'gcc/errors.h')
0 files changed, 0 insertions, 0 deletions