summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libitm/ChangeLog8
-rw-r--r--libitm/beginend.cc6
-rw-r--r--libitm/config/s390/target.h3
3 files changed, 17 insertions, 0 deletions
diff --git a/libitm/ChangeLog b/libitm/ChangeLog
index 2a3554fd6af1..42b47762b9f7 100644
--- a/libitm/ChangeLog
+++ b/libitm/ChangeLog
@@ -1,3 +1,11 @@
+2016-03-03 Dominik Vogt <vogt@linux.vnet.ibm.com>
+
+ * config/s390/target.h (TARGET_BEGIN_TRANSACTION_ATTRIBUTE): Define
+ function attribute to disable floating point in begin_transaction() on
+ S/390.
+ * beginend.cc (begin_transaction): Use
+ TARGET_BEGIN_TRANSACTION_ATTRIBUTE.
+
2016-01-22 Torvald Riegel <triegel@redhat.com>
* beginend.cc (GTM::gtm_thread::serial_lock): Put on cacheline
diff --git a/libitm/beginend.cc b/libitm/beginend.cc
index 1a258ad7965e..20b5547c30d8 100644
--- a/libitm/beginend.cc
+++ b/libitm/beginend.cc
@@ -149,6 +149,12 @@ choose_code_path(uint32_t prop, abi_dispatch *disp)
return a_runInstrumentedCode;
}
+#ifdef TARGET_BEGIN_TRANSACTION_ATTRIBUTE
+/* This macro can be used to define target specific attributes for this
+ function. For example, S/390 requires floating point to be disabled in
+ begin_transaction. */
+TARGET_BEGIN_TRANSACTION_ATTRIBUTE
+#endif
uint32_t
GTM::gtm_thread::begin_transaction (uint32_t prop, const gtm_jmpbuf *jb)
{
diff --git a/libitm/config/s390/target.h b/libitm/config/s390/target.h
index 44819a4d244f..c9d52034d1aa 100644
--- a/libitm/config/s390/target.h
+++ b/libitm/config/s390/target.h
@@ -69,6 +69,9 @@ cpu_relax (void)
/* Number of retries for transient failures. */
#define _HTM_ITM_RETRIES 10
#define USE_HTM_FASTPATH
+#define TARGET_BEGIN_TRANSACTION_ATTRIBUTE \
+ __attribute__ ((target("soft-float")))
+
static inline bool
htm_available ()