home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.os.vms      DEC's VAX* line of computers & VMS.      264,096 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 263,297 of 264,096   
   Dan Cross to Waldek Hebisch   
   Re: Binutils   
   09 Sep 25 17:36:04   
   
   From: cross@spitfire.i.gajendra.net   
      
   In article <109nfac$9u12$1@paganini.bofh.team>,   
   Waldek Hebisch  wrote:   
   >Dan Cross  wrote:   
   >> In article <109mep8$84ft$1@paganini.bofh.team>,   
   >> Waldek Hebisch  wrote:   
   >>>[snip]   
   >>>Well, one issue is if needed construct is supported at all.   
   >>>   
   >>>Other platforms have code like:   
   >>>   
   >>>        .text   
   >>>        .globl  exp_fun   
   >>>        .type   exp_fun, @function   
   >>>exp_fun:   
   >>>        ret   
   >>>.LFE0:   
   >>>        .size   exp_fun, .-exp_fun   
   >>>        .globl alias_fun   
   >>>        .set alias_fun,exp_fun   
   >>>   
   >>>Assembling this on x86 Linux gives object file exporting two symbols:   
   >>>exp_fun and alias_fun.  IIUC this behaviour is wanted by C++   
   >>>compiler.   
   >>>   
   >>>Alpha VMS needs more complicated function definition.  And more   
   >>>important: '.set alias_fun,exp_fun' causes assembler message   
   >>>about wrong syntax.   
   >>>   
   >>>In DEC assembler '=' apparently gives effect that you describe:   
   >>>new name is not exported.  In DEC assembler '==' apparently creates   
   >>>an alias, but as a data symbol.  I am not aware of DEC construct   
   >>>to get effect of '.set' as in x86 Linux example above (but up   
   >>>to now I did not look into macro manual).  So '=' probably is   
   >>>wrong syntatx, I do not know why gcc uses it.   
   >>   
   >> So the GNU `as` documentation says that `a = e` has the same   
   >> semamtics as `.set a, e`.  Why isn't the Alpha version exporting   
   >> that symbol?  I don't know off the top of my head.  But it's not   
   >> specific to Alpha: my experiments were on x86.  My suspcion   
   >> is that its because it is not used in the file itself.   
   >   
   >GNU assembler has four similar constructs: .set, .eqv, = and ==.   
      
   Don't forget, `.equ`, which is another name for `.set`.  Also,   
   `.equiv` is another spelling.   
      
   >Generically .set is claimed to be the same as =, .eqv is claimed   
   >to be the same as ==.  But on some platforms .set and = differ   
   >and Alpha VMS seem to one of such platforms.   
   >   
   >I tried now '==' and it is possible that this is needed: using   
   >it I get two text symbols which resolve to the same address.   
      
   Well that's good!   
      
   	- Dan C.   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca