jobsystem: group shared memory with thread_local instead of alloca
This commit is contained in:
@@ -348,7 +348,7 @@ namespace wi::audio
|
||||
{ XAUDIO2_SEND_USEFILTER, instanceinternal->audio->reverbSubmix }, // this should be last to enable/disable reverb simply
|
||||
};
|
||||
XAUDIO2_VOICE_SENDS SFXSendList = {
|
||||
instance->IsEnableReverb() ? arraysize(SFXSend) : 1,
|
||||
instance->IsEnableReverb() ? (uint32_t)arraysize(SFXSend) : 1,
|
||||
SFXSend
|
||||
};
|
||||
|
||||
|
||||
@@ -87,7 +87,9 @@ namespace wi::jobsystem
|
||||
args.groupID = job.groupID;
|
||||
if (job.sharedmemory_size > 0)
|
||||
{
|
||||
args.sharedmemory = alloca(job.sharedmemory_size);
|
||||
thread_local static wi::vector<uint8_t> shared_allocation_data;
|
||||
shared_allocation_data.reserve(job.sharedmemory_size);
|
||||
args.sharedmemory = shared_allocation_data.data();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -9,7 +9,7 @@ namespace wi::version
|
||||
// minor features, major updates, breaking compatibility changes
|
||||
const int minor = 60;
|
||||
// minor bug fixes, alterations, refactors, updates
|
||||
const int revision = 56;
|
||||
const int revision = 57;
|
||||
|
||||
const std::string version_string = std::to_string(major) + "." + std::to_string(minor) + "." + std::to_string(revision);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user