<value optimized out> even with gcc -g -O0
Roberto Ragusa
mail at robertoragusa.it
Mon Feb 1 15:44:17 UTC 2010
Chuck Anderson wrote:
> On Mon, Feb 01, 2010 at 09:34:19AM +0100, Gianluca Sforna wrote:
>> On Mon, Feb 1, 2010 at 7:18 AM, Chuck Anderson <cra at wpi.edu> wrote:
>>> Program received signal SIGSEGV, Segmentation fault.
>>> playmonoi16 (dst=0x76ddc0, len=<value optimized out>,
>>> ch=<value optimized out>) at mixasm.c:1746
>> Sorry for asking the obvious, but this hit me several times... is this
>> mixasm.c file part of the sources you are compiling with -g -O0? if
>> it's in a library your code is using, you also need to recompile that
>> one with -O0.
>
> Yup, it is part of the source. Many/most of the files are actually
> compiled as shared objects, but everything is using -g -O0. Someone
> on #gdb thinks this is a gcc bug.
One thing I would try is adding a
int *lenp=&len;
somewhere, just to make optimization a little more difficult for gcc.
Maybe you avoid the bug, if there is one.
--
Roberto Ragusa mail at robertoragusa.it
More information about the devel
mailing list