aboutsummaryrefslogtreecommitdiff
path: root/gcc/config/frv
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2022-10-21 18:34:37 +0200
committerJakub Jelinek <jakub@redhat.com>2022-10-21 18:34:37 +0200
commit5792208f5124f687376f25798668d105d7ddb270 (patch)
tree6ed073bd73add054a0a4d55fc383ad20b6f17188 /gcc/config/frv
parent2cc41601d9a948e8d612a21c3b9a44ce0b977747 (diff)
downloadgcc-5792208f5124f687376f25798668d105d7ddb270.zip
gcc-5792208f5124f687376f25798668d105d7ddb270.tar.gz
gcc-5792208f5124f687376f25798668d105d7ddb270.tar.bz2
i386: Fix up BFmode comparisons in conditional moves [PR107322]
As the testcase shows, when cbranchbf4/cstorebf4 patterns are defined, we can get ICEs for conditional moves. The problem is that the generic conditional move expansion just calls prepare_cmp_insn which just checks that such a cbranch<mode>4 exists and returns directly such comparison and passes it down to the conditional move optabs. The following patch fixes it by punting if the comparisons aren't ix86_fp_comparison_operator (to tell the generic code it should separately compare) and to handle the promotion of BFmode comparison operands to SFmode such that comparison is performed in SFmode. 2022-10-21 Jakub Jelinek <jakub@redhat.com> PR target/107322 * config/i386/i386-expand.cc (ix86_prepare_fp_compare_args): For BFmode comparisons promote arguments to SFmode and recurse. (ix86_expand_int_movcc, ix86_expand_fp_movcc): Return false early if comparison operands are BFmode and operands[1] is not ix86_fp_comparison_operator. * gcc.target/i386/pr107322.c: New test.
Diffstat (limited to 'gcc/config/frv')
0 files changed, 0 insertions, 0 deletions