This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFA/PATCH]: H8/300 - Update the generated debug information


While generating COFF debug information for "int" type, the compiler simply inserts type "T_INT" for this.
This doesn't say if the "int" is 32 bit or 16 bit.

The SDB/coff debug format is old, limited, and unextensible. It is almost always wrong to use it. Since you are using gdb, a better solution is to use stabs which doesn't have this problem.


Or, alternatively, if you must fix the SDB/coff debug info, I suggest doing the same thing Andrew Cagney suggested. Make gcc emit a special
directive (.int32) and/or pass an option to gas. Have gas set an ELF section header flag when it sees the directive or the option. Then modify gdb to set the int size appropriately depending on the ELF section header flags.


	* gcc/sdbout.c (plain_type_1): Update COFF debug output information.
					Output "short int" if integer size is 16 bit.

This isn't OK. It is wrong to emit a type of "short int" for an "int" even if they are the same size, because they aren't the same type. This will break the gdb testsuite.


Jim


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]