Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add compatibility with GCC <= 11.2 & Clang 10 #4

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions include-gcc/mwaitintrin.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,13 @@
#ifndef _MWAITINTRIN_H_INCLUDED
#define _MWAITINTRIN_H_INCLUDED

#if ((__GNUC__ >= 12) || (__GNUC__ == 11 && __GNUC_MINOR__ >= 3))
#ifndef __MWAIT__
#pragma GCC push_options
#pragma GCC target("mwait")
#define __DISABLE_MWAIT__
#endif /* __MWAIT__ */
#endif /* GCC >= 11.3 */

extern __inline void
__attribute__((__gnu_inline__, __always_inline__, __artificial__))
Expand Down
4 changes: 4 additions & 0 deletions include-llvm/immintrin.h
Original file line number Diff line number Diff line change
Expand Up @@ -509,10 +509,12 @@ _storebe_i64(void * __P, long long __D) {
#endif
#endif

#if (__clang_major__ >= 11)
#if !(defined(_MSC_VER) || defined(__SCE__)) || __has_feature(modules) || \
defined(__AMXTILE__) || defined(__AMXINT8__) || defined(__AMXBF16__)
#include <amxintrin.h>
#endif
#endif

#if !(defined(_MSC_VER) || defined(__SCE__)) || __has_feature(modules) || \
defined(__AVX512VP2INTERSECT__)
Expand All @@ -529,6 +531,7 @@ _storebe_i64(void * __P, long long __D) {
#include <enqcmdintrin.h>
#endif

#if (__clang_major__ >= 11)
#if !(defined(_MSC_VER) || defined(__SCE__)) || __has_feature(modules) || \
defined(__SERIALIZE__)
#include <serializeintrin.h>
Expand All @@ -538,6 +541,7 @@ _storebe_i64(void * __P, long long __D) {
defined(__TSXLDTRK__)
#include <tsxldtrkintrin.h>
#endif
#endif

#if defined(_MSC_VER) && __has_extension(gnu_asm)
/* Define the default attributes for these intrinsics */
Expand Down