[llvm-commits] [llvm] r127019 - in /llvm/trunk: lib/Target/ARM/ARMGlobalMerge.cpp test/CodeGen/ARM/2011-01-19-MergedGlobalDbg.ll test/CodeGen/ARM/global-merge.ll

Devang Patel dpatel at apple.com
Fri Mar 4 12:07:32 PST 2011


On Mar 4, 2011, at 12:01 PM, Rafael Avila de Espindola wrote:

> On 11-03-04 02:53 PM, Anton Korobeynikov wrote:
>> Hi Devang,
>> 
>>> Disable ARMGlobalMerge on darwin. The debugger is not yet able to
>>> extract individual variable's info from merged global.
>> Can't we just disable the merging of stuff with debug metadata
>> attached? This way we can keep the variables available for debugger
>> and won't hurt release builds.
> 
> In general it is a good idea for "$CC -c foo.c" and "$CC -g -c foo.c" to 
> produce the same output other than the extra section with debug info.

Yup, in fact we consider it is a requirement. 

We even have test harness (TEST=dbgopt in llvm-tests) to monitor this. What it does is simple :

$CC -fno-verbose-asm -S -Os foo.c -o foo.first.s
$CC -fno-verbose-asm -S -Os -g foo.c -mllvm -disable-debug-info-print -o foo.second.s
diff foo.first.s foo.second.s

-
Devang



More information about the llvm-commits mailing list