Revert "nir: Temporarily disable optimizations for MSVC ARM64"

This reverts commit 55d153b9f5.

The msvc bug is https://developercommunity.visualstudio.com/t/Stack-overflow-compiling-C-code-to-ARM64/916235

and Fixed In: Visual Studio 2022 version 17.7

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36767>
This commit is contained in:
Yonggang Luo
2025-08-13 02:34:31 +08:00
committed by Marge Bot
parent 85310e912c
commit a34756bbed
@@ -566,11 +566,6 @@ struct ${type}${width}_vec {
</%def>
% for name, op in sorted(opcodes.items()):
% if op.name == "fsat":
#if defined(_MSC_VER) && (defined(_M_ARM64) || defined(_M_ARM64EC))
#pragma optimize("", off) /* Temporary work-around for MSVC compiler bug, present in VS2019 16.9.2 */
#endif
% endif
static void
evaluate_${name}(nir_const_value *_dst_val,
UNUSED unsigned num_components,
@@ -594,11 +589,6 @@ evaluate_${name}(nir_const_value *_dst_val,
${evaluate_op(op, 0, execution_mode)}
% endif
}
% if op.name == "fsat":
#if defined(_MSC_VER) && (defined(_M_ARM64) || defined(_M_ARM64EC))
#pragma optimize("", on) /* Temporary work-around for MSVC compiler bug, present in VS2019 16.9.2 */
#endif
% endif
% endfor
void