[llvm-commits] [llvm] r93402 - /llvm/trunk/lib/VMCore/AsmWriter.cpp
Victor Hernandez
vhernandez at apple.com
Mon Jan 18 11:16:15 PST 2010
Fixed in r93748.
Victor
On Jan 18, 2010, at 11:02 AM, Devang Patel wrote:
>
> On Jan 13, 2010, at 5:47 PM, Victor Hernandez wrote:
>
>> Author: hernande
>> Date: Wed Jan 13 19:47:37 2010
>> New Revision: 93402
>>
>> URL: http://llvm.org/viewvc/llvm-project?rev=93402&view=rev
>> Log:
>> Fix printing of function-local metadata in AsmWriter
>>
>> Modified:
>> llvm/trunk/lib/VMCore/AsmWriter.cpp
>>
>> Modified: llvm/trunk/lib/VMCore/AsmWriter.cpp
>> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/VMCore/AsmWriter.cpp?rev=93402&r1=93401&r2=93402&view=diff
>>
>> ==============================================================================
>> --- llvm/trunk/lib/VMCore/AsmWriter.cpp (original)
>> +++ llvm/trunk/lib/VMCore/AsmWriter.cpp Wed Jan 13 19:47:37 2010
>> @@ -2062,8 +2062,9 @@
>> else
>> W.printAlias(cast<GlobalAlias>(GV));
>> } else if (const MDNode *N = dyn_cast<MDNode>(this)) {
>> - SlotTracker SlotTable((Function*)0);
>> - AssemblyWriter W(OS, SlotTable, 0, AAW);
>> + Function *F = N->getFunction();
>
> What if getFunction() returns NULL ?
> -
> Devang
>> + SlotTracker SlotTable(F);
>> + AssemblyWriter W(OS, SlotTable, getModuleFromVal(F), AAW);
>
>
>> W.printMDNodeBody(N);
>> } else if (const NamedMDNode *N = dyn_cast<NamedMDNode>(this)) {
>> SlotTracker SlotTable(N->getParent());
>>
>>
>> _______________________________________________
>> llvm-commits mailing list
>> llvm-commits at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>
More information about the llvm-commits
mailing list