On 10/29/14 05:59, Scott Duplichan wrote:
> Optimization is not enabled for x64 builds using gcc 4.4-4.9. For IA32
> builds, -Os (optimize for small code size) is used. Why is this? Apparently
> it is because variable argument list handling fails when gcc X64 optimization
> is enabled. The solution is an improvement to the patch of SVN rev 10440:
> http://sourceforge.net/p/edk2/mailman/message/25121111/

My reading of r10440 is different. As far as I understand,

  (gcc-4.4, X64, stdarg builtins)

is simply a broken a combination, regardless of optimization.

> The patch in this email only adds gcc X64 optimization for gcc versions 4.8
> and newer.

What happens if you add -Os for gcc-4.8+ (X64) without touching
NO_BUILTIN_VA_FUNCS and the VA_* macros? Just curious.

What implies any connection between lack of -Os and VA_*?

Thanks!
Laszlo

> This is because testing with older versions of gcc is a lot of
> work. On the other hand, the patch could be a lot simpler if it were to
> ignore gcc version. The patch is boot tested using Duet with gcc 4.8.2 and
> gcc 4.9.1. For these two cases, the print formatting problem is resolved
> by the patch.
> 
> Should we:
> 1) Restrict the change to recent gcc versions where testing is easy
>    (approach of included patch)
> 2) Apply the change to all gcc versions, and let older versions go
>    untested?
> 3) Try to find/build the needed older gcc versions so that the patch
>    can apply to all versions and be tested too
> 
> Thanks,
> Scott
> 
> 
> 
> ------------------------------------------------------------------------------
> 
> 
> 
> _______________________________________________
> edk2-devel mailing list
> edk2-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/edk2-devel
> 


------------------------------------------------------------------------------
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/edk2-devel

Reply via email to