.iov_base = &x86_regs_union
};
#elif defined(IA64)
-long ia32 = 0; /* not static */
+bool ia64_ia32mode = 0; /* not static */
static long ia64_r8, ia64_r10;
#elif defined(POWERPC)
struct pt_regs ppc_regs;
# define IA64_PSR_IS ((long)1 << 34)
long psr;
if (upeek(tcp->pid, PT_CR_IPSR, &psr) >= 0)
- ia32 = (psr & IA64_PSR_IS) != 0;
- if (ia32) {
+ ia64_ia32mode = ((psr & IA64_PSR_IS) != 0);
+ if (ia64_ia32mode) {
if (upeek(tcp->pid, PT_R1, &scno) < 0)
return -1;
} else {
return -1;
if (upeek(tcp->pid, PT_R8, &ia64_r8) < 0)
return -1;
- if (ia32 && ia64_r8 != -ENOSYS) {
+ if (ia64_ia32mode && ia64_r8 != -ENOSYS) {
if (debug_flag)
fprintf(stderr, "not a syscall entry (r8 = %ld)\n", ia64_r8);
return 0;
if (upeek(tcp->pid, REG_A0+i, &tcp->u_arg[i]) < 0)
return -1;
#elif defined(IA64)
- if (!ia32) {
+ if (!ia64_ia32mode) {
unsigned long *out0, cfm, sof, sol;
long rbs_end;
/* be backwards compatible with kernel < 2.4.4... */
# define IA64_PSR_IS ((long)1 << 34)
long psr;
if (upeek(tcp->pid, PT_CR_IPSR, &psr) >= 0)
- ia32 = (psr & IA64_PSR_IS) != 0;
+ ia64_ia32mode = ((psr & IA64_PSR_IS) != 0);
if (upeek(tcp->pid, PT_R8, &ia64_r8) < 0)
return -1;
if (upeek(tcp->pid, PT_R10, &ia64_r10) < 0)
tcp->u_lrval = rax;
}
#elif defined(IA64)
- if (ia32) {
+ if (ia64_ia32mode) {
int err;
err = (int)ia64_r8;
unsigned long cfm, sof, sol;
long bsp;
- if (ia32) {
+ if (ia64_ia32mode) {
/* Satisfy a false GCC warning. */
*state = NULL;
return 0;
{
int ret;
- if (ia32)
+ if (ia64_ia32mode)
ret = upeek(tcp->pid, PT_R11, valp);
else
ret = umoven(tcp,
{
int ret;
- if (ia32)
+ if (ia64_ia32mode)
ret = upeek(tcp->pid, PT_R9, valp);
else
ret = umoven(tcp,
int req = PTRACE_POKEDATA;
void *ap;
- if (ia32) {
+ if (ia64_ia32mode) {
ap = (void *) (intptr_t) PT_R11; /* r11 == EBX */
req = PTRACE_POKEUSER;
} else
int req = PTRACE_POKEDATA;
void *ap;
- if (ia32) {
+ if (ia64_ia32mode) {
ap = (void *) (intptr_t) PT_R9; /* r9 == ECX */
req = PTRACE_POKEUSER;
} else
/* setbpt/clearbpt never used: */
/* Blackfin is only supported since about linux-2.6.23 */
#elif defined(IA64)
- if (ia32) {
+ if (ia64_ia32mode) {
switch (new) {
case 2:
break; /* x86 SYS_fork */