Article View: gnu.gcc.bug
Article #1165Re: new config file for gcc for AIX PS/2 version 1.2 ...
From: Michael Bloom
Date: Mon, 24 Sep 1990 04:54
Date: Mon, 24 Sep 1990 04:54
67 lines
2888 bytes
2888 bytes
In article <9009220259.AA04317@life.ai.mit.edu> TRANLE@INTELLICORP.COM (Minh Tran-Le) writes:
> - changed to produce sdb debugging info instead of dbx debug info.
> The debugging info is not very usefull because ibm does not provide an sdb
> debugger and the as assembler does not know how to handle dbx .stabs. But at
> least it does not break when trying to compile with -g.
A possible alternative that WOULD allow debugging if it works on AIX
might be to use gas and gdb configured to work with dbx stabs in COFF
using the patches available from tut.cis.ohio-state.edu (or osu-cis).
If tm-i386gcoff.h is insufficent for aix, try creating a tm- file that
#includes tm-i386gcoff.h and uses #undef and #define to define what
would need to be different for AIX.
With these patches, you get a gas that understands dbx .stab
directives and produces coff. The coff symbols produced for .stab
directives appear to be ordinary non-debug symbols to a normal COFF
loader which will do the right thing with them.
The only problem that I can foresee is that the AIX ld might not
expect or generate standard COFF line number tables. Can anyone tell
me if this is so? If this is the case, the following patch (with
BROKEN_LINE_TABLES #defined) should allow gas to emit N_SLINE symbols
instead of a line number table at a cost (18 bytes per line number
instead of 6) in object file size.
*** ../dist/coff-conv.c Sun Sep 23 21:40:04 1990
--- ./coff-conv.c Sun Sep 23 21:42:19 1990
***************
*** 2028,2061 ****
--- 2028,2063 ----
SYMENT **sptr;
AUXENT **xptr;
unsigned int type;
int an;
{
int snum;
char sname ;
struct syment_pun *punptr = (struct syment_pun *) (*sptr);
+ #ifndef BROKEN_LINE_TABLES
if (type == (unsigned short) N_SLINE)
{
if (line_scope_change_sym == 0)
link_line_nums((*aptr));
else
{
/* A new line info header is generated whenever an N_SLINE occurs
after a symbol that indicated a change of line number scope
*/
make_line_info(aptr,sptr,xptr,type,an);
link_line_nums((*aptr));
line_scope_change_sym = 0;
}
return;
}
+ #endif /* BROKEN_LINE_TABLES */
(*sptr)->n_zeroes = 0;
(*sptr)->_n._n_n._n_offset = 0;
set_symbol(*aptr,*sptr);
sname = SNAME_OF(type);
snum = (*sptr)->n_scnum;
if (type == (unsigned int) N_SO
Technical Details
Message-ID:
<19996@ttidca.TTI.COM>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rutgers!usc!hacgate!ashtate!psivax!ttidca!mbReferences:
<9009220259.AA04317@life.ai.mit.edu>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rutgers!usc!hacgate!ashtate!psivax!ttidca!mb From: mb@ttidca.TTI.COM (Michael Bloom) Newsgroups: gnu.gcc.bug,comp.unix.aix Subject: Re: new config file for gcc for AIX PS/2 version 1.2 ... Message-ID: <19996@ttidca.TTI.COM> Date: 24 Sep 90 04:54:30 GMT References: <9009220259.AA04317@life.ai.mit.edu> Distribution: gnu Organization: Citicorp/TTI, Santa Monica Lines: 67