diff options
Diffstat (limited to 'libgomp/libgomp.h')
-rw-r--r-- | libgomp/libgomp.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/libgomp/libgomp.h b/libgomp/libgomp.h index ceef643..299cf42 100644 --- a/libgomp/libgomp.h +++ b/libgomp/libgomp.h @@ -95,6 +95,10 @@ enum memmodel #define GOMP_HAVE_EFFICIENT_ALIGNED_ALLOC 1 #endif +#if defined(GOMP_HAVE_EFFICIENT_ALIGNED_ALLOC) && !defined(__AMDGCN__) +#define GOMP_USE_ALIGNED_WORK_SHARES 1 +#endif + extern void *gomp_malloc (size_t) __attribute__((malloc)); extern void *gomp_malloc_cleared (size_t) __attribute__((malloc)); extern void *gomp_realloc (void *, size_t); @@ -348,7 +352,7 @@ struct gomp_work_share are in a different cache line. */ /* This lock protects the update of the following members. */ -#ifdef GOMP_HAVE_EFFICIENT_ALIGNED_ALLOC +#ifdef GOMP_USE_ALIGNED_WORK_SHARES gomp_mutex_t lock __attribute__((aligned (64))); #else char pad[64 - offsetof (struct gomp_work_share_1st_cacheline, pad)]; |