|
View:
New views
2 Messages
—
Rating Filter:
Alert me
|
|
|
gcc inliningHi devs,
in agg_basics.h file is declared macro AGG_INLINE that is used to heavy inline some larger functions. Under MSVC this is good, because it uses __forceinline keyword, but when I tried this with GCC and -Winline option enabled, I see that GCC not inlines pretty simple code. Soo, shouldn't be the AGG_INLINE definition changed to something like this? #if defined(_MSC_VER) #define AGG_INLINE __forceinline #elif defined(__GNUC__) #define AGG_INLINE inline __attribute__(always_inline) #else #define AGG_INLINE inline #endif I don't know if this affects performance a lot, I reccomend using -Winline to see what is not inlined Cheers - Petr ------------------------------------------------------------------------------ The NEW KODAK i700 Series Scanners deliver under ANY circumstances! Your production scanning environment may not be a perfect world - but thanks to Kodak, there's a perfect scanner to get the job done! With the NEW KODAK i700 Series Scanner you'll get full speed at 300 dpi even with all image processing features enabled. http://p.sf.net/sfu/kodak-com _______________________________________________ Vector-agg-general mailing list Vector-agg-general@... https://lists.sourceforge.net/lists/listinfo/vector-agg-general |
|
|
Re: gcc inliningSorry, it should be
#if defined(_MSC_VER) #define AGG_INLINE __forceinline #elif defined(__GNUC__) #define AGG_INLINE inline __attribute__((always_inline)) #else #define AGG_INLINE inline #endif 2009/5/6 Petr Kobalíček <kobalicek.petr@...>: > Hi devs, > > in agg_basics.h file is declared macro AGG_INLINE that is used to > heavy inline some larger functions. Under MSVC this is good, because > it uses __forceinline keyword, but when I tried this with GCC and > -Winline option enabled, I see that GCC not inlines pretty simple > code. > > Soo, shouldn't be the AGG_INLINE definition changed to something like this? > > #if defined(_MSC_VER) > #define AGG_INLINE __forceinline > #elif defined(__GNUC__) > #define AGG_INLINE inline __attribute__(always_inline) > #else > #define AGG_INLINE inline > #endif > > I don't know if this affects performance a lot, I reccomend using > -Winline to see what is not inlined > > Cheers > - Petr > ------------------------------------------------------------------------------ The NEW KODAK i700 Series Scanners deliver under ANY circumstances! Your production scanning environment may not be a perfect world - but thanks to Kodak, there's a perfect scanner to get the job done! With the NEW KODAK i700 Series Scanner you'll get full speed at 300 dpi even with all image processing features enabled. http://p.sf.net/sfu/kodak-com _______________________________________________ Vector-agg-general mailing list Vector-agg-general@... https://lists.sourceforge.net/lists/listinfo/vector-agg-general |
| Free embeddable forum powered by Nabble | Forum Help |