g++ (was stdio.h incompatibility)

Frank J. Edwards crash at ckctpa.UUCP
Sun Jun 23 10:53:42 AEST 1991


In article <1512 at compel.UUCP> her at compel.UUCP (Helge Egelund Rasmussen) writes:
>s000623 at kowande.bu.oz.au (Jason Patterson) writes:
>
>> **** THE STANDARD ASSEMBLER HATES $ SIGNS IN LABELS ****
>>This is a big problem because EVERY constructor gets a $ sign
>>put into it's "mangled" name by g++ (standard mangled names for
>>constructors begin _$_).
>
>Well, I haven't AMIX, and I'm working with g++.1.39.0, so might be wrong here...
>
>Try to define 
>     NO_DOLLAR_IN_LABEL 
>in the tm.h, it should solve this problem.
>
>This define is described in cplus_tree.h:

Yeah, but all that does is use periods instead.  And "as" under Amix doesn't
like periods in the middle of labels either.

I created a test file for the assembler and tried every punctuation character
on the keyboard to see what the assembler _would_ take; the underscore (if
you consider that punctuation) and the percent sign ('%') were it.  Of
course, the percent sign has problems when the compiler tries to do printf()s
and stuff, so you have to double it up, right?  Wrong.  The code makes
assumptions about labels of the form _$_ and expects three characters, so
_%%_ won't work.

All this is solved with the patch Rich Skrenta posted.  (aside to Rich:
my G++ is bombing out on src/Random.cc with segment violations in the
g++/varasm.c source file, subroutine decode_asm_reg() called from
make_decl_rtl().  It appears FIRST_PSEUDO_REGISTER is too large and
is causing strcmp() to perform a check with invalid parameters.  Would
you send me the config files you're using?  tm.h, md, etc.  Also include
any #include'd files please.  Thanks, I owe you one :-)  If you ever make
it down to Clearwater beach, look me up ;-)

>Hope this will work for you, now if someone could port g++ to AmigaDos....

Yeah, hopefully G++/GCC will be able to bootstrap itself to AmigaDOS once
I get this working (and I understand _WHY_ it's working ;-)

>Helge 
>---
>Helge E. Rasmussen  .  PHONE + 45 36 72 33 00  .  E-mail:  her at compel.dk
>Compel A/S          .  FAX   + 45 36 72 43 00  .  
>Copenhagen, Denmark

-- 
Frank J. Edwards		|  "I did make up my own mind -- there
2677 Arjay Court		|   simply WASN'T ANY OTHER choice!"
Palm Harbor, FL  34684-4504	|		-- Me
Phone (813) 786-3675 (voice)	|    Only Amiga Makes It Possible...



More information about the Comp.unix.amiga mailing list