[llvm-dev] Reviving the DebugIR pass

via llvm-dev llvm-dev at lists.llvm.org
Thu Mar 22 12:23:45 PDT 2018


>> This work could also be used to fix [3]. Although this probably needs
>> more though because there's the question of whether we should preserve
>> existing debug information in an LLVM IR file or write over it when it
>> is given to Clang.
>
> If foo.ll contains edited debug info, `clang -g` shouldn't silently drop
> the edits. A warning + no-op seems more appropriate.
>
> Happy to help with code review!
>
> thanks,
> vedant

Historically, the (mc) assembler has pretended the `-g` was not present
and simply used the debug info described in the assembler source, with no
diagnostic.  I think that would be reasonable behavior for `llvm-as -g`
or `clang -g foo.ll` as well.
--paulr



More information about the llvm-dev mailing list