PcloudStimProd: make sh_ptrs to Pcloud*StimBuff atomic<>
This change is a bit pedantic, but since these vars aren't accessed in any hotpath, it's fine to be pedantic. We made these sh_ptrs atomic so we can use acquire and release side effects when loading and storing them. This doesn't eliminate the problem of seeing inconsistent state across microcontrollers, but it helps with simple accesses like these ones we already do.
This commit is contained in:
@@ -91,9 +91,11 @@ public:
|
||||
StagingBuffer collationBuffer;
|
||||
size_t tempStimulusFrameMem;
|
||||
StimulusFrame tempStimulusFrame;
|
||||
std::shared_ptr<MeshStimulusBuffer> meshStimulusBuffer;
|
||||
std::shared_ptr<PcloudIntensityStimulusBuffer> intensityStimulusBuffer;
|
||||
std::shared_ptr<PcloudAmbienceStimulusBuffer> ambienceStimulusBuffer;
|
||||
std::atomic<std::shared_ptr<MeshStimulusBuffer>> meshStimulusBuffer;
|
||||
std::atomic<std::shared_ptr<PcloudIntensityStimulusBuffer>>
|
||||
intensityStimulusBuffer;
|
||||
std::atomic<std::shared_ptr<PcloudAmbienceStimulusBuffer>>
|
||||
ambienceStimulusBuffer;
|
||||
|
||||
private:
|
||||
class ProduceFrameReq;
|
||||
|
||||
Reference in New Issue
Block a user