aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Target/PowerPC/PPCTargetAsmInfo.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Target/PowerPC/PPCTargetAsmInfo.cpp')
-rw-r--r--lib/Target/PowerPC/PPCTargetAsmInfo.cpp14
1 files changed, 5 insertions, 9 deletions
diff --git a/lib/Target/PowerPC/PPCTargetAsmInfo.cpp b/lib/Target/PowerPC/PPCTargetAsmInfo.cpp
index 25920da0fe..36cf2a5570 100644
--- a/lib/Target/PowerPC/PPCTargetAsmInfo.cpp
+++ b/lib/Target/PowerPC/PPCTargetAsmInfo.cpp
@@ -12,21 +12,19 @@
//===----------------------------------------------------------------------===//
#include "PPCTargetAsmInfo.h"
-#include "llvm/ADT/Triple.h"
using namespace llvm;
-PPCDarwinTargetAsmInfo::PPCDarwinTargetAsmInfo(const Triple &TheTriple)
- : DarwinTargetAsmInfo(TheTriple) {
+PPCDarwinTargetAsmInfo::PPCDarwinTargetAsmInfo(bool is64Bit) {
PCSymbol = ".";
CommentString = ";";
ExceptionsType = ExceptionHandling::Dwarf;
- if (TheTriple.getArch() != Triple::ppc64)
+ if (!is64Bit)
Data64bitsDirective = 0; // We can't emit a 64-bit unit in PPC32 mode.
AssemblerDialect = 1; // New-Style mnemonics.
}
-PPCLinuxTargetAsmInfo::PPCLinuxTargetAsmInfo(const Triple &TheTriple) {
+PPCLinuxTargetAsmInfo::PPCLinuxTargetAsmInfo(bool is64Bit) {
CommentString = "#";
GlobalPrefix = "";
PrivateGlobalPrefix = ".L";
@@ -43,15 +41,13 @@ PPCLinuxTargetAsmInfo::PPCLinuxTargetAsmInfo(const Triple &TheTriple) {
HasLEB128 = true; // Target asm supports leb128 directives (little-endian)
// Exceptions handling
- if (TheTriple.getArch() != Triple::ppc64) {
+ if (!is64Bit)
ExceptionsType = ExceptionHandling::Dwarf;
- Data64bitsDirective = 0;
- }
AbsoluteEHSectionOffsets = false;
ZeroDirective = "\t.space\t";
SetDirective = "\t.set";
-
+ Data64bitsDirective = is64Bit ? "\t.quad\t" : 0;
AlignmentIsInBytes = false;
LCOMMDirective = "\t.lcomm\t";
AssemblerDialect = 0; // Old-Style mnemonics.