From 4214561c97dd0edb50fd52e217cd2915454893cc Mon Sep 17 00:00:00 2001 From: Samy Al Bahra Date: Sat, 14 Mar 2015 21:47:13 -0400 Subject: [PATCH] ck_pr: (Re-)introduce ck_pr_rfo. This was accidentally grouped into previous commit. The destiny of this interface for internal use is still unclear (in context of utilization in built-in data structures). The interface is enabled by default on x86, as it is compatible with read-side prefetch* operations and binary-compatible with 3DNow! extension. Older compilers will waste an additional byte (they generate 3DNow! variant) on this, but older compilers waste more on spillage if we encode instruction. Power support is coming soon. --- configure | 7 ------- include/ck_md.h.in | 4 ---- include/gcc/x86_64/ck_pr.h | 4 ++-- 3 files changed, 2 insertions(+), 13 deletions(-) diff --git a/configure b/configure index 7673b4d..185ecba 100755 --- a/configure +++ b/configure @@ -103,7 +103,6 @@ generate() -e "s#@GZIP_SUFFIX@#$GZIP_SUFFIX#g" \ -e "s#@POINTER_PACK_ENABLE@#$POINTER_PACK_ENABLE#g" \ -e "s#@RTM_ENABLE@#$RTM_ENABLE#g" \ - -e "s#@RFO_ENABLE@#$RFO_ENABLE#g" \ -e "s#@VMA_BITS@#$VMA_BITS_R#g" \ -e "s#@VMA_BITS_VALUE@#$VMA_BITS_VALUE_R#g" \ -e "s#@MM@#$MM#g" \ @@ -138,7 +137,6 @@ generate_stdout() echo " POINTER_PACK = $POINTER_PACK_ENABLE" echo " VMA_BITS = $VMA_BITS" echo " MEMORY_MODEL = $MM" - echo " RFO = $RFO_ENABLE" echo " RTM = $RTM_ENABLE" echo echo "Headers will be installed in $HEADERS" @@ -175,7 +173,6 @@ for option; do echo "The following options will affect generated code." echo " --enable-pointer-packing Assumes address encoding is subset of pointer range" echo " --enable-rtm Enable restricted transactional memory (power, x86_64)" - echo " --enable-rfo Enable read-for-ownership interface (power, x86_64)" echo " --memory-model=N Specify memory model (currently tso, pso or rmo)" echo " --vma-bits=N Specify valid number of VMA bits" echo @@ -217,9 +214,6 @@ for option; do --enable-rtm) RTM_ENABLE_SET="CK_MD_RTM_ENABLE" ;; - --enable-rfo) - RFO_ENABLE_SET="CK_MD_RFO_ENABLE" - ;; --cores=*) CORES=$value ;; @@ -280,7 +274,6 @@ MANDIR=${MANDIR:-"${PREFIX}/share/man"} GZIP=${GZIP:-"gzip -c"} POINTER_PACK_ENABLE=${POINTER_PACK_ENABLE:-"CK_MD_POINTER_PACK_DISABLE"} RTM_ENABLE=${RTM_ENABLE_SET:-"CK_MD_RTM_DISABLE"} -RFO_ENABLE=${RFO_ENABLE_SET:-"CK_MD_RFO_DISABLE"} VMA_BITS=${VMA_BITS:-"unknown"} if test "$PROFILE"; then diff --git a/include/ck_md.h.in b/include/ck_md.h.in index 63cbbf0..4449cf8 100644 --- a/include/ck_md.h.in +++ b/include/ck_md.h.in @@ -39,10 +39,6 @@ #define @RTM_ENABLE@ #endif /* @RTM_ENABLE@ */ -#ifndef @RFO_ENABLE@ -#define @RFO_ENABLE@ -#endif /* @RFO_ENABLE@ */ - #ifndef @POINTER_PACK_ENABLE@ #define @POINTER_PACK_ENABLE@ #endif /* @POINTER_PACK_ENABLE@ */ diff --git a/include/gcc/x86_64/ck_pr.h b/include/gcc/x86_64/ck_pr.h index b57a845..1a71d31 100644 --- a/include/gcc/x86_64/ck_pr.h +++ b/include/gcc/x86_64/ck_pr.h @@ -96,7 +96,7 @@ CK_PR_FENCE(acquire, "mfence") * 3DNow! variant which is binary compatible with x86-64 variant * of prefetchw. */ -#ifdef CK_MD_RFO_ENABLE +#ifndef CK_F_PR_RFO #define CK_F_PR_RFO CK_CC_INLINE static void ck_pr_rfo(const void *m) @@ -109,7 +109,7 @@ ck_pr_rfo(const void *m) return; } -#endif /* CD_MD_PREFETCHW_ENABLE */ +#endif /* CK_F_PR_RFO */ /* * Atomic fetch-and-store operations.