OSDN Git Service

Fix these comments to reflect current reality. Surprisingly,
authorDan Gohman <gohman@apple.com>
Tue, 16 Sep 2008 20:45:53 +0000 (20:45 +0000)
committerDan Gohman <gohman@apple.com>
Tue, 16 Sep 2008 20:45:53 +0000 (20:45 +0000)
MachineConstantPool::getConstantPoolIndex actually expects
a log2-encoded alignment.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56248 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/CodeGen/MachineConstantPool.h
lib/CodeGen/MachineFunction.cpp

index 9db6831..280d54d 100644 (file)
@@ -122,7 +122,8 @@ public:
   unsigned getConstantPoolAlignment() const { return PoolAlignment; }
   
   /// getConstantPoolIndex - Create a new entry in the constant pool or return
-  /// an existing one.  User must specify an alignment in bytes for the object.
+  /// an existing one.  User must specify the log2 of the minimum required
+  /// alignment for the object.
   unsigned getConstantPoolIndex(Constant *C, unsigned Alignment);
   unsigned getConstantPoolIndex(MachineConstantPoolValue *V,unsigned Alignment);
   
index 5aade03..bbc69a9 100644 (file)
@@ -479,7 +479,8 @@ MachineConstantPool::~MachineConstantPool() {
 }
 
 /// getConstantPoolIndex - Create a new entry in the constant pool or return
-/// an existing one.  User must specify an alignment in bytes for the object.
+/// an existing one.  User must specify the log2 of the minimum required
+/// alignment for the object.
 ///
 unsigned MachineConstantPool::getConstantPoolIndex(Constant *C, 
                                                    unsigned Alignment) {