[llvm-commits] CVS: llvm/lib/CodeGen/AsmPrinter.cpp
Chris Lattner
lattner at cs.uiuc.edu
Wed Feb 8 18:26:15 PST 2006
Changes in directory llvm/lib/CodeGen:
AsmPrinter.cpp updated: 1.49 -> 1.50
---
Log message:
Simplify code, alignment must be specified now.
---
Diffs of the changes: (+1 -10)
AsmPrinter.cpp | 11 +----------
1 files changed, 1 insertion(+), 10 deletions(-)
Index: llvm/lib/CodeGen/AsmPrinter.cpp
diff -u llvm/lib/CodeGen/AsmPrinter.cpp:1.49 llvm/lib/CodeGen/AsmPrinter.cpp:1.50
--- llvm/lib/CodeGen/AsmPrinter.cpp:1.49 Wed Feb 8 17:41:56 2006
+++ llvm/lib/CodeGen/AsmPrinter.cpp Wed Feb 8 20:26:04 2006
@@ -112,16 +112,7 @@
SwitchSection(ConstantPoolSection, 0);
for (unsigned i = 0, e = CP.size(); i != e; ++i) {
- // FIXME: force doubles to be naturally aligned. We should handle this
- // more correctly in the future.
- unsigned Alignment = CP[i].second;
- if (Alignment == 0) {
- Alignment = TD.getTypeAlignmentShift(CP[i].first->getType());
- if (CP[i].first->getType() == Type::DoubleTy && Alignment < 3)
- Alignment = 3;
- }
-
- EmitAlignment(Alignment);
+ EmitAlignment(CP[i].second);
O << PrivateGlobalPrefix << "CPI" << getFunctionNumber() << '_' << i
<< ":\t\t\t\t\t" << CommentString << *CP[i].first << '\n';
EmitGlobalConstant(CP[i].first);
More information about the llvm-commits
mailing list