mirror of
https://github.com/genodelabs/genode.git
synced 2025-04-20 09:02:09 +00:00
Mark packet-stream descriptor head/tail as volatile
`volatile` effectively prevents instruction reordering by the compiler and fixes an issue with -O3 compiled components. Note, this commit does not address further arguments regarding memory barriers and volatile voiced in issue #693. Issue #693
This commit is contained in:
parent
8d63a3c1f3
commit
9a35743df6
@ -168,8 +168,8 @@ class Genode::Packet_descriptor_queue
|
||||
*/
|
||||
struct
|
||||
{
|
||||
unsigned _head;
|
||||
unsigned _tail;
|
||||
unsigned volatile _head;
|
||||
unsigned volatile _tail;
|
||||
PACKET_DESCRIPTOR _queue[QUEUE_SIZE];
|
||||
};
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user