This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
GDB ARIndex cleanup
- From: "Pierre Muller" <muller at ics dot u-strasbg dot fr>
- To: <gdb-patches at sourceware dot org>
- Cc: <gdb at sourceware dot org>, "'Eli Zaretskii'" <eliz at gnu dot org>
- Date: Thu, 26 Mar 2009 14:09:49 +0100
- Subject: GDB ARIndex cleanup
After several commits related to
Awk Regression Index page
http://sourceware.org/gdb/current/ari/
I finally came down to 2 Critical items left, i.e. :
Things previously eliminated but returned. This should always be empty.
These are :
inline 11 Do not use the inline attribute; since the compiler
generally ignores this, better algorithm selection is needed to improved
performance
GNU/Linux 7 Do not use `Linux', instead use `Linux kernel' or
`GNU/Linux system'; comments should clearly differentiate between the two
(this test assumes that word `Linux' appears on the same line as the word
`GNU' or `kernel'
I wanted to get feedback on these two issues:
1) "inline"
for inline, someone once said that the
rule that we should not use "inline" keyword
is old, and maybe not correct anymore.
If everyone agrees that this rule should stay,
I will be happy to commit an obvious fix removing
all of them as this seems quite mechanical,
but I wanted to get some feedback first.
2) GNU/Linux issues.
This is more difficult for me to fix, as
the difference between "Linux kernel" and "GNU/Linux system"
is still kind of fuzzy...
Could someone else look into those issues?
3) I also recompiled doschk program
so that the list of incompatibilities with
the DOS limitations is generated again...
Eli, there are probably several directories that we could
disregard for this, but I think that
there are also real issues left.
Pierre Muller
Pascal language support maintainer for GDB
PS:
Here is a list of Linux detected problems:
lines 39,43p gdb/ppc-linux-tdep.h
int ppc_linux_trap_reg_p (struct gdbarch *gdbarch);
/* Linux target descriptions. */
extern struct target_desc *tdesc_powerpc_32l;
extern struct target_desc *tdesc_powerpc_altivec32l;
lines 1273,1279p gdb/amd64-tdep.c
}
/* The list of issues to contend with here is taken from
resume_execution in arch/x86/kernel/kprobes.c, Linux 2.6.28.
Yay for Free Software! */
/* Relocate the %rip back to the program's instruction stream,
lines 70,76p gdb/linux-nat.c
the specific pid, and not passing WNOHANG.
When waiting for an event in all threads, waitpid is not quite good. Prior
to
version 2.4, Linux can either wait for event in main thread, or in secondary
threads. (2.4 has the __WALL flag). So, if we use blocking waitpid, we
might
miss an event. The solution is to use non-blocking waitpid, together with
sigsuspend. First, we use non-blocking waitpid to get an event in the main
lines 430,436p gdb/i386-tdep.c
paddr_nz (from), paddr_nz (to), insn[0], insn[1]);
/* The list of issues to contend with here is taken from
resume_execution in arch/i386/kernel/kprobes.c, Linux 2.6.20.
Yay for Free Software! */
/* Relocate the %eip, if necessary. */
lines 165,171p gdb/i386-tdep.h
#define I386_SEL_KPL 0x0000 /* Kernel Privilige Level. */
/* The length of the longest i386 instruction (according to
include/asm-i386/kprobes.h in Linux 2.6. */
#define I386_MAX_INSN_LEN (16)
/* Functions exported from i386-tdep.c. */
lines 659,665p gdb/ppc-linux-tdep.c
return addr;
}
/* Wrappers to handle Linux-only registers. */
static void
ppc_linux_supply_gregset (const struct regset *regset,
lines 1175,1181p gdb/ppc-linux-tdep.c
gdbarch_register_osabi (bfd_arch_rs6000, bfd_mach_rs6k, GDB_OSABI_LINUX,
ppc_linux_init_abi);
/* Initialize the Linux target descriptions. */
initialize_tdesc_powerpc_32l ();
initialize_tdesc_powerpc_altivec32l ();
initialize_tdesc_powerpc_vsx32l ();