This is the mail archive of the gdb@sources.redhat.com mailing list for the GDB 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: 64bit gdb for KAI/KCC compiler


On Thu, Jun 27, 2002 at 05:36:03PM -0500, Chu, Josh wrote:
> Ok, so here's the deal : KAI released a patch for gdb 5.0 that will allow
> gdb to read the EDG-style mangled names.  I've attached the patch files that
> were to be applied to 5.0 (gdb.patch-5.0 and libiberty.patch-5.0).  I tried
> manually applying these modifications to the 5.2 source, and it builds.
> However, there are some definite problems because gdb will now core dump
> occasionally, not to mention the names are still mangled.
> I've included the patch files to 5.0 and my modifications to the files in
> 5.2 :
>  
> gdb/libiberty:
>     cplus-dem.c
>  
> gdb/gdb:
>     dwarf2read.c
>     hpread.c
>     stabsread.c
>     symfile.c

> After this is done, you can try to build and run.  (export CC='gcc -m64' and
> ./configure first)

What platform is this, Solaris?  Looks like it from the m64.

> I suppose this is a fairly vague question : but does anyone have a clue why
> the patches aren't working with 5.2?
> This would be a huge help for anyone who has a KAI compiler on a 64-bit
> system, as it would allow people to debug 64bit programs compiled with KCC.
> Or if someone who's familiar with the above-mentioned files could comment on
> the patched files and what could potentially be wrong with them, I would
> very much appreciate it.
> Thanks so much

I'm more curious why they worked with 5.0.  I imagine they had very
limited functionality, since there is a great deal more to do in C++
support than demangle names properly.

I skimmed the patches and nothing jumps out at me as immediately wrong
except for:
!       if ( !EDG_DEMANGLING && !is_edg_temporary_var(sym) )
!         add_symbol_to_list (sym, &local_symbols);

That should probably be || if you ever want to see a local static
variable in GDB.... also, you do not need to comment out
finish_cv_type.



-- 
Daniel Jacobowitz                           Carnegie Mellon University
MontaVista Software                         Debian GNU/Linux Developer


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