aboutsummaryrefslogtreecommitdiff
path: root/libgo/misc/cgo/stdio/stdio_test.go
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2024-03-05 10:27:14 +0100
committerJakub Jelinek <jakub@redhat.com>2024-03-05 10:27:14 +0100
commit9d2bc5def30830e685ae2e3c2f4d07b967e2be63 (patch)
tree7f083086b754067ead1218d254683fb1df7c725c /libgo/misc/cgo/stdio/stdio_test.go
parent8ee6d13e32279faf9ef4fd8eabfba0adfca0dfb9 (diff)
downloadgcc-9d2bc5def30830e685ae2e3c2f4d07b967e2be63.zip
gcc-9d2bc5def30830e685ae2e3c2f4d07b967e2be63.tar.gz
gcc-9d2bc5def30830e685ae2e3c2f4d07b967e2be63.tar.bz2
bitint: Handle BIT_FIELD_REF lowering [PR114157]
The following patch adds support for BIT_FIELD_REF lowering with large/huge _BitInt lhs. BIT_FIELD_REF requires mode argument first operand, so the operand shouldn't be any huge _BitInt. If we only access limbs from inside of BIT_FIELD_REF using constant indexes, we can just create a new BIT_FIELD_REF to extract the limb, but if we need to use variable index in a loop, I'm afraid we need to spill it into memory, which is what the following patch does. If there is some bitwise type for the extraction, it extracts just what we need and not more than that, otherwise it spills the whole first argument of BIT_FIELD_REF and uses MEM_REF with an offset with VIEW_CONVERT_EXPR around it. 2024-03-05 Jakub Jelinek <jakub@redhat.com> PR middle-end/114157 * gimple-lower-bitint.cc: Include stor-layout.h. (mergeable_op): Return true for BIT_FIELD_REF. (struct bitint_large_huge): Declare handle_bit_field_ref method. (bitint_large_huge::handle_bit_field_ref): New method. (bitint_large_huge::handle_stmt): Use it for BIT_FIELD_REF. * gcc.dg/bitint-98.c: New test. * gcc.target/i386/avx2-pr114157.c: New test. * gcc.target/i386/avx512f-pr114157.c: New test.
Diffstat (limited to 'libgo/misc/cgo/stdio/stdio_test.go')
0 files changed, 0 insertions, 0 deletions