zfs/include/os/freebsd
Richard Yao 0f03a41161
Use __attribute__((malloc)) on memory allocation functions
This informs the C compiler that pointers returned from these functions
do not alias other functions, which allows it to do better code
optimization and should make the compiled code smaller.

References:
https://stackoverflow.com/a/53654773
https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-malloc-function-attribute
https://clang.llvm.org/docs/AttributeReference.html#malloc

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Richard Yao <richard.yao@alumni.stonybrook.edu>
Closes #14827
2023-05-26 15:47:52 -07:00
..
linux Cleanup: Make memory barrier definitions consistent across kernels 2022-09-13 16:59:33 -07:00
spl Use __attribute__((malloc)) on memory allocation functions 2023-05-26 15:47:52 -07:00
zfs/sys Linux 6.3 compat: idmapped mount API changes 2023-04-10 14:15:36 -07:00
Makefile.am Add SHA2 SIMD feature tests for FreeBSD 2023-03-02 13:51:56 -08:00