[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Gm2] internal compiler error:
From: |
Gaius Mulley |
Subject: |
Re: [Gm2] internal compiler error: |
Date: |
Sat, 10 Jun 2017 13:39:10 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) |
John Dubery <address@hidden> writes:
> Gaius,
> I get the following error:
>
> In function ‘_M2_ScreenTest_init’:
> cc1gm2: internal compiler error: in convert_loc, at
> gm2/gm2-lang.c:822
> Please submit a full bug report,
> with preprocessed source if appropriate.
> See <http://gcc.gnu.org/bugs.html> for instructions.
>
> when compiling:
>
> MODULE ScreenTest;
> FROM SYSTEM IMPORT ADDRESS;
> FROM RPiMailbox IMPORT
> WriteToMbox, ReadFromMbox;
> FROM RPiGPIOControl IMPORT
> FlashError, FlashNumber;
>
> TYPE FrameBufferType=
> RECORD
> PhysicalWidth: INTEGER;
> PhysicalHeight: INTEGER;
> VirtualWidth: INTEGER;
> VirtualHeight: INTEGER;
> GPUPitch: INTEGER;
> BitDepth: INTEGER;
> X: INTEGER;
> Y: INTEGER;
> GPUPointer: ARRAY [1..4096] OF CARDINAL;
> GPUSize: INTEGER;
> END;
> FrameBufferPtrType= POINTER TO FrameBufferType;
>
> VAR
> FrameBuffer: FrameBufferType;
> FrameBufferPtr: FrameBufferPtrType;
> Result: CARDINAL;
> ErrorNumber: INTEGER;
> X, Y, i: CARDINAL;
>
> BEGIN
> FrameBufferPtr:= ADDRESS (FrameBuffer);
> WITH FrameBufferPtr^ DO
> PhysicalWidth:=1024;
> PhysicalHeight:=768;
> VirtualWidth:=1024;
> VirtualHeight:=768;
> GPUPitch:=0;
> BitDepth:=16;
> X:=0;
> Y:=0;
> GPUPointer:=ADDRESS(0);
> GPUSize:=0;
> END;
>
> WriteToMbox(1, CARDINAL(FrameBufferPtr)+40000000H, ErrorNumber);
> IF ErrorNumber#0 THEN FlashError; FlashNumber(ErrorNumber) END;
> ReadFromMbox(1, Result, ErrorNumber);
> IF ErrorNumber#0 THEN FlashError; FlashNumber(ErrorNumber) END;
>
> (* Display colours systematically *)
> i:= 1;
> FOR X:= 1 TO 1024 DO
> FOR Y:= 1 TO 768 DO
> INC(i);
> FrameBufferPtr^.GPUPointer[i]:= i;
> END;
> END;
>
> END ScreenTest.
>
> The command was:
> gm2 -Wextra -save-temps ScreenTest.mod
> I can't find any relevant files in /tmp.
> I get the same error on AMD64 and ARM.
> On AMD64 I'm running Ubuntu 16.04, gm2 is 5.2.0, gcc is 5.4.0 20160609
> (Ubuntu 5.4.0-6ubuntu1~16.04.4).
> On the Raspberry Pi I'm running Raspbian. 'uname -a' gives:
> Linux dubery2-rpi 4.1.19+ #858 Tue Mar 15 15:52:03 GMT 2016 armv6l
> GNU/Linux
> gm2 is 4.7.4 , gcc is 4.6.3 (Debian 4.6.3-14+rpi1).
> Would you like the sub-modules? Any advice to work around this?
>
> Thanks,
> John
Hello John,
many thanks for the report -
> Would you like the sub-modules? Any advice to work around this?
yes please - if possible. So I can run the compiler and inspect it as
it fails under gdb. I'll keep the code in my non-free code test tree
(and only look at it when debugging gm2),
regards,
Gaius