summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUlrich Weigand <ulrich.weigand@de.ibm.com>2017-10-05 19:12:45 +0200
committerUlrich Weigand <ulrich.weigand@de.ibm.com>2017-10-05 19:12:45 +0200
commit1841ee5d0300cf00022c8aadfe16725c5e86fe1d (patch)
tree3c3f8fa6bf0c40ed7b2fe1019dd9af3d3d50cb9b
parenta80a647180bf92692e0f01efe7b323afe7d317c9 (diff)
Clean up includes of doublest.h and floatformat.h
As a first small step to getting rid of doublest.h, this patch removes the include of "floatformat.h" in "doublest.h". This is actually not needed for the file itself. A few source files now need to include "floatformat.h" directly, since they got it indirectly via "doublest.h" and still need it. In reviewing which files need it, I found a number of files that include "floatformat.h" directly without actually needing it at all. Similarly, a number of files include "doublest.h" without needing it. I've also removed those unnecessary include statements. gdb/ChangeLog: 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com> * doublest.h: Do not include "floatformat.h". Remove stale comments. * gdbtypes.c: Include "floatformat.h". * value.c: Likewise. * m68k-tdep.c: Likewise. * findvar.c: Do not include "floatformat.h". * amd64-darwin-tdep.c: Likewise. * arm-linux-tdep.c: Likewise. * i386-darwin-tdep.c: Likewise. * i387-tdep.c: Likewise. * m68k-linux-tdep.c: Likewise. * mep-tdep.c: Likewise. * mips-tdep.c: Likewise. * nios2-tdep.c: Likewise. * s390-linux-tdep.c: Likewise. * sparc-obsd-tdep.c: Likewise. * sparc-tdep.c: Likewise. * sparc64-tdep.c: Likewise. * spu-tdep.c: Likewise. * tic6x-tdep.c: Likewise. * tilegx-tdep.c: Likewise. * vax-tdep.c: Likewise. * xstormy16-tdep.c: Likewise. * xtensa-tdep.c: Likewise. * top.c: Do not include "doublest.h". * aarch64-tdep.c: Likewise. * alpha-tdep.c: Likewise. * arm-linux-tdep.c: Likewise. * m68k-linux-tdep.c: Likewise. * tilegx-tdep.c: Likewise. * xstormy16-tdep.c: Likewise.
-rw-r--r--gdb/ChangeLog35
-rw-r--r--gdb/aarch64-tdep.c1
-rw-r--r--gdb/alpha-tdep.c1
-rw-r--r--gdb/amd64-darwin-tdep.c1
-rw-r--r--gdb/arm-linux-tdep.c2
-rw-r--r--gdb/doublest.h12
-rw-r--r--gdb/findvar.c1
-rw-r--r--gdb/gdbtypes.c1
-rw-r--r--gdb/i386-darwin-tdep.c1
-rw-r--r--gdb/i387-tdep.c1
-rw-r--r--gdb/m68k-linux-tdep.c2
-rw-r--r--gdb/m68k-tdep.c1
-rw-r--r--gdb/mep-tdep.c1
-rw-r--r--gdb/mips-tdep.c1
-rw-r--r--gdb/nios2-tdep.c1
-rw-r--r--gdb/s390-linux-tdep.c1
-rw-r--r--gdb/sparc-obsd-tdep.c1
-rw-r--r--gdb/sparc-tdep.c1
-rw-r--r--gdb/sparc64-tdep.c1
-rw-r--r--gdb/spu-tdep.c1
-rw-r--r--gdb/tic6x-tdep.c1
-rw-r--r--gdb/tilegx-tdep.c2
-rw-r--r--gdb/top.c1
-rw-r--r--gdb/value.c1
-rw-r--r--gdb/vax-tdep.c1
-rw-r--r--gdb/xstormy16-tdep.c2
-rw-r--r--gdb/xtensa-tdep.c1
27 files changed, 38 insertions, 38 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 024664f041..5439ffb284 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,38 @@
+2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
+
+ * doublest.h: Do not include "floatformat.h". Remove stale comments.
+ * gdbtypes.c: Include "floatformat.h".
+ * value.c: Likewise.
+ * m68k-tdep.c: Likewise.
+
+ * findvar.c: Do not include "floatformat.h".
+ * amd64-darwin-tdep.c: Likewise.
+ * arm-linux-tdep.c: Likewise.
+ * i386-darwin-tdep.c: Likewise.
+ * i387-tdep.c: Likewise.
+ * m68k-linux-tdep.c: Likewise.
+ * mep-tdep.c: Likewise.
+ * mips-tdep.c: Likewise.
+ * nios2-tdep.c: Likewise.
+ * s390-linux-tdep.c: Likewise.
+ * sparc-obsd-tdep.c: Likewise.
+ * sparc-tdep.c: Likewise.
+ * sparc64-tdep.c: Likewise.
+ * spu-tdep.c: Likewise.
+ * tic6x-tdep.c: Likewise.
+ * tilegx-tdep.c: Likewise.
+ * vax-tdep.c: Likewise.
+ * xstormy16-tdep.c: Likewise.
+ * xtensa-tdep.c: Likewise.
+
+ * top.c: Do not include "doublest.h".
+ * aarch64-tdep.c: Likewise.
+ * alpha-tdep.c: Likewise.
+ * arm-linux-tdep.c: Likewise.
+ * m68k-linux-tdep.c: Likewise.
+ * tilegx-tdep.c: Likewise.
+ * xstormy16-tdep.c: Likewise.
+
2017-10-05 John Baldwin <jhb@FreeBSD.org>
* mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
diff --git a/gdb/aarch64-tdep.c b/gdb/aarch64-tdep.c
index da5731e783..e74b7cd370 100644
--- a/gdb/aarch64-tdep.c
+++ b/gdb/aarch64-tdep.c
@@ -27,7 +27,6 @@
#include "dis-asm.h"
#include "regcache.h"
#include "reggroups.h"
-#include "doublest.h"
#include "value.h"
#include "arch-utils.h"
#include "osabi.h"
diff --git a/gdb/alpha-tdep.c b/gdb/alpha-tdep.c
index e66517d21c..89556956ab 100644
--- a/gdb/alpha-tdep.c
+++ b/gdb/alpha-tdep.c
@@ -18,7 +18,6 @@
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#include "defs.h"
-#include "doublest.h"
#include "frame.h"
#include "frame-unwind.h"
#include "frame-base.h"
diff --git a/gdb/amd64-darwin-tdep.c b/gdb/amd64-darwin-tdep.c
index 7f6cb94ad6..384d20944b 100644
--- a/gdb/amd64-darwin-tdep.c
+++ b/gdb/amd64-darwin-tdep.c
@@ -23,7 +23,6 @@
#include "inferior.h"
#include "gdbcore.h"
#include "target.h"
-#include "floatformat.h"
#include "symtab.h"
#include "regcache.h"
#include "objfiles.h"
diff --git a/gdb/arm-linux-tdep.c b/gdb/arm-linux-tdep.c
index 72b91d4f2e..056c1b9421 100644
--- a/gdb/arm-linux-tdep.c
+++ b/gdb/arm-linux-tdep.c
@@ -21,11 +21,9 @@
#include "target.h"
#include "value.h"
#include "gdbtypes.h"
-#include "floatformat.h"
#include "gdbcore.h"
#include "frame.h"
#include "regcache.h"
-#include "doublest.h"
#include "solib-svr4.h"
#include "osabi.h"
#include "regset.h"
diff --git a/gdb/doublest.h b/gdb/doublest.h
index a22baef89e..74d0572912 100644
--- a/gdb/doublest.h
+++ b/gdb/doublest.h
@@ -23,18 +23,6 @@
struct type;
struct floatformat;
-/* Setup definitions for host and target floating point formats. We need to
- consider the format for `float', `double', and `long double' for both target
- and host. We need to do this so that we know what kind of conversions need
- to be done when converting target numbers to and from the hosts DOUBLEST
- data type. */
-
-/* This is used to indicate that we don't know the format of the floating point
- number. Typically, this is useful for native ports, where the actual format
- is irrelevant, since no conversions will be taking place. */
-
-#include "floatformat.h" /* For struct floatformat */
-
/* Use `long double' if the host compiler supports it. (Note that this is not
necessarily any longer than `double'. On SunOS/gcc, it's the same as
double.) This is necessary because GDB internally converts all floating
diff --git a/gdb/findvar.c b/gdb/findvar.c
index b3fb337f77..2bc2095bf7 100644
--- a/gdb/findvar.c
+++ b/gdb/findvar.c
@@ -25,7 +25,6 @@
#include "gdbcore.h"
#include "inferior.h"
#include "target.h"
-#include "floatformat.h"
#include "symfile.h" /* for overlay functions */
#include "regcache.h"
#include "user-regs.h"
diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
index 57bc218d91..73d445361d 100644
--- a/gdb/gdbtypes.c
+++ b/gdb/gdbtypes.c
@@ -38,6 +38,7 @@
#include "bcache.h"
#include "dwarf2loc.h"
#include "gdbcore.h"
+#include "floatformat.h"
/* Initialize BADNESS constants. */
diff --git a/gdb/i386-darwin-tdep.c b/gdb/i386-darwin-tdep.c
index a888e10c89..c642040432 100644
--- a/gdb/i386-darwin-tdep.c
+++ b/gdb/i386-darwin-tdep.c
@@ -23,7 +23,6 @@
#include "inferior.h"
#include "gdbcore.h"
#include "target.h"
-#include "floatformat.h"
#include "symtab.h"
#include "regcache.h"
#include "objfiles.h"
diff --git a/gdb/i387-tdep.c b/gdb/i387-tdep.c
index 574914cab7..3de7c62f4a 100644
--- a/gdb/i387-tdep.c
+++ b/gdb/i387-tdep.c
@@ -19,7 +19,6 @@
#include "defs.h"
#include "doublest.h"
-#include "floatformat.h"
#include "frame.h"
#include "gdbcore.h"
#include "inferior.h"
diff --git a/gdb/m68k-linux-tdep.c b/gdb/m68k-linux-tdep.c
index fa0848f453..c911f2d4ac 100644
--- a/gdb/m68k-linux-tdep.c
+++ b/gdb/m68k-linux-tdep.c
@@ -19,8 +19,6 @@
#include "defs.h"
#include "gdbcore.h"
-#include "doublest.h"
-#include "floatformat.h"
#include "frame.h"
#include "target.h"
#include "gdbtypes.h"
diff --git a/gdb/m68k-tdep.c b/gdb/m68k-tdep.c
index ce126a8b81..37df9d5f27 100644
--- a/gdb/m68k-tdep.c
+++ b/gdb/m68k-tdep.c
@@ -32,6 +32,7 @@
#include "osabi.h"
#include "dis-asm.h"
#include "target-descriptions.h"
+#include "floatformat.h"
#include "m68k-tdep.h"
diff --git a/gdb/mep-tdep.c b/gdb/mep-tdep.c
index fffd40569c..623ab7f42f 100644
--- a/gdb/mep-tdep.c
+++ b/gdb/mep-tdep.c
@@ -36,7 +36,6 @@
#include "arch-utils.h"
#include "regcache.h"
#include "remote.h"
-#include "floatformat.h"
#include "sim-regno.h"
#include "disasm.h"
#include "trad-frame.h"
diff --git a/gdb/mips-tdep.c b/gdb/mips-tdep.c
index 5fc0618787..05d7ae1e87 100644
--- a/gdb/mips-tdep.c
+++ b/gdb/mips-tdep.c
@@ -49,7 +49,6 @@
#include "frame-base.h"
#include "trad-frame.h"
#include "infcall.h"
-#include "floatformat.h"
#include "remote.h"
#include "target-descriptions.h"
#include "dwarf2-frame.h"
diff --git a/gdb/nios2-tdep.c b/gdb/nios2-tdep.c
index 4ad49aef05..cf60337627 100644
--- a/gdb/nios2-tdep.c
+++ b/gdb/nios2-tdep.c
@@ -37,7 +37,6 @@
#include "value.h"
#include "symfile.h"
#include "arch-utils.h"
-#include "floatformat.h"
#include "infcall.h"
#include "regset.h"
#include "target-descriptions.h"
diff --git a/gdb/s390-linux-tdep.c b/gdb/s390-linux-tdep.c
index a6a6d5d978..dfc7404f4b 100644
--- a/gdb/s390-linux-tdep.c
+++ b/gdb/s390-linux-tdep.c
@@ -30,7 +30,6 @@
#include "gdbcore.h"
#include "gdbcmd.h"
#include "objfiles.h"
-#include "floatformat.h"
#include "regcache.h"
#include "trad-frame.h"
#include "frame-base.h"
diff --git a/gdb/sparc-obsd-tdep.c b/gdb/sparc-obsd-tdep.c
index fbe5aab795..d495f714b2 100644
--- a/gdb/sparc-obsd-tdep.c
+++ b/gdb/sparc-obsd-tdep.c
@@ -18,7 +18,6 @@
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#include "defs.h"
-#include "floatformat.h"
#include "frame.h"
#include "frame-unwind.h"
#include "gdbcore.h"
diff --git a/gdb/sparc-tdep.c b/gdb/sparc-tdep.c
index 8bb69f5e36..353b33cf59 100644
--- a/gdb/sparc-tdep.c
+++ b/gdb/sparc-tdep.c
@@ -22,7 +22,6 @@
#include "dis-asm.h"
#include "dwarf2.h"
#include "dwarf2-frame.h"
-#include "floatformat.h"
#include "frame.h"
#include "frame-base.h"
#include "frame-unwind.h"
diff --git a/gdb/sparc64-tdep.c b/gdb/sparc64-tdep.c
index 8722f0acc8..b4ae165678 100644
--- a/gdb/sparc64-tdep.c
+++ b/gdb/sparc64-tdep.c
@@ -20,7 +20,6 @@
#include "defs.h"
#include "arch-utils.h"
#include "dwarf2-frame.h"
-#include "floatformat.h"
#include "frame.h"
#include "frame-base.h"
#include "frame-unwind.h"
diff --git a/gdb/spu-tdep.c b/gdb/spu-tdep.c
index 39cecfe5a5..a7eb27d638 100644
--- a/gdb/spu-tdep.c
+++ b/gdb/spu-tdep.c
@@ -38,7 +38,6 @@
#include "language.h"
#include "regcache.h"
#include "reggroups.h"
-#include "floatformat.h"
#include "block.h"
#include "observer.h"
#include "infcall.h"
diff --git a/gdb/tic6x-tdep.c b/gdb/tic6x-tdep.c
index 013a084a2f..aff95b69ad 100644
--- a/gdb/tic6x-tdep.c
+++ b/gdb/tic6x-tdep.c
@@ -36,7 +36,6 @@
#include "value.h"
#include "symfile.h"
#include "arch-utils.h"
-#include "floatformat.h"
#include "glibc-tdep.h"
#include "infcall.h"
#include "regset.h"
diff --git a/gdb/tilegx-tdep.c b/gdb/tilegx-tdep.c
index 5291e10f60..3a630c33d8 100644
--- a/gdb/tilegx-tdep.c
+++ b/gdb/tilegx-tdep.c
@@ -31,10 +31,8 @@
#include "dis-asm.h"
#include "inferior.h"
#include "arch-utils.h"
-#include "floatformat.h"
#include "regcache.h"
#include "regset.h"
-#include "doublest.h"
#include "osabi.h"
#include "linux-tdep.h"
#include "objfiles.h"
diff --git a/gdb/top.c b/gdb/top.c
index af27fcbcb0..ed109344b2 100644
--- a/gdb/top.c
+++ b/gdb/top.c
@@ -41,7 +41,6 @@
#include "top.h"
#include "version.h"
#include "serial.h"
-#include "doublest.h"
#include "main.h"
#include "event-loop.h"
#include "gdbthread.h"
diff --git a/gdb/value.c b/gdb/value.c
index d0871ef5bb..347eba5978 100644
--- a/gdb/value.c
+++ b/gdb/value.c
@@ -29,6 +29,7 @@
#include "language.h"
#include "demangle.h"
#include "doublest.h"
+#include "floatformat.h"
#include "regcache.h"
#include "block.h"
#include "dfp.h"
diff --git a/gdb/vax-tdep.c b/gdb/vax-tdep.c
index 4ff12fde3f..04203de1c4 100644
--- a/gdb/vax-tdep.c
+++ b/gdb/vax-tdep.c
@@ -20,7 +20,6 @@
#include "defs.h"
#include "arch-utils.h"
#include "dis-asm.h"
-#include "floatformat.h"
#include "frame.h"
#include "frame-base.h"
#include "frame-unwind.h"
diff --git a/gdb/xstormy16-tdep.c b/gdb/xstormy16-tdep.c
index bed4305d23..153375a1bd 100644
--- a/gdb/xstormy16-tdep.c
+++ b/gdb/xstormy16-tdep.c
@@ -30,9 +30,7 @@
#include "dis-asm.h"
#include "inferior.h"
#include "arch-utils.h"
-#include "floatformat.h"
#include "regcache.h"
-#include "doublest.h"
#include "osabi.h"
#include "objfiles.h"
#include "common/byte-vector.h"
diff --git a/gdb/xtensa-tdep.c b/gdb/xtensa-tdep.c
index 51fa520702..e8f6eb2c59 100644
--- a/gdb/xtensa-tdep.c
+++ b/gdb/xtensa-tdep.c
@@ -29,7 +29,6 @@
#include "dis-asm.h"
#include "inferior.h"
#include "osabi.h"
-#include "floatformat.h"
#include "regcache.h"
#include "reggroups.h"
#include "regset.h"