VirtualBox

Ignore:
Timestamp:
Jun 8, 2022 7:43:44 AM (3 years ago)
Author:
vboxsync
Message:

libs/openssl: Switched to v3.0.3, bugref:10128

Location:
trunk/src/libs/openssl-3.0.3
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/libs/openssl-3.0.3

    • Property svn:mergeinfo
      •  

        old new  
        1414/vendor/openssl/3.0.1:150323-150324
        1515/vendor/openssl/3.0.2:150728-150729
        16 /vendor/openssl/current:147554-150727
         16/vendor/openssl/3.0.3:151497-151729
         17/vendor/openssl/current:147554-151496
  • trunk/src/libs/openssl-3.0.3/crypto/threads_pthread.c

    r94404 r95219  
    1616#if defined(__sun)
    1717# include <atomic.h>
     18#endif
     19
     20#if defined(__apple_build_version__) && __apple_build_version__ < 6000000
     21/*
     22 * OS/X 10.7 and 10.8 had a weird version of clang which has __ATOMIC_ACQUIRE and
     23 * __ATOMIC_ACQ_REL but which expects only one parameter for __atomic_is_lock_free()
     24 * rather than two which has signature __atomic_is_lock_free(sizeof(_Atomic(T))).
     25 * All of this makes impossible to use __atomic_is_lock_free here.
     26 *
     27 * See: https://github.com/llvm/llvm-project/commit/a4c2602b714e6c6edb98164550a5ae829b2de760
     28 */
     29#define BROKEN_CLANG_ATOMICS
    1830#endif
    1931
     
    189201int CRYPTO_atomic_add(int *val, int amount, int *ret, CRYPTO_RWLOCK *lock)
    190202{
    191 # if defined(__GNUC__) && defined(__ATOMIC_ACQ_REL)
     203# if defined(__GNUC__) && defined(__ATOMIC_ACQ_REL) && !defined(BROKEN_CLANG_ATOMICS)
    192204    if (__atomic_is_lock_free(sizeof(*val), val)) {
    193205        *ret = __atomic_add_fetch(val, amount, __ATOMIC_ACQ_REL);
     
    216228                     CRYPTO_RWLOCK *lock)
    217229{
    218 # if defined(__GNUC__) && defined(__ATOMIC_ACQ_REL)
     230# if defined(__GNUC__) && defined(__ATOMIC_ACQ_REL) && !defined(BROKEN_CLANG_ATOMICS)
    219231    if (__atomic_is_lock_free(sizeof(*val), val)) {
    220232        *ret = __atomic_or_fetch(val, op, __ATOMIC_ACQ_REL);
     
    241253int CRYPTO_atomic_load(uint64_t *val, uint64_t *ret, CRYPTO_RWLOCK *lock)
    242254{
    243 # if defined(__GNUC__) && defined(__ATOMIC_ACQUIRE)
     255# if defined(__GNUC__) && defined(__ATOMIC_ACQUIRE) && !defined(BROKEN_CLANG_ATOMICS)
    244256    if (__atomic_is_lock_free(sizeof(*val), val)) {
    245257        __atomic_load(val, ret, __ATOMIC_ACQUIRE);
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette