Skip to content

Conversation

@compnerd
Copy link
Member

@compnerd compnerd commented Sep 1, 2023

llvm::MallocAllocator uses operator new, not malloc. This memory may not be free'ed but must be deleted. However, this is also not guaranteed. Instead, we should have a global bump allocator or a global llvm::MallocAllocator that uses Allocate and Deallocate to manage this memory.

`llvm::MallocAllocator` uses `operator new`, not `malloc`.  This memory
may not be `free`'ed but must be `delete`d.  However, this is also not
guaranteed.  Instead, we should have a global bump allocator or a global
`llvm::MallocAllocator` that uses `Allocate` and `Deallocate` to manage
this memory.
@compnerd
Copy link
Member Author

compnerd commented Sep 1, 2023

CC: @DougGregor @rintaro @bnbarham

@compnerd compnerd mentioned this pull request Sep 1, 2023
9 tasks
@DougGregor
Copy link
Member

I have a nicer version of this in #68271

@DougGregor DougGregor closed this Sep 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants