diff options
author | Chris Lattner <sabre@nondot.org> | 2004-08-17 06:48:16 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2004-08-17 06:48:16 +0000 |
commit | 9fa0fc4d5e2c003f7c1a94d72e80cdc3c26da46e (patch) | |
tree | 1e8490c27896ae12aac14b18200f33e5a2b6f5b0 /llvm/lib/CodeGen/AsmPrinter.cpp | |
parent | f97bce72148e080d6701aa136feeeffca0815fbc (diff) | |
download | bcm5719-llvm-9fa0fc4d5e2c003f7c1a94d72e80cdc3c26da46e.tar.gz bcm5719-llvm-9fa0fc4d5e2c003f7c1a94d72e80cdc3c26da46e.zip |
Add support for targets that have .quad, drop extra tab inserted
llvm-svn: 15870
Diffstat (limited to 'llvm/lib/CodeGen/AsmPrinter.cpp')
-rw-r--r-- | llvm/lib/CodeGen/AsmPrinter.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter.cpp b/llvm/lib/CodeGen/AsmPrinter.cpp index 7773274eed4..92707528f97 100644 --- a/llvm/lib/CodeGen/AsmPrinter.cpp +++ b/llvm/lib/CodeGen/AsmPrinter.cpp @@ -31,11 +31,8 @@ bool AsmPrinter::doFinalization(Module &M) { void AsmPrinter::setupMachineFunction(MachineFunction &MF) { // What's my mangled name? CurrentFnName = Mang->getValueName((Value*)MF.getFunction()); - } - - // Print out the specified constant, without a storage class. Only the // constants valid in constant expressions can occur here. void AsmPrinter::emitConstantValueOnly(const Constant *CV) { @@ -203,7 +200,9 @@ void AsmPrinter::emitGlobalConstant(const Constant *CV) { } U; U.FVal = Val; - if (TD.isBigEndian()) { + if (Data64bitsDirective) + O << Data64bitsDirective << U.UVal << "\n"; + else if (TD.isBigEndian()) { O << Data32bitsDirective << unsigned(U.UVal >> 32) << "\t; double most significant word " << Val << "\n"; O << Data32bitsDirective << unsigned(U.UVal) @@ -229,7 +228,9 @@ void AsmPrinter::emitGlobalConstant(const Constant *CV) { if (const ConstantInt *CI = dyn_cast<ConstantInt>(CV)) { uint64_t Val = CI->getRawValue(); - if (TD.isBigEndian()) { + if (Data64bitsDirective) + O << Data64bitsDirective << Val << "\n"; + else if (TD.isBigEndian()) { O << Data32bitsDirective << unsigned(Val >> 32) << "\t; Double-word most significant word " << Val << "\n"; O << Data32bitsDirective << unsigned(Val) @@ -245,7 +246,6 @@ void AsmPrinter::emitGlobalConstant(const Constant *CV) { } const Type *type = CV->getType(); - O << "\t"; switch (type->getTypeID()) { case Type::UByteTyID: case Type::SByteTyID: O << Data8bitsDirective; |