This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
[COMMIT] Fix long double for OpenBSD/powerpc
- From: Mark Kettenis <mark dot kettenis at xs4all dot nl>
- To: gdb-patches at sourceware dot org
- Date: Sat, 16 Apr 2005 23:37:36 +0200 (CEST)
- Subject: [COMMIT] Fix long double for OpenBSD/powerpc
They're not really long.
Committed (and sorry for the non-atomic commit),
Mark
Index: ChangeLog
from Mark Kettenis <kettenis@gnu.org>
* ppcobsd-tdep.c: Include "floatformat.h".
(ppcobsd_init_abi): Set long_double_bit and long_double_format.
* Makefile.in (ppcobsd-tdep.o): Update dependencies.
Index: ppcobsd-tdep.c
===================================================================
RCS file: /cvs/src/src/gdb/ppcobsd-tdep.c,v
retrieving revision 1.7
diff -u -p -r1.7 ppcobsd-tdep.c
--- ppcobsd-tdep.c 16 Apr 2005 21:08:21 -0000 1.7
+++ ppcobsd-tdep.c 16 Apr 2005 21:33:34 -0000
@@ -21,6 +21,7 @@
#include "defs.h"
#include "arch-utils.h"
+#include "floatformat.h"
#include "osabi.h"
#include "regcache.h"
#include "regset.h"
@@ -169,6 +170,10 @@ static const struct tramp_frame ppcobsd_
static void
ppcobsd_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
{
+ /* OpenBSD doesn't support the 128-bit `long double' from the psABI. */
+ set_gdbarch_long_double_bit (gdbarch, 64);
+ set_gdbarch_long_double_format (gdbarch, &floatformat_ieee_double_big);
+
/* OpenBSD uses SVR4-style shared libraries. */
set_solib_svr4_fetch_link_map_offsets
(gdbarch, svr4_ilp32_fetch_link_map_offsets);
Index: Makefile.in
===================================================================
RCS file: /cvs/src/src/gdb/Makefile.in,v
retrieving revision 1.712
diff -u -p -r1.712 Makefile.in
--- Makefile.in 15 Apr 2005 08:01:13 -0000 1.712
+++ Makefile.in 16 Apr 2005 21:36:20 -0000
@@ -2372,10 +2372,10 @@ ppcnbsd-tdep.o: ppcnbsd-tdep.c $(defs_h)
$(gdb_assert_h) $(solib_svr4_h)
ppcobsd-nat.o: ppcobsd-nat.c $(defs_h) $(inferior_h) $(regcache_h) \
$(ppc_tdep_h) $(ppcobsd_tdep_h)
-ppcobsd-tdep.o: ppcobsd-tdep.c $(defs_h) $(arch_utils_h) $(osabi_h) \
- $(regcache_h) $(regset_h) $(trad_frame_h_ $(tramp_frame_h) \
- $(gdb_assert_h) $(gdb_string_h) $(ppc_tdep_h) $(ppcobsd_tdep_h) \
- $(solib_svr4_h)
+ppcobsd-tdep.o: ppcobsd-tdep.c $(defs_h) $(arch_utils_h) $(floatformat_h) \
+ $(osabi_h) $(regcache_h) $(regset_h) $(trad_frame_h) \
+ $(tramp_frame_h) $(gdb_assert_h) $(gdb_string_h) $(ppc_tdep_h) \
+ $(ppcobsd_tdep_h) $(solib_svr4_h)
ppc-sysv-tdep.o: ppc-sysv-tdep.c $(defs_h) $(gdbcore_h) $(inferior_h) \
$(regcache_h) $(value_h) $(gdb_string_h) $(gdb_assert_h) \
$(ppc_tdep_h) $(target_h) $(objfiles_h) $(infcall_h)