X-Git-Url: http://drtracing.org/?a=blobdiff_plain;f=gdb%2Fi387-tdep.c;h=b7a9554d218fa5a0337a703731a4b28b5b2a6097;hb=b6ba6518e9254bc25f88088228e93ac966ebccd1;hp=f887da95b2617a77819b380c9249f03dee225e29;hpb=1d77867f997863c81debc79e048b0abffe2fe646;p=deliverable%2Fbinutils-gdb.git diff --git a/gdb/i387-tdep.c b/gdb/i387-tdep.c index f887da95b2..b7a9554d21 100644 --- a/gdb/i387-tdep.c +++ b/gdb/i387-tdep.c @@ -1,5 +1,6 @@ /* Intel 387 floating point stuff. - Copyright (C) 1988, 89, 91, 98, 99, 2000 Free Software Foundation, Inc. + Copyright 1988, 1989, 1991, 1992, 1993, 1994, 1998, 1999, 2000, 2001 + Free Software Foundation, Inc. This file is part of GDB. @@ -25,26 +26,23 @@ #include "value.h" #include "gdbcore.h" #include "floatformat.h" +#include "regcache.h" /* FIXME: Eliminate the next two functions when we have the time to change all the callers. */ -void i387_to_double PARAMS ((char *from, char *to)); -void double_to_i387 PARAMS ((char *from, char *to)); +void i387_to_double (char *from, char *to); +void double_to_i387 (char *from, char *to); void -i387_to_double (from, to) - char *from; - char *to; +i387_to_double (char *from, char *to) { floatformat_to_double (&floatformat_i387_ext, from, (double *) to); } void -double_to_i387 (from, to) - char *from; - char *to; +double_to_i387 (char *from, char *to) { floatformat_from_double (&floatformat_i387_ext, (double *) from, to); } @@ -56,12 +54,11 @@ double_to_i387 (from, to) use the generic implementation based on the new register file layout. */ -static void print_387_control_bits PARAMS ((unsigned int control)); -static void print_387_status_bits PARAMS ((unsigned int status)); +static void print_387_control_bits (unsigned int control); +static void print_387_status_bits (unsigned int status); static void -print_387_control_bits (control) - unsigned int control; +print_387_control_bits (unsigned int control) { switch ((control >> 8) & 3) { @@ -117,8 +114,7 @@ print_387_control_bits (control) } void -print_387_control_word (control) - unsigned int control; +print_387_control_word (unsigned int control) { printf_filtered ("control %s:", local_hex_string(control & 0xffff)); print_387_control_bits (control); @@ -126,8 +122,7 @@ print_387_control_word (control) } static void -print_387_status_bits (status) - unsigned int status; +print_387_status_bits (unsigned int status) { printf_unfiltered (" flags %d%d%d%d; ", (status & 0x4000) != 0, @@ -149,8 +144,7 @@ print_387_status_bits (status) } void -print_387_status_word (status) - unsigned int status; +print_387_status_word (unsigned int status) { printf_filtered ("status %s:", local_hex_string (status & 0xffff)); print_387_status_bits (status); @@ -176,7 +170,8 @@ print_i387_value (char *raw) { /* Copy straight over, but take care of the padding. */ memcpy (&value, raw, FPU_REG_RAW_SIZE); - memset (&value + FPU_REG_RAW_SIZE, 0, sizeof (value) - FPU_REG_RAW_SIZE); + memset ((char *) &value + FPU_REG_RAW_SIZE, 0, + sizeof (value) - FPU_REG_RAW_SIZE); } else #endif