]> gcc.gnu.org Git - gcc.git/commit
Handle const_int in expand_single_bit_test
authorAndrew Pinski <apinski@marvell.com>
Mon, 5 Jun 2023 02:42:08 +0000 (19:42 -0700)
committerAndrew Pinski <apinski@marvell.com>
Wed, 7 Jun 2023 03:02:49 +0000 (20:02 -0700)
commit3f085e45755643f13d4fa45a12a6ade45be98f95
treec4130544f10cbca73d79e796b2aa0dc6ae5c9ed9
parente60593f3881c72a96a3fa4844d73e8a2cd14f670
Handle const_int in expand_single_bit_test

After expanding directly to rtl instead of
creating a tree, we could end up with
a const_int which is not ready to be handled
by extract_bit_field.
So need to the constant folding here instead.

OK? bootstrapped and tested on x86_64-linux-gnu with no regressions.

PR middle-end/110117

gcc/ChangeLog:

* expr.cc (expand_single_bit_test): Handle
const_int from expand_expr.

gcc/testsuite/ChangeLog:

* gcc.dg/pr110117-1.c: New test.
* gcc.dg/pr110117-2.c: New test.
gcc/expr.cc
gcc/testsuite/gcc.dg/pr110117-1.c [new file with mode: 0644]
gcc/testsuite/gcc.dg/pr110117-2.c [new file with mode: 0644]
This page took 0.066059 seconds and 6 git commands to generate.