<br><br><div>On Thu Jan 02 2014 at 1:09:50 PM, Eric Christopher <<a href="mailto:echristo@gmail.com">echristo@gmail.com</a>> wrote:</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Author: echristo<br>
Date: Thu Jan 2 15:03:28 2014<br>
New Revision: 198351<br>
<br>
URL: <a href="http://llvm.org/viewvc/llvm-project?rev=198351&view=rev" target="_blank">http://llvm.org/viewvc/llvm-<u></u>project?rev=198351&view=rev</a><br>
Log:<br>
Fix up a couple of review comments:<br>
<br>
Use an if statement instead of a pair of ternary operators checking<br>
the same condition.<br>
Use a cheap method call rather than returning the local symbol.<br>
<br>
Modified:<br>
llvm/trunk/lib/CodeGen/<u></u>AsmPrinter/DwarfDebug.cpp<br>
llvm/trunk/lib/CodeGen/<u></u>AsmPrinter/DwarfUnit.h<br>
<br>
Modified: llvm/trunk/lib/CodeGen/<u></u>AsmPrinter/DwarfDebug.cpp<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp?rev=198351&r1=198350&r2=198351&view=diff" target="_blank">http://llvm.org/viewvc/llvm-<u></u>project/llvm/trunk/lib/<u></u>CodeGen/AsmPrinter/DwarfDebug.<u></u>cpp?rev=198351&r1=198350&r2=<u></u>198351&view=diff</a><br>
==============================<u></u>==============================<u></u>==================<br>
--- llvm/trunk/lib/CodeGen/<u></u>AsmPrinter/DwarfDebug.cpp (original)<br>
+++ llvm/trunk/lib/CodeGen/<u></u>AsmPrinter/DwarfDebug.cpp Thu Jan 2 15:03:28 2014<br>
@@ -822,14 +822,14 @@ DwarfCompileUnit *DwarfDebug::constructD<br>
if (!FirstCU)<br>
FirstCU = NewCU;<br>
<br>
- NewCU->initSection(<br>
- useSplitDwarf() ? Asm->getObjFileLowering().<u></u>getDwarfInfoDWOSection()<br>
- : Asm->getObjFileLowering().<u></u>getDwarfInfoSection(),<br>
- useSplitDwarf() ? DwarfInfoDWOSectionSym : DwarfInfoSectionSym);<br>
-<br>
- // If we're splitting the dwarf then construct the skeleton CU now.<br>
- if (useSplitDwarf())<br>
+ if (useSplitDwarf()) {<br>
+ NewCU->initSection(Asm-><u></u>getObjFileLowering().<u></u>getDwarfInfoDWOSection(),<br>
+ DwarfInfoDWOSectionSym);<br>
+ // If we're splitting the dwarf then construct the skeleton CU now.<br></blockquote><div><br></div><div>Not sure about you, but this comment doesn't seem to add a lot to me... </div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
NewCU->setSkeleton(<u></u>constructSkeletonCU(NewCU));<br>
+ } else<br>
+ NewCU->initSection(Asm-><u></u>getObjFileLowering().<u></u>getDwarfInfoSection(),<br>
+ DwarfInfoSectionSym);<br>
<br>
CUMap.insert(std::make_pair(<u></u>DIUnit, NewCU));<br>
CUDieMap.insert(std::make_<u></u>pair(Die, NewCU));<br>
<br>
Modified: llvm/trunk/lib/CodeGen/<u></u>AsmPrinter/DwarfUnit.h<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/AsmPrinter/DwarfUnit.h?rev=198351&r1=198350&r2=198351&view=diff" target="_blank">http://llvm.org/viewvc/llvm-<u></u>project/llvm/trunk/lib/<u></u>CodeGen/AsmPrinter/DwarfUnit.<u></u>h?rev=198351&r1=198350&r2=<u></u>198351&view=diff</a><br>
==============================<u></u>==============================<u></u>==================<br>
--- llvm/trunk/lib/CodeGen/<u></u>AsmPrinter/DwarfUnit.h (original)<br>
+++ llvm/trunk/lib/CodeGen/<u></u>AsmPrinter/DwarfUnit.h Thu Jan 2 15:03:28 2014<br>
@@ -185,7 +185,7 @@ public:<br>
MCSymbol *getLocalSectionSym() const {<br>
if (Skeleton)<br>
return Skeleton->getSectionSym();<br>
- return SectionSym;<br>
+ return getSectionSym();<br>
}<br>
<br>
MCSymbol *getSectionSym() const {<br>
@@ -198,7 +198,7 @@ public:<br>
MCSymbol *getLocalLabelBegin() const {<br>
if (Skeleton)<br>
return Skeleton->getLabelBegin();<br>
- return LabelBegin;<br>
+ return getLabelBegin();<br>
}<br>
<br>
MCSymbol *getLabelBegin() const {<br>
<br>
<br>
______________________________<u></u>_________________<br>
llvm-commits mailing list<br>
<a href="mailto:llvm-commits@cs.uiuc.edu" target="_blank">llvm-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits" target="_blank">http://lists.cs.uiuc.edu/<u></u>mailman/listinfo/llvm-commits</a><br>
</blockquote>