Yahoo Groups archive

Lpc2000

Index last updated: 2026-04-28 23:31 UTC

Message

unexplained RAM use on GCC and CrrosWorks

2005-11-21 by Gus

put the following code in a file and compile it. it takes 240 byte 
of RAM!!!!!!

Can anyone explain why?
Remove any one of the cases and the RAM usage goes down to NONE!!!

int foo(int i)
{
    switch (i)
    {
            case 0x22:
            case 0x2A:
            case 0x2B:
            case 0x3E:
            case 0x5C:
            case 0x5D:
                    return 12;
            break;
    }    
}

Attachments

Move to quarantaine

This moves the raw source file on disk only. The archive index is not changed automatically, so you still need to run a manual refresh afterward.