https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101667
Bug ID: 101667
Summary: GNAT bug detected in op1_range in range-op.cc during
GIMPLE pass evrp
Product: gcc
Version: 11.1.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: ada
Assignee: unassigned at gcc dot gnu.org
Reporter: denkpadje at gmail dot com
Target Milestone: ---
Created attachment 51220
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=51220&action=edit
src/ folder and Makefile
GNAT bug detected in provided code (see zip file) when tree-vrp is enabled.
Following options are needed to reproduce it: -gnatVa -gnata -O1 -ftree-vrp.
The error can be avoided by using -fno-tree-vrp or -O0 or by removing -gnatVa
or -gnata.
Reproducable in 11.1.0 on Arch Linux
Not reproducable in 10.3.0 and 9.3.0 on Ubuntu 20.04.2 LTS
```
gnatmake -gnatVa -gnata -O1 -ftree-vrp src/egl-objects-displays.adb
gcc -c -Isrc/ -gnatVa -gnata -O1 -ftree-vrp -I- src/egl-objects-displays.adb
during GIMPLE pass: evrp
+===========================GNAT BUG DETECTED==============================+
| 11.1.0 (x86_64-pc-linux-gnu) in op1_range, at range-op.cc:2646 |
| Error detected around
/usr/lib/gcc/x86_64-pc-linux-gnu/11.1.0/adainclude/s-stoele.adb:70:31|
| Please submit a bug report; see https://gcc.gnu.org/bugs/ . |
| Use a subject line meaningful to you and us to track the bug. |
| Include the entire contents of this bug box in the report. |
| Include the exact command that you entered. |
| Also include sources listed below. |
+==========================================================================+
Please include these source files with error report
Note that list may not be accurate in some cases,
so please double check that the problem can still
be reproduced with the set of files listed.
Consider also -gnatd.n switch (see debug.adb).
src/egl-objects-displays.adb
src/egl-objects-displays.ads
src/egl-objects.ads
src/egl.ads
src/egl-objects-devices.ads
src/egl-api.ads
src/egl-errors.ads
src/egl-loading.ads
raised TYPES.UNRECOVERABLE_ERROR : comperr.adb:407
```