From e391a281024a8f8283160b03aa3703405e037ed7 Mon Sep 17 00:00:00 2001 From: Pokechu22 Date: Mon, 23 Jan 2023 15:30:49 -0800 Subject: [PATCH] DSPTool: Generate an alignment specifier alignas is a C++ keyword since C++11, and can be used in C with a header too (although I don't know the details). --- Source/DSPTool/DSPTool.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/DSPTool/DSPTool.cpp b/Source/DSPTool/DSPTool.cpp index 46d71b4bf9..2f99d56522 100644 --- a/Source/DSPTool/DSPTool.cpp +++ b/Source/DSPTool/DSPTool.cpp @@ -68,7 +68,7 @@ static std::string CodeToHeader(const std::vector& code, const std::string& SplitPath(filename, nullptr, &filename_without_extension, nullptr); header.append(fmt::format("const char* UCODE_NAMES[NUM_UCODES] = {{\"{}\"}};\n\n", filename_without_extension)); - header.append("const unsigned short dsp_code[NUM_UCODES][0x1000] = {\n"); + header.append("alignas(0x20) const unsigned short dsp_code[NUM_UCODES][0x1000] = {\n"); header.append("\t{\n\t\t"); for (u32 j = 0; j < code_padded.size(); j++)