From afebdda2031ca0a39f2816cf56388c04c63ed336 Mon Sep 17 00:00:00 2001 From: ReinUsesLisp Date: Wed, 11 Mar 2020 01:08:28 -0300 Subject: maxwell_3d: Add padding words to XFB entries Use INSERT_UNION_PADDING_WORDS instead of alignas to ensure a size requirement. --- src/video_core/engines/maxwell_3d.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/video_core/engines/maxwell_3d.h') diff --git a/src/video_core/engines/maxwell_3d.h b/src/video_core/engines/maxwell_3d.h index ba9c76593..8a9e9992e 100644 --- a/src/video_core/engines/maxwell_3d.h +++ b/src/video_core/engines/maxwell_3d.h @@ -628,12 +628,13 @@ public: float depth_range_far; }; - struct alignas(32) TransformFeedbackBinding { + struct TransformFeedbackBinding { u32 buffer_enable; u32 address_high; u32 address_low; s32 buffer_size; s32 buffer_offset; + INSERT_UNION_PADDING_WORDS(3); GPUVAddr Address() const { return static_cast((static_cast(address_high) << 32) | @@ -642,10 +643,11 @@ public: }; static_assert(sizeof(TransformFeedbackBinding) == 32); - struct alignas(16) TransformFeedbackLayout { + struct TransformFeedbackLayout { u32 stream; u32 varying_count; u32 stride; + INSERT_UNION_PADDING_WORDS(1); }; static_assert(sizeof(TransformFeedbackLayout) == 16); -- cgit v1.2.3