Memory pool vectors (DVector) have been enormously simplified in code, and renamed to PoolVector

This commit is contained in:
Juan Linietsky
2017-01-07 18:25:37 -03:00
parent 2a38a5eaa8
commit 2ab83e1abb
257 changed files with 2818 additions and 3130 deletions

View File

@ -76,6 +76,9 @@ uint32_t atomic_decrement( register uint32_t * pw ) {
return InterlockedDecrement( (LONG volatile*)pw );
}
uint32_t atomic_increment( register uint32_t * pw ) {
return InterlockedIncrement( (LONG volatile*)pw );
}
#elif defined(__GNUC__)
uint32_t atomic_conditional_increment( register uint32_t * pw ) {
@ -95,6 +98,12 @@ uint32_t atomic_decrement( register uint32_t * pw ) {
}
uint32_t atomic_increment( register uint32_t * pw ) {
return __sync_add_and_fetch(pw,1);
}
#else
//no threads supported?
#error Must provide atomic functions for this platform or compiler!