ck_pr: Fallback to RMO for PSO for this release.

Barriers can be rejiggered next release.
ck_pring
Samy Al Bahra 12 years ago
parent ac50efbeaf
commit 3f217c9789

@ -55,7 +55,7 @@ ck_pr_stall(void)
return; return;
} }
#ifdef CK_MD_RMO #if defined(CK_MD_RMO) || defined(CK_MD_PSO)
#define CK_PR_FENCE(T, I) \ #define CK_PR_FENCE(T, I) \
CK_CC_INLINE static void \ CK_CC_INLINE static void \
ck_pr_fence_strict_##T(void) \ ck_pr_fence_strict_##T(void) \
@ -77,7 +77,7 @@ ck_pr_stall(void)
{ \ { \
__asm__ __volatile__("" ::: "memory"); \ __asm__ __volatile__("" ::: "memory"); \
} }
#endif /* !CK_MD_RMO */ #endif /* !CK_MD_RMO && !CK_MD_PSO */
CK_PR_FENCE(load_depends, "") CK_PR_FENCE(load_depends, "")
CK_PR_FENCE(store, "eieio") CK_PR_FENCE(store, "eieio")

@ -54,7 +54,7 @@ ck_pr_stall(void)
return; return;
} }
#if defined(CK_MD_RMO) #if defined(CK_MD_RMO) || defined(CK_MD_PSO)
#define CK_PR_FENCE(T, I) \ #define CK_PR_FENCE(T, I) \
CK_CC_INLINE static void \ CK_CC_INLINE static void \
ck_pr_fence_strict_##T(void) \ ck_pr_fence_strict_##T(void) \
@ -76,7 +76,7 @@ ck_pr_stall(void)
{ \ { \
__asm__ __volatile__("" ::: "memory"); \ __asm__ __volatile__("" ::: "memory"); \
} }
#endif /* !CK_MD_RMO */ #endif /* !CK_MD_RMO && !CK_MD_PSO */
CK_PR_FENCE(load_depends, "") CK_PR_FENCE(load_depends, "")
CK_PR_FENCE(store, "eieio") CK_PR_FENCE(store, "eieio")

@ -51,9 +51,9 @@ ck_pr_stall(void)
return; return;
} }
#ifndef CK_MD_RMO #if defined(CK_MD_RMO) || defined(CK_MD_PSO)
/* /*
* By default, we will assume TSO model is used on SPARCv9. * If RMO is forced, then do not assume TSO model.
*/ */
#define CK_PR_FENCE(T, I) \ #define CK_PR_FENCE(T, I) \
CK_CC_INLINE static void \ CK_CC_INLINE static void \
@ -63,11 +63,11 @@ ck_pr_stall(void)
} \ } \
CK_CC_INLINE static void ck_pr_fence_##T(void) \ CK_CC_INLINE static void ck_pr_fence_##T(void) \
{ \ { \
__asm__ __volatile__("" ::: "memory"); \ __asm__ __volatile__(I ::: "memory"); \
} }
#else #else
/* /*
* If RMO is forced, then do not assume TSO model. * By default, we will assume TSO model is used on SPARCv9.
*/ */
#define CK_PR_FENCE(T, I) \ #define CK_PR_FENCE(T, I) \
CK_CC_INLINE static void \ CK_CC_INLINE static void \
@ -77,9 +77,9 @@ ck_pr_stall(void)
} \ } \
CK_CC_INLINE static void ck_pr_fence_##T(void) \ CK_CC_INLINE static void ck_pr_fence_##T(void) \
{ \ { \
__asm__ __volatile__(I ::: "memory"); \ __asm__ __volatile__("" ::: "memory"); \
} }
#endif /* CK_MD_RMO */ #endif /* !CK_MD_RMO && !CK_MD_PSO */
CK_PR_FENCE(load_depends, "") CK_PR_FENCE(load_depends, "")
CK_PR_FENCE(store, "membar #StoreStore") CK_PR_FENCE(store, "membar #StoreStore")

@ -63,7 +63,7 @@ ck_pr_stall(void)
return; return;
} }
#ifdef CK_MD_RMO #if defined(CK_MD_RMO) || defined(CK_MD_PSO)
#define CK_PR_FENCE(T, I) \ #define CK_PR_FENCE(T, I) \
CK_CC_INLINE static void \ CK_CC_INLINE static void \
ck_pr_fence_strict_##T(void) \ ck_pr_fence_strict_##T(void) \
@ -92,7 +92,7 @@ ck_pr_stall(void)
{ \ { \
__asm__ __volatile__("" ::: "memory"); \ __asm__ __volatile__("" ::: "memory"); \
} }
#endif /* !CK_MD_RMO */ #endif /* !CK_MD_RMO && !CK_MD_PSO */
CK_PR_FENCE(load, "lfence") CK_PR_FENCE(load, "lfence")
CK_PR_FENCE(load_depends, "") CK_PR_FENCE(load_depends, "")

@ -62,7 +62,7 @@ ck_pr_stall(void)
return; return;
} }
#ifdef CK_MD_RMO #if defined(CK_MD_RMO) || defined(CK_MD_PSO)
#define CK_PR_FENCE(T, I) \ #define CK_PR_FENCE(T, I) \
CK_CC_INLINE static void \ CK_CC_INLINE static void \
ck_pr_fence_strict_##T(void) \ ck_pr_fence_strict_##T(void) \
@ -91,7 +91,7 @@ ck_pr_stall(void)
{ \ { \
__asm__ __volatile__("" ::: "memory"); \ __asm__ __volatile__("" ::: "memory"); \
} }
#endif /* !CK_MD_RMO */ #endif /* !CK_MD_RMO && !CK_MD_PSO */
CK_PR_FENCE(load, "lfence") CK_PR_FENCE(load, "lfence")
CK_PR_FENCE(load_depends, "") CK_PR_FENCE(load_depends, "")

Loading…
Cancel
Save