[llvm] de863bc - [Support] Fix up header comments after splitting Allocator.h, NFC

Reid Kleckner via llvm-commits llvm-commits at lists.llvm.org
Fri Jan 24 17:44:44 PST 2020


Author: Reid Kleckner
Date: 2020-01-24T17:43:38-08:00
New Revision: de863bcc6c860dd63f611ab6062856d275e3a3de

URL: https://github.com/llvm/llvm-project/commit/de863bcc6c860dd63f611ab6062856d275e3a3de
DIFF: https://github.com/llvm/llvm-project/commit/de863bcc6c860dd63f611ab6062856d275e3a3de.diff

LOG: [Support] Fix up header comments after splitting Allocator.h, NFC

Added: 
    

Modified: 
    llvm/include/llvm/Support/Allocator.h
    llvm/include/llvm/Support/AllocatorBase.h

Removed: 
    


################################################################################
diff  --git a/llvm/include/llvm/Support/Allocator.h b/llvm/include/llvm/Support/Allocator.h
index b631815df01b..cf3a709fa8fe 100644
--- a/llvm/include/llvm/Support/Allocator.h
+++ b/llvm/include/llvm/Support/Allocator.h
@@ -7,13 +7,10 @@
 //===----------------------------------------------------------------------===//
 /// \file
 ///
-/// This file defines the MallocAllocator and BumpPtrAllocator interfaces. Both
-/// of these conform to an LLVM "Allocator" concept which consists of an
-/// Allocate method accepting a size and alignment, and a Deallocate accepting
-/// a pointer and size. Further, the LLVM "Allocator" concept has overloads of
-/// Allocate and Deallocate for setting size and alignment based on the final
-/// type. These overloads are typically provided by a base class template \c
-/// AllocatorBase.
+/// This file defines the BumpPtrAllocator interface. BumpPtrAllocator conforms
+/// to the LLVM "Allocator" concept and is similar to MallocAllocator, but
+/// objects cannot be deallocated. Their lifetime is tied to the lifetime of the
+/// allocator.
 ///
 //===----------------------------------------------------------------------===//
 

diff  --git a/llvm/include/llvm/Support/AllocatorBase.h b/llvm/include/llvm/Support/AllocatorBase.h
index 5c4328a55fa5..c5a2f03e6bf8 100644
--- a/llvm/include/llvm/Support/AllocatorBase.h
+++ b/llvm/include/llvm/Support/AllocatorBase.h
@@ -1,4 +1,4 @@
-//===- AllocatorBase.h - Simple memory allocation abstraction -------*- C++ -*-===//
+//===- AllocatorBase.h - Simple memory allocation abstraction ---*- C++ -*-===//
 //
 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
 // See https://llvm.org/LICENSE.txt for license information.
@@ -7,13 +7,12 @@
 //===----------------------------------------------------------------------===//
 /// \file
 ///
-/// This file defines the MallocAllocator and BumpPtrAllocator interfaces. Both
-/// of these conform to an LLVM "Allocator" concept which consists of an
-/// Allocate method accepting a size and alignment, and a Deallocate accepting
-/// a pointer and size. Further, the LLVM "Allocator" concept has overloads of
-/// Allocate and Deallocate for setting size and alignment based on the final
-/// type. These overloads are typically provided by a base class template \c
-/// AllocatorBase.
+/// This file defines MallocAllocator. MallocAllocator conforms to the LLVM
+/// "Allocator" concept which consists of an Allocate method accepting a size
+/// and alignment, and a Deallocate accepting a pointer and size. Further, the
+/// LLVM "Allocator" concept has overloads of Allocate and Deallocate for
+/// setting size and alignment based on the final type. These overloads are
+/// typically provided by a base class template \c AllocatorBase.
 ///
 //===----------------------------------------------------------------------===//
 


        


More information about the llvm-commits mailing list