ETISS 0.8.0
Extendable Translating Instruction Set Simulator (version 0.8.0)
amxintrin.h
Go to the documentation of this file.
1 /*===--------------- amxintrin.h - AMX intrinsics -*- C/C++ -*---------------===
2  *
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
6  *
7  *===------------------------------------------------------------------------===
8  */
9 
10 #ifndef __IMMINTRIN_H
11 #error "Never use <amxintrin.h> directly; include <immintrin.h> instead."
12 #endif /* __IMMINTRIN_H */
13 
14 #ifndef __AMXINTRIN_H
15 #define __AMXINTRIN_H
16 #ifdef __x86_64__
17 
18 #define __DEFAULT_FN_ATTRS \
19  __attribute__((__always_inline__, __nodebug__, __target__("amx-tile")))
20 
34 static __inline__ void __DEFAULT_FN_ATTRS
35 _tile_loadconfig(const void *__config)
36 {
37  __builtin_ia32_tile_loadconfig(__config);
38 }
39 
51 static __inline__ void __DEFAULT_FN_ATTRS
52 _tile_storeconfig(void *__config)
53 {
54  __builtin_ia32_tile_storeconfig(__config);
55 }
56 
63 static __inline__ void __DEFAULT_FN_ATTRS
64 _tile_release(void)
65 {
66  __builtin_ia32_tilerelease();
67 }
68 
83 #define _tile_loadd(dst, base, stride) \
84  __builtin_ia32_tileloadd64((dst), ((const void *)(base)), (__SIZE_TYPE__)(stride))
85 
102 #define _tile_stream_loadd(dst, base, stride) \
103  __builtin_ia32_tileloaddt164((dst), ((const void *)(base)), (__SIZE_TYPE__)(stride))
104 
119 #define _tile_stored(dst, base, stride) \
120  __builtin_ia32_tilestored64((dst), ((void *)(base)), (__SIZE_TYPE__)(stride))
121 
130 #define _tile_zero(tile) __builtin_ia32_tilezero((tile))
131 
148 #define _tile_dpbssd(dst, src0, src1) __builtin_ia32_tdpbssd((dst), (src0), (src1))
149 
166 #define _tile_dpbsud(dst, src0, src1) __builtin_ia32_tdpbsud((dst), (src0), (src1))
167 
184 #define _tile_dpbusd(dst, src0, src1) __builtin_ia32_tdpbusd((dst), (src0), (src1))
185 
202 #define _tile_dpbuud(dst, src0, src1) __builtin_ia32_tdpbuud((dst), (src0), (src1))
203 
219 #define _tile_dpbf16ps(dst, src0, src1) \
220  __builtin_ia32_tdpbf16ps((dst), (src0), (src1))
221 
222 #undef __DEFAULT_FN_ATTRS
223 
224 #endif /* __x86_64__ */
225 #endif /* __AMXINTRIN_H */
#define __DEFAULT_FN_ATTRS