nir: no-op C99 _Pragma() with MSVC

This fixes a build failure on MSVC.

BTW, it looks like clang supports _Pragma() but I don't know if it
understands the "gcc unroll N" directive.

Signed-off-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
This commit is contained in:
Brian Paul
2019-11-22 19:42:34 -07:00
parent 95fdde5a60
commit a2689ebcd6

View File

@@ -218,6 +218,13 @@ analyze_constant(const struct nir_alu_instr *instr, unsigned src,
*/
#define _______ unknown
/* MSVC doesn't have C99's _Pragma() */
#ifdef _MSC_VER
#define _Pragma(x)
#endif
#ifndef NDEBUG
#define ASSERT_TABLE_IS_COMMUTATIVE(t) \
do { \