Skip to content

Commit

Permalink
Merge pull request #4477 from keithc-ca/fpc
Browse files Browse the repository at this point in the history
Fix read of FPC register
  • Loading branch information
fjeremic authored Jan 28, 2019
2 parents d7ff5a8 + befb88e commit b17263d
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions runtime/compiler/runtime/SignalHandler.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 2000, 2018 IBM Corp. and others
* Copyright (c) 2000, 2019 IBM Corp. and others
*
* This program and the accompanying materials are made available under
* the terms of the Eclipse Public License 2.0 which accompanies this
Expand Down Expand Up @@ -920,7 +920,6 @@ UDATA jit390Handler(J9VMThread* vmThread, U_32 sigType, void* sigInfo)
const char* infoName;
UDATA *controlPC;
UDATA controlPCValue;
UDATA *controlFPC;
UDATA *entryPointRegister;
U_8 DXC;
U_8 ILC;
Expand All @@ -941,13 +940,12 @@ UDATA jit390Handler(J9VMThread* vmThread, U_32 sigType, void* sigInfo)
controlPCValue = *controlPC;

infoType = j9sig_info(sigInfo, J9PORT_SIG_CONTROL, J9PORT_SIG_CONTROL_S390_FPC, &infoName, &infoValue);
if (infoType != J9PORT_SIG_VALUE_ADDRESS)
if (infoType != J9PORT_SIG_VALUE_32)
return J9PORT_SIG_EXCEPTION_CONTINUE_SEARCH;

controlFPC = (UDATA *) infoValue;
DXC = *(U_8 *)(((U_8 *)controlFPC)+2);
DXC = *(U_8 *)(((U_8 *)infoValue) + 2);

if (J9PORT_SIG_FLAG_SIGFPE == sigType && DXC == (U_8)0xFF)
if (J9PORT_SIG_FLAG_SIGFPE == sigType && DXC == (U_8)0xFF)
{
trapType = jit390IdentifyCodeCacheTrapType(vmThread, (U_8 *) controlPCValue, &ILC, sigInfo);
controlPCValue = controlPCValue - ILC;
Expand Down

0 comments on commit b17263d

Please sign in to comment.