spir Wrote:

> On 02/11/2011 09:49 PM, bearophile wrote:
> > Jim:
> >
> >> If forced inlining is to be supported
> >
> > spir was asking for a list of functions that the compiled has inlined, not 
> > for a forced inlining functionality.
> 
> You are (nearly) right, Bearophile. More precisely, I rather wish @inline on 
> a 
> given func to output a compiler message if said func is *not* inlined, due to 
> some criterion the compiler uses to decide; at best, some hint about said 
> criterion.
> I certainly do /not/ ask for forced inlining. (But others take the thread and 
> speak of what they wish...)


Sorry about that, but I think that is a closely related discussion. @inline is 
certainly a verb -- even imperative mood, so not just asking for information.
Why do you need information if you can't affect the outcome?

bearophile Wrote:
> D is almost a system language, so sometimes you need to go lower level (or 
> you just need a program that's not too much slow).

And it's true. To fit that niche you need control. D proudly supports inline 
assembler, after all... Why not function inlining?


Also, the meta-namespace is intriguing:

   static if( meta.inlined )
   {
      ...
   }

A function would know statically whether it was inlined, perhaps on request by 
the caller of the function.

The meta-namespace could provide a lot of useful information.

Reply via email to