This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Unomitted frame pointers


Sam Lauber wrote:
Do you know about macro expansion? CPP would make it seperate strings. So there would be (simplified);

Have you actually TRIED this ?


int main(void)
{
       char str1 = "Hello World!\n";
       char str2 = "Hello World!\n";
       int str_len = 0;
       while (*str1++ != "\0")
              str_len++;
       write(2, str2, str_len);
}

This program won't compile. How do you know what assembly you'd get?


I think you're hypothesizing with no knowledge of the internals of the compiler,
or actual experimentation.

nathan
--
Nathan Sidwell    ::   http://www.codesourcery.com   ::     CodeSourcery LLC
nathan@codesourcery.com    ::     http://www.planetfall.pwp.blueyonder.co.uk


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]