[llvm] r196158 - Debug Info: drop debug info via upgrading path if version number does not match.

Adrian Prantl aprantl at apple.com
Fri Dec 13 13:45:54 PST 2013


On Dec 2, 2013, at 13:29, Manman Ren <manman.ren at gmail.com> wrote:
> Modified: llvm/trunk/lib/IR/DebugInfo.cpp
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/IR/DebugInfo.cpp?rev=196158&r1=196157&r2=196158&view=diff
> ==============================================================================
> --- llvm/trunk/lib/IR/AutoUpgrade.cpp (original)
> +++ llvm/trunk/lib/IR/AutoUpgrade.cpp Mon Dec  2 15:29:56 2013
> +/// Check the debug info version number, if it is out-dated, drop the debug
> +/// info. Return true if module is modified.
> +bool llvm::UpgradeDebugInfo(Module &M) {
> +  if (getDebugInfoVersionFromModule(M) == DEBUG_METADATA_VERSION)
> +    return false;
> +
> +  return StripDebugInfo(M);
> +}
> 
Hi Manman,

sorry for commenting with such a delay.
Can we somehow make this not just silently drop the debug info but print a warning or at least a DEBUG() message?
Either here or in LLParser and BitCodeReader (which both seem to ignore the return value)?

thanks!
  adrian



More information about the llvm-commits mailing list