mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-10-21 20:12:56 +02:00
make elf targets correctly handle constant pool entries that require relocations.
llvm-svn: 77130
This commit is contained in:
parent
b3d6d59c10
commit
e795c027fd
@ -81,8 +81,13 @@ ELFTargetAsmInfo::SelectSectionForGlobal(const GlobalValue *GV,
|
||||
const Section *
|
||||
ELFTargetAsmInfo::getSectionForMergableConstant(uint64_t Size,
|
||||
unsigned ReloInfo) const {
|
||||
// FIXME: IF this global requires a relocation, can we really put it in
|
||||
// rodata??? This should check ReloInfo like darwin.
|
||||
// If this constant pool entry has relocations, stick it into a relocatable
|
||||
// section.
|
||||
if (ReloInfo == 2)
|
||||
return DataRelROSection;
|
||||
if (ReloInfo == 1)
|
||||
return DataRelROLocalSection;
|
||||
|
||||
|
||||
const char *SecName = 0;
|
||||
switch (Size) {
|
||||
|
Loading…
Reference in New Issue
Block a user