st/mesa: try to fix MSVC build failure due to ALWAYS_INLINE
authorMarek Olšák <marek.olsak@amd.com>
Fri, 14 Feb 2020 21:53:42 +0000 (16:53 -0500)
committerMarek Olšák <marek.olsak@amd.com>
Tue, 18 Feb 2020 21:45:34 +0000 (16:45 -0500)
Fixes: 11db8e0e00a72884ba9f ("st/mesa: optimize st_update_array with ALWAYSINLINE")
Tested-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3861>

src/mesa/state_tracker/st_atom_array.c

index de03abea66d6ec685a7bc51b1dda4fe0655dc253..b4af4c3e6298525ab5fe6ec1cc9ea2c50ddb89a6 100644 (file)
@@ -125,7 +125,10 @@ init_velement(const struct st_vertex_program *vp,
 /* ALWAYS_INLINE helps the compiler realize that most of the parameters are
  * on the stack.
  */
-void ALWAYS_INLINE
+void
+#ifndef _MSC_VER /* MSVC doesn't like inlining public functions */
+ALWAYS_INLINE
+#endif
 st_setup_arrays(struct st_context *st,
                 const struct st_vertex_program *vp,
                 const struct st_common_variant *vp_variant,