libagx: use native static_assert on host
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27616>
This commit is contained in:
committed by
Marge Bot
parent
bfaa3691e1
commit
fc929d9318
@@ -10,7 +10,8 @@
|
||||
#ifndef __OPENCL_VERSION__
|
||||
#include <stdint.h>
|
||||
#include "util/macros.h"
|
||||
#define GLOBAL(type_) uint64_t
|
||||
#define GLOBAL(type_) uint64_t
|
||||
#define AGX_STATIC_ASSERT(_COND) static_assert(_COND, "OpenCL assertion")
|
||||
#else
|
||||
#pragma OPENCL EXTENSION cl_khr_fp16 : enable
|
||||
#define PACKED
|
||||
@@ -37,9 +38,9 @@ uint32_t nir_load_helper_arg_lo_agx(void);
|
||||
uint32_t nir_load_helper_arg_hi_agx(void);
|
||||
uint32_t nir_fence_helper_exit_agx(void);
|
||||
|
||||
#endif
|
||||
|
||||
#define AGX_STATIC_ASSERT(_COND) \
|
||||
typedef char static_assertion_##__line__[(_COND) ? 1 : -1]
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user