[llvm-commits] [llvm] r100616 - in /llvm/trunk/lib/CodeGen/AsmPrinter: DwarfDebug.cpp DwarfDebug.h DwarfException.cpp DwarfException.h

Török Edwin edwintorok at gmail.com
Wed Apr 7 03:20:40 PDT 2010


On 04/07/2010 12:28 PM, Bill Wendling wrote:
> Author: void
> Date: Wed Apr  7 04:28:04 2010
> New Revision: 100616
> 
> URL: http://llvm.org/viewvc/llvm-project?rev=100616&view=rev
> Log:
> Use the "NamedGroupTimer" class to categorize DWARF emission better.

Hi Bill,

Looks like this change broke most of the buildbots, because the dwarf
timers are now shown unconditionally on stderr when llc quits, see for
example:
http://google1.osuosl.org:8011/builders/clang-i686-linux/builds/6270/steps/test-llvm/logs/2007-03-07-combinercrash.ll



> 
> Modified:
>     llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
>     llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.h
>     llvm/trunk/lib/CodeGen/AsmPrinter/DwarfException.cpp
>     llvm/trunk/lib/CodeGen/AsmPrinter/DwarfException.h
> 
> Modified: llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp?rev=100616&r1=100615&r2=100616&view=diff
> ==============================================================================
> --- llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp (original)
> +++ llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp Wed Apr  7 04:28:04 2010
> @@ -39,6 +39,11 @@
>  #include "llvm/System/Path.h"
>  using namespace llvm;
>  
> +namespace {
> +  const char *DWARFGroupName = "DWARF Emission";
> +  const char *DbgTimerName = "DWARF Debug Writer";
> +} // end anonymous namespace
> +
>  //===----------------------------------------------------------------------===//
>  
>  /// Configuration values for initial hash set sizes (log2).
> @@ -305,22 +310,17 @@
>  DwarfDebug::DwarfDebug(AsmPrinter *A, Module *M)
>    : Asm(A), MMI(Asm->MMI), ModuleCU(0),
>      AbbreviationsSet(InitAbbreviationsSetSize), 
> -    CurrentFnDbgScope(0), DebugTimer(0) {
> +    CurrentFnDbgScope(0) {
>    NextStringPoolNumber = 0;
>        
>    DwarfFrameSectionSym = DwarfInfoSectionSym = DwarfAbbrevSectionSym = 0;
>    DwarfStrSectionSym = TextSectionSym = 0;
>        
> -  if (TimePassesIsEnabled)
> -    DebugTimer = new Timer("Dwarf Debug Writer");

Looks like you should guard the new timers with if (TimePassesIsEnabled).

Best regards,
--Edwin



More information about the llvm-commits mailing list