diff options
Diffstat (limited to 'llvm/lib/IR/Metadata.cpp')
| -rw-r--r-- | llvm/lib/IR/Metadata.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/IR/Metadata.cpp b/llvm/lib/IR/Metadata.cpp index 3e07b3a7c94..17aa1216b3e 100644 --- a/llvm/lib/IR/Metadata.cpp +++ b/llvm/lib/IR/Metadata.cpp @@ -434,7 +434,7 @@ StringRef MDString::getString() const { // prepended to them. #define HANDLE_MDNODE_LEAF(CLASS) \ static_assert( \ - llvm::AlignOf<uint64_t>::Alignment >= llvm::AlignOf<CLASS>::Alignment, \ + alignof(uint64_t) >= alignof(CLASS), \ "Alignment is insufficient after objects prepended to " #CLASS); #include "llvm/IR/Metadata.def" @@ -442,7 +442,7 @@ void *MDNode::operator new(size_t Size, unsigned NumOps) { size_t OpSize = NumOps * sizeof(MDOperand); // uint64_t is the most aligned type we need support (ensured by static_assert // above) - OpSize = alignTo(OpSize, llvm::alignOf<uint64_t>()); + OpSize = alignTo(OpSize, alignof(uint64_t)); void *Ptr = reinterpret_cast<char *>(::operator new(OpSize + Size)) + OpSize; MDOperand *O = static_cast<MDOperand *>(Ptr); for (MDOperand *E = O - NumOps; O != E; --O) @@ -453,7 +453,7 @@ void *MDNode::operator new(size_t Size, unsigned NumOps) { void MDNode::operator delete(void *Mem) { MDNode *N = static_cast<MDNode *>(Mem); size_t OpSize = N->NumOperands * sizeof(MDOperand); - OpSize = alignTo(OpSize, llvm::alignOf<uint64_t>()); + OpSize = alignTo(OpSize, alignof(uint64_t)); MDOperand *O = static_cast<MDOperand *>(Mem); for (MDOperand *E = O - N->NumOperands; O != E; --O) |

