From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 9A1893858400; Wed, 22 Sep 2021 13:47:40 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 9A1893858400 From: "dave.anglin at bell dot net" To: gcc-bugs@gcc.gnu.org Subject: [Bug ada/102450] GCC error: in set_min_and_max_values_for_integral_type, at stor-layout.c:2851 Date: Wed, 22 Sep 2021 13:47:40 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: ada X-Bugzilla-Version: 12.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: dave.anglin at bell dot net X-Bugzilla-Status: WAITING X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 22 Sep 2021 13:47:40 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D102450 --- Comment #2 from dave.anglin at bell dot net --- On 2021-09-22 9:14 a.m., rguenth at gcc dot gnu.org wrote: > what's MAX_BITSIZE_MODE_ANY_INT in insn-modes.h? (in the build directory) > I think it should correspond to TImode and thus be 16 * BITS_PER_UNIT whi= ch > means that we're building an INTEGER_TYPE bigger than TImode - can you co= nfirm > that? #define BITS_PER_UNIT (8) #define MAX_BITSIZE_MODE_ANY_INT (16*BITS_PER_UNIT) #define MAX_BITSIZE_MODE_ANY_MODE (32*BITS_PER_UNIT) However, TImode is not supported on this target. (gdb) ignor 1 325 Will ignore next 325 crossings of breakpoint 1. (gdb) r Starting program: /home/dave/gnu/gcc/objdir/gcc/gnat1 -quiet -nostdinc -O2 -Wext=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0 ra -Wall -dumpbase s-regpat.adb -dumpbase-ext .adb -gnatwa -fchecking=3D1 -g -fPIC=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0 -gnatpg -gnatO s-regpat.o s-regpat.adb -o s-regpat.s Breakpoint 1, _Z40set_min_and_max_values_for_integral_typeP9tree_nodei6sign= op =C2=A0=C2=A0=C2=A0 (type=3D, precision=3D256, sgn=3DUNSIGN= ED) =C2=A0=C2=A0=C2=A0 at ../../gcc/gcc/stor-layout.c:2851 2851=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 gcc_assert (precision <=3D WIDE_INT_MAX_= PRECISION); (gdb) p precision $2 =3D 256 (gdb) disass $pc-16,$pc+16 Dump of assembler code from 0xfbc244 to 0xfbc264: =C2=A0=C2=A0 0x00fbc244 <_Z40set_min_and_max_values_for_integral_typeP9tree_nodei6signop+36>:=C2=A0= =C2=A0=C2=A0=C2=A0 stw r7,-70(sp) =C2=A0=C2=A0 0x00fbc248 <_Z40set_min_and_max_values_for_integral_typeP9tree_nodei6signop+40>:=C2=A0= =C2=A0=C2=A0=C2=A0 stw r6,-6c(sp) =C2=A0=C2=A0 0x00fbc24c <_Z40set_min_and_max_values_for_integral_typeP9tree_nodei6signop+44>:=C2=A0= =C2=A0=C2=A0=C2=A0 cmpib,>=3D 0,r25,0xfbc2d4 <_Z40set_min_and_max_values_for_integral_typeP9tree_nodei6signop+180> =C2=A0=C2=A0 0x00fbc250 <_Z40set_min_and_max_values_for_integral_typeP9tree_nodei6signop+48>:=C2=A0= =C2=A0=C2=A0=C2=A0 copy r26,r3 =3D> 0x00fbc254 <_Z40set_min_and_max_values_for_integral_typeP9tree_nodei6signop+52>:=C2=A0= =C2=A0=C2=A0=C2=A0 ldi c0,ret0 =C2=A0=C2=A0 0x00fbc258 <_Z40set_min_and_max_values_for_integral_typeP9tree_nodei6signop+56>:=C2=A0= =C2=A0=C2=A0=C2=A0 cmpb,< ret0,r25,0xfbc2fc <_Z40set_min_and_max_values_for_integral_typeP9tree_nodei6signop+220> =C2=A0=C2=A0 0x00fbc25c <_Z40set_min_and_max_values_for_integral_typeP9tree_nodei6signop+60>:=C2=A0= =C2=A0=C2=A0=C2=A0 copy r24,r25 =C2=A0=C2=A0 0x00fbc260 <_Z40set_min_and_max_values_for_integral_typeP9tree_nodei6signop+64>:=C2=A0= =C2=A0=C2=A0=C2=A0 ldo -98(sp),r6 End of assembler dump. (gdb) p $ret0 $3 =3D 8388608 (gdb) p 0xc0 $4 =3D 192 (gdb) p $r25 $5 =3D 256 (gdb) bt #0=C2=A0 _Z40set_min_and_max_values_for_integral_typeP9tree_nodei6signop ( =C2=A0=C2=A0=C2=A0 type=3D, precision=3D256, sgn=3DUNSIGNE= D) =C2=A0=C2=A0=C2=A0 at ../../gcc/gcc/stor-layout.c:2851 #1=C2=A0 0x00fc0b9c in _Z18make_unsigned_typei (precision=3D256) =C2=A0=C2=A0=C2=A0 at ../../gcc/gcc/stor-layout.c:2885 #2=C2=A0 0x000da2b4 in _Z18gnat_type_for_sizeji (precision=3D256, unsignedp= =3D256) =C2=A0=C2=A0=C2=A0 at ../../gcc/gcc/ada/gcc-interface/utils.c:3670 #3=C2=A0 0x00b05c2c in gimple_fold_builtin_memory_op(gimple_stmt_iterator*, tree_node*, tree_node*, built_in_function) (v=3D@0x79aebb68, reserve=3D256, exact=3Dtrue) =C2=A0=C2=A0=C2=A0 at ../../gcc/gcc/gimple-fold.c:1004 #4=C2=A0 0x00afffac in _ZL11fold_stmt_1P20gimple_stmt_iteratorbPFP9tree_nod= eS2_E ( =C2=A0=C2=A0=C2=A0 gsi=3D0x7a001018, inplace=3Dtrue, valueize=3D0x79ae8b58) =C2=A0=C2=A0=C2=A0 at ../../gcc/gcc/gimple-fold.c:5054 #5=C2=A0 0x00b13668 in _ZL10lower_stmtP20gimple_stmt_iteratorP10lower_data ( =C2=A0=C2=A0=C2=A0 gsi=3D..., data=3D0x7a000fa4) at ../../gcc/gcc/gimple-lo= w.c:390 #6=C2=A0 0x00b1405c in _ZL17lower_gimple_bindP20gimple_stmt_iteratorP10lowe= r_data ( =C2=A0=C2=A0=C2=A0 gsi=3D0x7a000f98, data=3D0x7a000fa4) at ../../gcc/gcc/gi= mple-low.c:217 #7=C2=A0 0x00b146a0 in _ZN12_GLOBAL__N_113pass_lower_cf7executeEP8function ( =C2=A0=C2=A0=C2=A0 this=3D0x79ab92a0) at ../../gcc/gcc/gimple-low.c:110 #8=C2=A0 0x00e8b140 in _Z16execute_one_passP8opt_pass (pass=3D0x40716078) =C2=A0=C2=A0=C2=A0 at ../../gcc/gcc/passes.c:2567 #9=C2=A0 0x00e8ba2c in _ZL19execute_pass_list_1P8opt_pass (pass=3D0x4071607= 8) =C2=A0=C2=A0=C2=A0 at ../../gcc/gcc/passes.c:2656 ---Type to continue, or q to quit--- #10 0x00e8bad0 in _Z17execute_pass_listP8functionP8opt_pass (fn=3D0x79ab92a= 0, =C2=A0=C2=A0=C2=A0 pass=3D0x100) at ../../gcc/gcc/passes.c:2667 #11 0x00906578 in _ZN11cgraph_node7analyzeEv (this=3D) =C2=A0=C2=A0=C2=A0 at ../../gcc/gcc/cgraphunit.c:680 #12 0x009098e0 in _ZL17analyze_functionsb (first_time=3D148) =C2=A0=C2=A0=C2=A0 at ../../gcc/gcc/cgraphunit.c:1234 #13 0x0090a6c8 in _ZN12symbol_table25finalize_compilation_unitEv ( =C2=A0=C2=A0=C2=A0 this=3D0x79c59000) at ../../gcc/gcc/cgraphunit.c:2508 #14 0x00fcd444 in _ZL12compile_filev () at ../../gcc/gcc/toplev.c:483 #15 0x00fd0d5c in _ZN6toplev4mainEiPPc (this=3D0x7a000a98, argc=3D0, argv= =3D0x0) =C2=A0=C2=A0=C2=A0 at ../../gcc/gcc/toplev.c:2233 #16 0x01461b40 in main (argc=3D20, argv=3D0x7a0008f4) at ../../gcc/gcc/main= .c:39=