mirror of
https://github.com/KhronosGroup/SPIRV-Cross.git
synced 2024-11-08 13:20:06 +00:00
Don't add volatile to thread address space variables
This commit is contained in:
parent
670cc7fb1d
commit
467ba39110
@ -11,7 +11,7 @@ struct main0_out
|
||||
};
|
||||
|
||||
static inline __attribute__((always_inline))
|
||||
void func(thread float& FragColor, volatile thread bool& gl_HelperInvocation)
|
||||
void func(thread float& FragColor, thread bool& gl_HelperInvocation)
|
||||
{
|
||||
bool _14 = gl_HelperInvocation;
|
||||
float _17 = float(_14);
|
||||
|
@ -13213,7 +13213,10 @@ string CompilerMSL::get_type_address_space(const SPIRType &type, uint32_t id, bo
|
||||
addr_space = type.pointer || (argument && type.basetype == SPIRType::ControlPointArray) ? "thread" : "";
|
||||
}
|
||||
|
||||
return join(decoration_flags_signal_volatile(flags) ? "volatile " : "", addr_space);
|
||||
if (decoration_flags_signal_volatile(flags) && 0 != strcmp(addr_space, "thread"))
|
||||
return join("volatile ", addr_space);
|
||||
else
|
||||
return addr_space;
|
||||
}
|
||||
|
||||
const char *CompilerMSL::to_restrict(uint32_t id, bool space)
|
||||
|
Loading…
Reference in New Issue
Block a user