-
Notifications
You must be signed in to change notification settings - Fork 5
Memory Allocation Intrinsics #73
Copy link
Copy link
Open
Labels
enhancementNew feature or requestNew feature or request
Description
- Introduce an IR instrinsic function to represent zeroing and nonzeroin memory allocation (calloc and malloc) (use
IntrinCallstmt), probably make the set of intrinsics an ADT or polymorphic variant. - Introduce a transform pass that soundly replaces calls to external procedures named
mallocandcallocwith calls to this intrinsic. Be careful of the detail of which registers are preserved or clobbered across the call. Most likely assume an IR with parameter form, and assume the ABI is adhered to.
The goal here is to avoid analyses having to ever match on procedure names and apply a specific semantics; if we do this we need to introduce an intrinsic.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request