Intercept new `free_sized` and `free_aligned_sized` functions
C23 adds two new deallocators, free_sized and free_aligned_sized, which we currently do not intercept. It's valid for an implementation to treat them exactly as it would treat calls to free.
Hey @godlygeek I'm interested in picking this up. Do you have any pointers.
I think that the best approach here is to add two new memray::intercept::free_sized and memray::intercept::free_aligned_sized functions in hooks.cpp, declare them and add them to MEMRAY_HOOKED_FUNCTIONS in hooks.h, and have the implementation in hooks.cpp just call memray::intercept::free. I think that might be all that's required to support these new deallocators.
Then, we'll need to add a new test that exercises these things. That test would need to be skipped if free_sized and free_aligned_sized aren't available, but otherwise that the test will call them from a test extension module and ensure that we get a FREE record recorded for them.
Alright. it's clearer now.