Re: [Qemu-devel] [PATCH] qemu/compiler: Wrap __attribute__((flatten)) in a macro

2018-09-26 Thread Peter Maydell
On 27 September 2018 at 06:28, Thomas Huth wrote: > Speaking of the minimum GCC version that we require: Did we ever > officially define that? Or is it just a result from appendix C in our > qemu-doc? I guess the minimum GCC could be defined to 4.2 since that's > the compiler that was still used i

Re: [Qemu-devel] [PATCH] qemu/compiler: Wrap __attribute__((flatten)) in a macro

2018-09-26 Thread Thomas Huth
On 2018-09-26 20:57, Peter Maydell wrote: > On 26 September 2018 at 16:59, Thomas Huth wrote: > >> +/* >> + * Clang 3.4 claims to be compatible with GCC 4.2, but does not have the >> + * "flatten" attribute, so we've got to handle Clang via __has_attribute >> here >> + */ >> +#if defined(__clang

Re: [Qemu-devel] [PATCH] qemu/compiler: Wrap __attribute__((flatten)) in a macro

2018-09-26 Thread Peter Maydell
On 26 September 2018 at 16:59, Thomas Huth wrote: > +/* > + * Clang 3.4 claims to be compatible with GCC 4.2, but does not have the > + * "flatten" attribute, so we've got to handle Clang via __has_attribute here > + */ > +#if defined(__clang__) && defined(__has_attribute) > +# if __has_attribute

Re: [Qemu-devel] [PATCH] qemu/compiler: Wrap __attribute__((flatten)) in a macro

2018-09-26 Thread Richard Henderson
On 9/26/18 8:59 AM, Thomas Huth wrote: > Older versions of Clang (before 3.5) and GCC (before 4.1) do not > support the "__attribute__((flatten))" yet. Since at least Clang > 3.4 is still used in EPEL for RHEL7 / CentOS 7, we should not > use this attribute directly but with a wrapper macro instead

[Qemu-devel] [PATCH] qemu/compiler: Wrap __attribute__((flatten)) in a macro

2018-09-26 Thread Thomas Huth
Older versions of Clang (before 3.5) and GCC (before 4.1) do not support the "__attribute__((flatten))" yet. Since at least Clang 3.4 is still used in EPEL for RHEL7 / CentOS 7, we should not use this attribute directly but with a wrapper macro instead. Signed-off-by: Thomas Huth --- fpu/softflo