#361 Wrong stack offset: using and --stack-a

closed
5
2013-05-25
2002-07-23
Anonymous
No

Reported by Chris Erickson <cerickson99@earthlink.net>
http://sourceforge.net/mailarchive/forum.php?thread_id=837826&forum_id=4107

char foo (char c1, char c2) using 1 reentrant
{ return c1+c2; }

char main (void)
{ return foo (1, 2); }

SDCC calculates a wrong stack-offset:
;c2 Allocated to stack - offset -4
-3 is the correct value.

Discussion

  • Erik Petrich

    Erik Petrich - 2003-02-02

    Logged In: YES
    user_id=635249

    Fixed in sdcc/src/mcs51/main.c 1.64

     
  • Johan Knol

    Johan Knol - 2003-02-02
    • assigned_to: nobody --> epetrich
     
  • Johan Knol

    Johan Knol - 2003-02-02

    Logged In: YES
    user_id=63512

    Nice. For some reason you (epetrich) didn't had permissions
    to close the bug, now you should have. So if you're sure,
    please close the bug.

    Johan

     
  • Erik Petrich

    Erik Petrich - 2003-02-02
    • milestone: --> fixed
    • status: open --> closed
     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.





No, thanks