[libcxx-commits] [libcxx] fd11c81 - [libc++] Add `_LIBCPP_NO_CFI` to `__allocate_unique_temporary_buffer` (#109682)

via libcxx-commits libcxx-commits at lists.llvm.org
Mon Sep 23 18:29:38 PDT 2024


Author: A. Jiang
Date: 2024-09-24T09:29:34+08:00
New Revision: fd11c81a80608ddd4b33b664e28b426229aabde1

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

LOG: [libc++] Add `_LIBCPP_NO_CFI` to `__allocate_unique_temporary_buffer` (#109682)

Follows up #100914. Addresses the issue revealed in
https://github.com/llvm/llvm-project/pull/100914#discussion_r1771647801.

Added: 
    

Modified: 
    libcxx/include/__memory/unique_temporary_buffer.h

Removed: 
    


################################################################################
diff  --git a/libcxx/include/__memory/unique_temporary_buffer.h b/libcxx/include/__memory/unique_temporary_buffer.h
index b9e2a47332682f..001254e8fa4be1 100644
--- a/libcxx/include/__memory/unique_temporary_buffer.h
+++ b/libcxx/include/__memory/unique_temporary_buffer.h
@@ -47,7 +47,7 @@ template <class _Tp>
 using __unique_temporary_buffer = unique_ptr<_Tp, __temporary_buffer_deleter<_Tp> >;
 
 template <class _Tp>
-inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX23 __unique_temporary_buffer<_Tp>
+inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_NO_CFI _LIBCPP_CONSTEXPR_SINCE_CXX23 __unique_temporary_buffer<_Tp>
 __allocate_unique_temporary_buffer(ptr
diff _t __count) {
   using __deleter_type       = __temporary_buffer_deleter<_Tp>;
   using __unique_buffer_type = __unique_temporary_buffer<_Tp>;


        


More information about the libcxx-commits mailing list