Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

#1200 Fatal Error in MCS-51 medium model compiler

closed-fixed
Maarten Brock
5
2013-05-25
2006-09-25
Anonymous
No

>>> The error is:

[apply] file.c:30: error 9: FATAL Compiler
Internal Error in file '/home/users/s/sd/sdcc-
builder/build/sdcc-build/orig/sdcc/src/mcs51/gen.c'
line number '440' : getFreePtr should never reach
here

>>> The SDCC version is:

mcs51/gbz80/z80/avr/ds390/pic16/pic14/TININative/xa51/
ds400/hc08 2.6.0 #4309 (Jul 28 2006) (MINGW32)

>>> The command line is:

sdcc -c -mmcs51 --code-size 8192 --iram-size 256 --
xram-size 512 --model-medium --use-stdout --debug -o
bla.out file.c

>>> The (simplified) crashing code is:

unsigned int test()
{
unsigned int i,j;
unsigned long l=0;

for (i=0;i<10;i++)
{
j=SP; // any SFR would do to generate crash
l+=j;
}
return 1; // <- it gives error on this line
}

>>> Note

It only crashes when using --model-medium. It doesn't
crash with --model-small.

Thanks everybody for your hard work!

Discussion

  • Logged In: YES
    user_id=564030
    Originator: NO

    Please change category from "Build system" to mcs51.

    Philipp

     
    • labels: 101551 --> mcs51(8051) target
     
  • Maarten Brock
    Maarten Brock
    2008-02-26

    Logged In: YES
    user_id=888171
    Originator: NO

    Fixed in SDCC 2.7.5 #5053.

     
  • Maarten Brock
    Maarten Brock
    2008-02-26

    • milestone: --> fixed
    • assigned_to: nobody --> maartenbrock
    • status: open --> closed-fixed