1 /*===---------------- hresetintrin.h - HRESET intrinsics -------------------===
3 * Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 * See https://llvm.org/LICENSE.txt for license information.
5 * SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 *===-----------------------------------------------------------------------===
9 #ifndef __X86GPRINTRIN_H
10 #error "Never use <hresetintrin.h> directly; include <x86gprintrin.h> instead."
13 #ifndef __HRESETINTRIN_H
14 #define __HRESETINTRIN_H
16 #if __has_extension(gnu_asm)
18 /* Define the default attributes for the functions in this file. */
19 #define __DEFAULT_FN_ATTRS \
20 __attribute__((__always_inline__, __nodebug__, __target__("hreset")))
22 /// Provides a hint to the processor to selectively reset the prediction
23 /// history of the current logical processor specified by a 32-bit integer
26 /// This intrinsic corresponds to the <c> HRESET </c> instruction.
34 /// ResetPredictionFeature(i)
39 static __inline
void __DEFAULT_FN_ATTRS
42 __asm__ ("hreset $0" :: "a"(__eax
));
45 #undef __DEFAULT_FN_ATTRS
47 #endif /* __has_extension(gnu_asm) */
49 #endif /* __HRESETINTRIN_H */