comparison gcc/testsuite/gnat.dg/opt83.adb @ 19:2b5abeee2509 default tip

update gcc11
author anatofuz
date Mon, 25 May 2020 07:50:57 +0900
parents
children
comparison
equal deleted inserted replaced
18:1830386684a0 19:2b5abeee2509
1 -- { dg-do compile }
2 -- { dg-options "-O2" }
3
4 -- rpo fre3 used to loop indefinitely replacing _2 with _8 and back,
5 -- given MEM[(struct test__e &)_2][0]{lb: _7 sz: 16}._tag = A23s_29;
6 -- and an earlier _8 = &*_2[0]{lb: _7 sz: 16}.
7
8 procedure Opt83 is
9
10 type E is tagged record
11 I : Natural := 0;
12 end record;
13
14 type A is array (Natural range <>) of aliased E;
15
16 F : E;
17
18 R : access A;
19
20 procedure N is
21 begin
22 if R = null then
23 R := new A (0 .. 4);
24 end if;
25 end N;
26
27 begin
28
29 N;
30
31 R (0) := F;
32
33 end Opt83;