This is the mail archive of the binutils@sourceware.org mailing list for the binutils 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: Gnu assembler question for ARM


On 08 May 2007 16:41, Ciaccia wrote:

> Hi Nick,
> Thanks a lot for your mail, I was not aware about the existence of the
> __builtin_offsetof "operator" (is it really an operator?). 

  It's a builtin function, which is to say, it's kind of internal compiler
magic that looks a lot like a function from the outside but doesn't actually
have to translate to a run-time function call in the compiled assembly, the
compiler can evaluate it at compile-time and replace it with a constant equal
to the result, or whatever else it might want to do.  Take a look at the docs
for '__builtin_expect' for another example, here we have something with the
syntax of a function call, which in fact does not compile to anything at all,
but is instead treated as an instruction to the compiler to take into account
during code generation.


    cheers,
      DaveK
-- 
Can't think of a witty .sigline today....


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