diff options
author | Jakub Jelinek <jakub@redhat.com> | 2023-06-09 09:10:29 +0200 |
---|---|---|
committer | Jakub Jelinek <jakub@redhat.com> | 2023-06-09 09:10:29 +0200 |
commit | 4cf6e322adc19f927859e0a5edfa93cec4b8c844 (patch) | |
tree | 860b02b2999609e72979ef3bab1df79b403e8030 /gcc/tree-vectorizer.h | |
parent | dac73e4c64bf62be18bd5203e4e0f3e6bc64b4dc (diff) | |
download | gcc-4cf6e322adc19f927859e0a5edfa93cec4b8c844.zip gcc-4cf6e322adc19f927859e0a5edfa93cec4b8c844.tar.gz gcc-4cf6e322adc19f927859e0a5edfa93cec4b8c844.tar.bz2 |
fortran: Fix ICE on pr96024.f90 on big-endian hosts [PR96024]
The pr96024.f90 testcase ICEs on big-endian hosts. The problem is
that length->val.integer is accessed after checking
length->expr_type == EXPR_CONSTANT, but it is a CHARACTER constant
which uses length->val.character union member instead and on big-endian
we end up reading constant 0x100000000 rather than some small number
on little-endian and if target doesn't have enough memory for 4 times
that (i.e. 16GB allocation), it ICEs.
2023-06-09 Jakub Jelinek <jakub@redhat.com>
PR fortran/96024
* primary.cc (gfc_convert_to_structure_constructor): Only do
constant string ctor length verification and truncation/padding
if constant length has INTEGER type.
Diffstat (limited to 'gcc/tree-vectorizer.h')
0 files changed, 0 insertions, 0 deletions