[cfe-commits] r47850 - /cfe/trunk/Headers/mmintrin.h

Eli Friedman eli.friedman at gmail.com
Mon Mar 3 16:43:39 PST 2008


On Mon, Mar 3, 2008 at 4:11 PM, Mike Stump <mrs at apple.com> wrote:
> On Mar 3, 2008, at 11:29 AM, Anders Carlsson wrote:
>  > +inline void _mm_empty()
>  > +{
>  > +    __builtin_ia32_emms();
>  > +}
>
>  Do we have an always_inline attr yet?  :-)  Also, a nodebug style
>  attribute is useful to avoid having a debugger show us that we are in
>  this file...

A nodebug-style attribute might be useful once clang actually starts
supporting emitting debug info; why does always_inline matter, though?

always_inline would probably need to be implemented in an
end-of-translation-unit hook, and I don't think one exists at the
moment.  Besides that, though, there's nothing especially difficult
about it: all that would need to happen is that CodeGen would need to
loop over all the always_inline functions and inline the callsites.

Actually, I just realized an issue with the current implementation:
shouldn't the functions in mmintrin.h actually be static inline?  We
don't ever want to depend on an external definition.

-Eli



More information about the cfe-commits mailing list