From 38c4959f6c69e070d5a194a2a2e3746971e72512 Mon Sep 17 00:00:00 2001 From: Jason Volk Date: Sun, 1 Jan 2023 21:02:52 +0000 Subject: [PATCH] ircd::simt: Add macro to differentiate RDNA over GCN. --- include/ircd/simt/portable.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/include/ircd/simt/portable.h b/include/ircd/simt/portable.h index a781d3c77..5fd92f111 100644 --- a/include/ircd/simt/portable.h +++ b/include/ircd/simt/portable.h @@ -85,3 +85,13 @@ #define __SIZEOF_FLOAT16__ 64 #endif #endif + +// +// Differentiate RDNA over GCN +// + +#if defined(__AMDGCN__) && !defined(__AMDDNA__) + #if __AMDGCN_WAVEFRONT_SIZE == 32 + #define __AMDDNA__ 1 + #endif +#endif