summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorReid Spencer <rspencer@reidspencer.com>2006-12-21 19:04:23 +0000
committerReid Spencer <rspencer@reidspencer.com>2006-12-21 19:04:23 +0000
commit4e0c2a0e415ef0e15305dd595ceae866d054ca1d (patch)
treefff04a2aba997bccf0552fbd533394c9cf7c82f0
parentcfcec2caac382c3803cbbd5b608676f1f0d0c85f (diff)
downloadbcm5719-llvm-4e0c2a0e415ef0e15305dd595ceae866d054ca1d.tar.gz
bcm5719-llvm-4e0c2a0e415ef0e15305dd595ceae866d054ca1d.zip
Just print integer constants as signed values. The actual signedness
doesn't matter as it is determined in the way the constant is used. llvm-svn: 32733
-rw-r--r--llvm/lib/CodeGen/AsmPrinter.cpp8
1 files changed, 1 insertions, 7 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter.cpp b/llvm/lib/CodeGen/AsmPrinter.cpp
index 82e110a2753..5bbcaee339b 100644
--- a/llvm/lib/CodeGen/AsmPrinter.cpp
+++ b/llvm/lib/CodeGen/AsmPrinter.cpp
@@ -392,13 +392,7 @@ void AsmPrinter::EmitConstantValueOnly(const Constant *CV) {
assert(CB->getValue());
O << "1";
} else if (const ConstantInt *CI = dyn_cast<ConstantInt>(CV)) {
- if (CI->getType()->isSigned()) {
- if (((CI->getSExtValue() << 32) >> 32) == CI->getSExtValue())
- O << CI->getSExtValue();
- else
- O << (uint64_t)CI->getSExtValue();
- } else
- O << CI->getZExtValue();
+ O << CI->getSExtValue();
} else if (const GlobalValue *GV = dyn_cast<GlobalValue>(CV)) {
// This is a constant address for a global variable or function. Use the
// name of the variable or function as the address value, possibly
OpenPOWER on IntegriCloud