chicken-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-users] c-string return question


From: Jörg F . Wittenberger
Subject: Re: [Chicken-users] c-string return question
Date: 13 Oct 2011 19:24:12 +0200

On Oct 13 2011, Jörg F. Wittenberger wrote:
Recently this code begin to return garbage under gcc 4.4.5
on amd64 and ARM, though more reliable on ARM.

I forgot some marginal thing you might want to know just in case:

With gcc 4.4.5 (as in current debian stable) you really, really
don't want to compile C code as produced by Chicken with
gcc -O3 !!

This works for me for small test programs so far.

But with a 50k LoC program it runs into all sorts of errors.
Just deleting the .o files and recompile the same C code gives
me a working executable.

This trigger memories to my recent observation
http://lists.nongnu.org/archive/html/chicken-users/2011-10/msg00067.html
This one came up under gcc 4.5.2 (as in current Ubuntu).

IMHO the moral of the story: Never trust you C compiler too much.

Since the latter would be a case of the newer compiler producing
code from perfect C source about valgrind will complain.
(Which does not exclude the chance that valgrind would be wrong.
Just I don't believe in that.)

I'm afraid these facts are almost off-topic here.
Unrelated except for the collateral damage, that Chicken compiles
to C, which is not exactly an executable format on most machines.  ;-)


/Jörg






reply via email to

[Prev in Thread] Current Thread [Next in Thread]