1
0
mirror of https://github.com/c64scene-ar/llvm-6502.git synced 2025-04-22 00:37:49 +00:00

IA64 is as weird as Alpha wrt r/o relocs :)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@68007 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Anton Korobeynikov 2009-03-29 17:14:35 +00:00
parent 01209bc12a
commit 721c2c647e
2 changed files with 8 additions and 0 deletions

@ -12,6 +12,8 @@
//===----------------------------------------------------------------------===//
#include "IA64TargetAsmInfo.h"
#include "llvm/Constants.h"
#include "llvm/Target/TargetMachine.h"
using namespace llvm;
@ -34,4 +36,9 @@ IA64TargetAsmInfo::IA64TargetAsmInfo(const TargetMachine &TM):
ConstantPoolSection = "\n\t.section .data, \"aw\", \"progbits\"\n";
}
unsigned IA64TargetAsmInfo::RelocBehaviour() const {
return (TM.getRelocationModel() != Reloc::Static ?
Reloc::LocalOrGlobal : Reloc::Global);
}
// FIXME: Support small data/bss/rodata sections someday.

@ -24,6 +24,7 @@ namespace llvm {
struct IA64TargetAsmInfo : public ELFTargetAsmInfo {
explicit IA64TargetAsmInfo(const TargetMachine &TM);
virtual unsigned RelocBehaviour() const;
};