[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: gm2 internal compiler error report
From: |
Gaius Mulley |
Subject: |
Re: gm2 internal compiler error report |
Date: |
Thu, 14 Mar 2024 23:08:05 +0000 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) |
Alice Osako <alicetrillianosako@gmail.com> writes:
> Gaius Mulley:
>
> Thanks for the bug report - I believe this is fixed in the latest git
> gcc repro (gcc-14):
>
> $ gm2 -g -Idefs -fiso -c impls/UTF8.mod
> impls/UTF8.mod:47:13: error: In procedure ‘GetExtChar’: type incompatibility
> between ‘CARDINAL’ and ‘BYTE’
> 47 | RETURN b - {7, 6};
> | ~~^~~~~~~~
>
> $ gm2 --version
> gm2 (GCC) 14.0.1 20240308 (experimental)
>
> I'll back port the fix to gm2 13.2
>
> OK, I tried the latest build of gm2, which according to the GCC git summary
> includes the fix you mentioned, and I continued to get an internal compiler
> error.
>
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> // Target: x86_64-pc-linux-gnu
> // Configured with: /home/schol-r-lea/Deployments/gm2/gcc/configure
> --host=x86_64-pc-linux-gnu --target=x86_64-pc-linux-gnu
> --prefix=/home/schol-r-lea/opt --bindir=/home/schol-r-lea/opt/bin
> --libdir=/home/schol-r-lea/opt/lib --libexecdir=/home/schol-r-lea/opt/lib
> --enable-threads=posix --enable-clocale=gnu --disable-multilib
> --disable-bootstrap --enable-checking --enable-languages=m2 : (reconfigured)
> /home/schol-r-lea/Deployments/gm2/gcc/configure --host=x86_64-pc-linux-gnu
> --target=x86_64-pc-linux-gnu --prefix=/home/schol-r-lea/opt
> --bindir=/home/schol-r-lea/opt/bin --libdir=/home/schol-r-lea/opt/lib
> --libexecdir=/home/schol-r-lea/opt/lib --enable-threads=posix
> --enable-clocale=gnu
> --disable-multilib --disable-bootstrap --enable-checking --enable-languages=m2
> // Thread model: posix
> // Supported LTO compression algorithms: zlib zstd
> // gcc version 13.2.1 20240314 (GCC)
> //
> // _M2_UTF8_init _M2_UTF8_fini
> // -quiet: internal compiler error: not expecting this kind of symbol
> // 0x1f081d7 internal_error(char const*, ...)
> // ???:0
> // 0x8cbdc2 m2linemap_internal_error
> // ???:0
> // 0x99669b M2Emit_InternalError
> // ???:0
> // 0x8f60ee M2Error_InternalError
> // ???:0
> // 0x9573b3 SymbolTable_IsValueSolved
> // ???:0
> // 0x8e206d M2ALU_TryEvaluateValue
> // ???:0
> // 0x8fb656 M2GCCDeclare_TryDeclareConstructor
> // ???:0
> // 0x8fb6c2 M2GCCDeclare_TryDeclareConstant
> // ???:0
> // 0x90701e M2GenGCC_ResolveConstantExpressions
> // ???:0
> // 0x938c6c M2Scope_ForeachScopeBlockDo
> // ???:0
> // 0x8f23c2 M2Code_CodeBlock
> // ???:0
> // 0x8dfb2a Lists_ForeachItemInListDo
> // ???:0
> // 0x8f2536 M2Code_CodeBlock
> // ???:0
> // 0x8f28da M2Code_Code
> // ???:0
> // 0x8f3751 M2Comp_compile
> // ???:0
> // Please submit a full bug report, with preprocessed source.
> // Please include the complete backtrace with any bug report.
> // See <https://gcc.gnu.org/bugs/> for instructions.
>
> // /home/schol-r-lea/opt/lib/gcc/x86_64-pc-linux-gnu/13.2.1/cc1gm2 -quiet
> -dumpbase UTF8.mod -dumpbase-ext .mod -mtune=generic -march=x86-64 -g
> -fiso -freport-bug -fm2-pathname=- -fm2-pathnameIdefs/ -fm2-pathnameI.
> -fscaffold-dynamic -flibs=m2iso,m2cor,m2pim,m2log -fm2-pathname=-
> -fm2-pathnameIdefs/ -fm2-pathnameI. impls/UTF8.mod -c -o - -frandom-seed=0
> -fdump-noaddr
>
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
> The current version of the code is which seems to breaking is:
>
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> (* in the definition file *)
> TYPE
> Octet = PACKEDSET OF CARDINAL [0 .. 0FFH];
> UTF8Buffer = ARRAY [0..3] OF Octet;
>
> (* in the implementation file *)
> PROCEDURE GetSubChar(b: Octet): Octet;
> BEGIN
> RETURN b - {6..7};
> END GetSubChar;
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
> Again, the repo for the whole can be found at
> https://github.com/Schol-R-LEA/UNICODE-For-Modula-2/
>
> Sorry to keep bothering you with this.
Hi Alice,
thanks for the bug reports and test code. With the latest gm2 from the
gcc git, I get the following results:
$ gm2 --version
gm2 (GCC) 14.0.1 20240314 (experimental)
Copyright (C) 2024 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
$ make -k
/home/gaius/opt/bin/gm2 -g -fiso -freport-bug -Idefs/ -c impls/Unicode.mod
/home/gaius/opt/bin/gm2 -g -fiso -freport-bug -Idefs/ -c impls/UTF8.mod
impls/UTF8.mod:131:47: error: In procedure ‘UnicharToUtf8’: type
incompatibility between ‘CARDINAL’ and ‘WORD’
131 | utf8[1] := extMask + (WordShr(ch, 6) - {6..31}) |
| ~~~~~~~~~~~~~~~^~~~~~~~~
make: *** [Makefile:16: utf8] Error 1
make: *** No rule to make target 'uintextio', needed by 'testucs4repr'.
make: Target 'testucs4repr' not remade because of errors.
(Although I think the error type message looks wrong though - it should
say BITSET and WORD perhaps).
regards,
Gaius
- Re: Portable bitwise operations library (was Re: Portability Considerations), (continued)
- Re: Portable bitwise operations library (was Re: Portability Considerations), Benjamin Kowarsch, 2024/03/22
- Re: Portable bitwise operations library (was Re: Portability Considerations), Benjamin Kowarsch, 2024/03/22
- Re: Portable bitwise operations library (was Re: Portability Considerations), Gaius Mulley, 2024/03/23
- Re: Portable bitwise operations library (was Re: Portability Considerations), Fischlin Andreas, 2024/03/24
- Re: Portable bitwise operations library (was Re: Portability Considerations), Benjamin Kowarsch, 2024/03/24
- Re: Portable bitwise operations library (was Re: Portability Considerations), Fischlin Andreas, 2024/03/24
- Re: Portable bitwise operations library (was Re: Portability Considerations), Benjamin Kowarsch, 2024/03/22
- Re: Portable bitwise operations library (was Re: Portability Considerations), Eric Streit, 2024/03/23
- Re: Portable bitwise operations library (was Re: Portability Considerations), Christoph Schlegel, 2024/03/20
- Re: Portability Considerations, Gaius Mulley, 2024/03/20
- Re: gm2 internal compiler error report,
Gaius Mulley <=
- Re: gm2 internal compiler error report, Gaius Mulley, 2024/03/18