Hello,
Please take a look at the source code of the Delphi XE
DRWLock here:
https://sites.google.com/site/aminer68/scalable-distributed-reader-writer-mutex
I have delclared the following variables in LW_RWLockx.pas
"volatile" like this:
[Volatile] FCount1: PMyRecord1;
[Volatile] FCount2: PMyRecord2;
[Volatile] FCount3: PMyRecord3;
[Volatile] nbr: PMyRecord4;
And i have delclared the following variable in RWLockx.pas
"volatile" like this:
[Volatile] FCount1: PMyRecord1;
[Volatile] FCount2: PMyRecord2;
[Volatile] FCount3: PMyRecord3;
[Volatile] nbr: PMyRecord4;
[Volatile] nbr1: PMyRecord5;
So now you can be more confident of visibility accross cores.