100 int (*
process)(
const uint32_t
key,
const void *data,
void *user_data),
381#if((__has_feature(address_sanitizer) || defined(__SANITIZE_ADDRESS__)) && 1)
390# if defined(HAVE_THREAD_RWLOCK_ARCH_T_READERS)
391 if(entry->
lock.
lock.__data.__readers <= 1)
392# elif defined(HAVE_THREAD_RWLOCK_ARCH_T_NR_READERS)
393 if(entry->
lock.
lock.__data.__nr_readers <= 1)
395# error "No valid reader member"
425 entry->
cost = cost ? cost : data_size;
__DT_CLONE_TARGETS__ int process(struct dt_iop_module_t *self, const dt_dev_pixelpipe_t *pipe, const dt_dev_pixelpipe_iop_t *piece, const void *const ivoid, void *const ovoid)
typedef void((*dt_cache_allocate_t)(void *userdata, dt_cache_entry_t *entry))
#define ASAN_POISON_MEMORY_REGION(addr, size)
#define ASAN_UNPOISON_MEMORY_REGION(addr, size)
void * dt_alloc_align(size_t size)
static int dt_pthread_rwlock_unlock(dt_pthread_rwlock_t *rwlock)
static int dt_pthread_rwlock_tryrdlock(dt_pthread_rwlock_t *rwlock)
#define dt_pthread_rwlock_wrlock_with_caller(A, B, C)
#define dt_pthread_rwlock_trywrlock_with_caller(A, B, C)
#define dt_pthread_rwlock_tryrdlock_with_caller(A, B, C)
static int dt_pthread_mutex_unlock(dt_pthread_mutex_t *mutex) RELEASE(mutex) NO_THREAD_SAFETY_ANALYSIS
static int dt_pthread_rwlock_trywrlock(dt_pthread_rwlock_t *rwlock)
static int dt_pthread_mutex_init(dt_pthread_mutex_t *mutex, const pthread_mutexattr_t *mutexattr)
static int dt_pthread_rwlock_destroy(dt_pthread_rwlock_t *lock)
static int dt_pthread_mutex_destroy(dt_pthread_mutex_t *mutex)
static int dt_pthread_rwlock_init(dt_pthread_rwlock_t *lock, const pthread_rwlockattr_t *attr)
static int dt_pthread_mutex_lock(dt_pthread_mutex_t *mutex) ACQUIRE(mutex) NO_THREAD_SAFETY_ANALYSIS
#define dt_pthread_rwlock_rdlock_with_caller(A, B, C)
#define IS_NULL_PTR(p)
C is way too permissive with !=, == and if(var) checks, which can mean too many things depending on w...
#define dt_free_align(ptr)
static const dt_aligned_pixel_simd_t value
int32_t dt_cache_contains(dt_cache_t *cache, const uint32_t key)
int dt_cache_seed(dt_cache_t *cache, const uint32_t key, const void *data, size_t data_size, size_t cost, gboolean aligned_alloc)
void dt_cache_entry_free_detached(dt_cache_entry_t *entry)
Release an entry from dt_cache_entry_new_detached(), and its data. NULL-safe.
void dt_cache_gc(dt_cache_t *cache, const float fill_ratio)
void dt_cache_release_with_caller(dt_cache_t *cache, dt_cache_entry_t *entry, const char *file, int line)
dt_cache_entry_t * dt_cache_testget(dt_cache_t *cache, const uint32_t key, char mode)
dt_cache_entry_t * dt_cache_entry_new_detached(void)
Allocate a cache entry that belongs to NO cache, for a one-shot decode.
void dt_cache_init(dt_cache_t *cache, size_t entry_size, size_t cost_quota)
dt_cache_entry_t * dt_cache_get_with_caller(dt_cache_t *cache, const uint32_t key, char mode, const char *file, int line)
int dt_cache_remove(dt_cache_t *cache, const uint32_t key)
int dt_cache_for_all(dt_cache_t *cache, int(*process)(const uint32_t key, const void *data, void *user_data), void *user_data)
void dt_cache_cleanup(dt_cache_t *cache)
dt_cache_allocate_t allocate
dt_cache_allocate_t cleanup