[llvm-commits] [PATCH 6/10] Fix name clash when emitting TOC entries for PowerPC64
Adhemerval Zanella
azanella at linux.vnet.ibm.com
Mon Sep 17 13:20:24 PDT 2012
Current TOC entry name creation fails when a .ll file contains an symbol
that clash with the entry's name. For instance, if a .ll file contains
the definition:
@.LC0 = internal global [5 x i8] c".LC0\00"
And also generates a TOC entry, it will fail saying the symbol name can
not be defined twice.
This patch address this issue by checking if the symbol already exists
and incrementing the TOC counter if so (I didn't add any overflow check
because 'TOCLabelID' is a uint64_t). I also added a test to check the
name clash generation by creating two TOC entry like name and checking
its name generation.
--
Adhemerval Zanella Netto
Software Engineer
Linux Technology Center Brazil
Toolchain / GLIBC on Power Architecture
azanella at linux.vnet.ibm.com / azanella at br.ibm.com
+55 61 8642-9890
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0007-Fix-name-clash-when-emitting-TOC-entries-for-PowerPC.patch
Type: text/x-patch
Size: 2781 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20120917/f8a2e0a4/attachment.bin>
More information about the llvm-commits
mailing list