[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH v4 01/12] x86: infrastructure to allow converting certain indirect calls to direct ones



>>> On 02.10.18 at 15:21, <andrew.cooper3@xxxxxxxxxx> wrote:
> On 02/10/18 11:12, Jan Beulich wrote:
>> --- a/xen/include/xen/lib.h
>> +++ b/xen/include/xen/lib.h
>> @@ -66,6 +66,10 @@
>>  
>>  #define ROUNDUP(x, a) (((x) + (a) - 1) & ~((a) - 1))
>>  
>> +#define count_va_arg_(dot, a1, a2, a3, a4, a5, a6, a7, a8, x, ...) x
>> +#define count_va_arg(args...) \
>> +    count_va_arg_(., ## args, 8, 7, 6, 5, 4, 3, 2, 1, 0)
> 
> This particular bit of review split out for obvious reasons.
> 
> We already have __count_args() in the ARM SMCCC infrastructure.  Please
> can we dedup that (broken out into a separate patch) rather than
> introducing a competing version.
> 
> The ARM version is buggy.  It is off-by-two in the base case, and
> doesn't compile if fewer than two parameters are passed.

If you had followed earlier discussion, you'd have known up front
Julien's reaction. It is for that reason that I'm not trying to fiddle
with the ARM code in this regard, despite agreeing with you that
at the very least it _looks_ buggy.

> This version functions correctly, but should be named with a plural.

Why plural? Nothing in stdarg.h uses plural (including the header
file name itself).

Jan



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.