From 3f94a793ae2db2e1d4c12a955eacbcacb49f6dba Mon Sep 17 00:00:00 2001 From: Florian Krohm Date: Thu, 3 May 2012 01:31:24 +0000 Subject: [PATCH] Add ETF3 facility (valgrind bits). Part of fixing Bugzilla #289839. Patch by Divya Vyas (divyvyas@linux.vnet.ibm.com) git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12550 --- coregrind/m_machine.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/coregrind/m_machine.c b/coregrind/m_machine.c index 82fd8a436e..ffe41ee713 100644 --- a/coregrind/m_machine.c +++ b/coregrind/m_machine.c @@ -1014,7 +1014,7 @@ Bool VG_(machine_get_hwcaps)( void ) vki_sigaction_toK_t tmp_sigill_act; volatile Bool have_LDISP, have_EIMM, have_GIE, have_DFP, have_FGX; - volatile Bool have_STFLE, have_ETF2; + volatile Bool have_STFLE, have_ETF2, have_ETF3; Int r, model; /* Unblock SIGILL and stash away the old action for that signal */ @@ -1087,6 +1087,7 @@ Bool VG_(machine_get_hwcaps)( void ) time, so the absence of STLFE implies the absence of ETF2. */ have_STFLE = True; have_ETF2 = False; + have_ETF3 = False; if (VG_MINIMAL_SETJMP(env_unsup_insn)) { have_STFLE = False; } else { @@ -1098,6 +1099,8 @@ Bool VG_(machine_get_hwcaps)( void ) : : "cc", "memory"); if (hoststfle[0] & (1ULL << (63 - 24))) have_ETF2 = True; + if (hoststfle[0] & (1ULL << (63 - 30))) + have_ETF3 = True; } /* Restore signals */ @@ -1114,8 +1117,8 @@ Bool VG_(machine_get_hwcaps)( void ) identification yet. Keeping fingers crossed. */ VG_(debugLog)(1, "machine", "machine %d LDISP %d EIMM %d GIE %d DFP %d " - "FGX %d STFLE %d ETF2 %d\n", model, have_LDISP, have_EIMM, - have_GIE, have_DFP, have_FGX, have_STFLE, have_ETF2); + "FGX %d STFLE %d ETF2 %d ETF3 %d\n", model, have_LDISP, have_EIMM, + have_GIE, have_DFP, have_FGX, have_STFLE, have_ETF2, have_ETF3); vai.hwcaps = model; if (have_LDISP) { @@ -1129,6 +1132,7 @@ Bool VG_(machine_get_hwcaps)( void ) if (have_DFP) vai.hwcaps |= VEX_HWCAPS_S390X_DFP; if (have_FGX) vai.hwcaps |= VEX_HWCAPS_S390X_FGX; if (have_ETF2) vai.hwcaps |= VEX_HWCAPS_S390X_ETF2; + if (have_ETF3) vai.hwcaps |= VEX_HWCAPS_S390X_ETF3; if (have_STFLE) vai.hwcaps |= VEX_HWCAPS_S390X_STFLE; VG_(debugLog)(1, "machine", "hwcaps = 0x%x\n", vai.hwcaps); -- 2.47.2