[PATCH][benchtests] Accept output arguments to benchmark functions
Siddhesh Poyarekar
siddhesh@redhat.com
Wed Dec 4 10:05:00 GMT 2013
On Wed, Dec 04, 2013 at 09:55:40AM +0000, Will Newton wrote:
> On 4 December 2013 07:38, Siddhesh Poyarekar <siddhesh@redhat.com> wrote:
> > Hi,
> >
> > This patch adds the ability to accept output arguments to functions
> > being benchmarked, by nesting the argument type in <> in the args
> > directive. It includes the sincos implementation as an example, where
> > the function would have the following args directive:
>
> Is there a line missing here?
Ugh, yeah there is. sincos would have the following args directive:
## args: double:<double *>:<double *>
The above means that sincos takes three arguments of type double,
double * and double *, where the last two arguments (enclosed with <>)
are output arguments.
>
> It's not clear to me how these values map to the arguments / return values.
>
The values map only to the input arguments. So if I had a directive
like this:
## args: int:<int *>:int:<int *>
and I have a value list like this:
1, 2
3, 4
5, 6
then the function calls generated would be:
foo (1, &out1, 2, &out2);
foo (3, &out1, 4, &out2);
foo (5, &out1, 6, &out2);
Siddhesh
More information about the Libc-alpha
mailing list