From: Adhemerval Zanella <adhemerval.zanella@linaro.org>
To: Carlos O'Donell <carlos@redhat.com>, libc-alpha@sourceware.org
Subject: Re: [PATCH v2] Add malloc micro benchmark
Date: Fri, 05 Jan 2018 16:46:00 -0000 [thread overview]
Message-ID: <b06da97c-3336-4385-377f-ac2872e48b88@linaro.org> (raw)
In-Reply-To: <54c9f9e0-5939-4b98-e36b-76383f276f35@redhat.com>
On 05/01/2018 14:17, Carlos O'Donell wrote:
> On 01/05/2018 07:50 AM, Adhemerval Zanella wrote:
>>
>>
>> On 05/01/2018 12:32, Carlos O'Donell wrote:
>>> On 01/04/2018 05:48 AM, Wilco Dijkstra wrote:
>>>> Carlos O'Donell wrote:
>>>>>
>>>>> Don't use mallopt, please make it a tunable then.
>>>>>
>>>>> The mallopt API already had 2 secret arena options which eventually became
>>>>> so well used they were baked into the API and had to be made public.
>>>>
>>>> Unfortunately tunables are not exported so you can't use them outside of GLIBC:
>>>>
>>>> /build/glibc/benchtests/bench-malloc-simple.o: In function `bench':
>>>> bench-malloc-simple.c:(.text+0x19c): undefined reference to `__tunable_set_val'
>>>> collect2: error: ld returned 1 exit status
>>>
>>> Correct, we only have a env-var frontend right now, and the internal API is not
>>> made accessible via GLIBC_PRIVATE.
>>>
>>> You have 3 options for tests:
>>>
>>> * Use the env vars to adjust test behaviour. Run the tests multiple times.
>>> * Add a new C API frontend, very valuable, but more time consuming.
>>> * Expose the existing internal C API via GLIBC_PRIVATE for testing, and throw
>>> it away later when we get a proper C API frontend.
>>>
>>
>> Do we want a C API to tied the malloc implementation to some tunables? My
>> understanding is the tunable api idea is not really enforce retro-compability
>> (where a C api would enforce it).
>
> If we add a C API to the tunables, we would honour that API for tunables for
> all time, but the tunables themselves would not be stable.
>
> e.g.
>
> * get list of tunables supported
> * get the default value for a tunable
> * get the value of a tunable
> * set the value of a tunable
>
> So you would use this API in the tests to get the tunable list, assert the
> tcache tunable was accepted (or fail the test), and then set it to a special
> value for the part of the test that needs it.
Right, this seems a reasonable approach (although I think out of the scope for
this change).
next prev parent reply other threads:[~2018-01-05 16:46 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-01 13:51 [PATCH] " Wilco Dijkstra
2017-12-01 16:13 ` Carlos O'Donell
2017-12-18 15:18 ` Wilco Dijkstra
2017-12-18 16:33 ` Carlos O'Donell
2018-01-02 18:20 ` [PATCH v2] " Wilco Dijkstra
2018-01-02 18:45 ` DJ Delorie
2018-01-03 12:12 ` Wilco Dijkstra
2018-01-03 15:07 ` Carlos O'Donell
2018-01-04 13:48 ` Wilco Dijkstra
2018-01-04 16:37 ` Adhemerval Zanella
2018-01-05 14:32 ` Carlos O'Donell
2018-01-05 15:50 ` Adhemerval Zanella
2018-01-05 16:17 ` Carlos O'Donell
2018-01-05 16:46 ` Adhemerval Zanella [this message]
2018-01-05 17:28 ` Carlos O'Donell
2018-01-05 14:33 ` Carlos O'Donell
2018-01-05 16:28 ` Joseph Myers
2018-01-05 17:26 ` Carlos O'Donell
2018-02-28 12:57 ` Florian Weimer
2018-02-28 15:16 ` Ondřej Bílka
2018-02-28 16:16 ` Florian Weimer
2018-02-28 18:21 ` Carlos O'Donell
2018-02-28 23:17 ` Ondřej Bílka
2018-02-28 19:56 ` Ondřej Bílka
2018-02-28 20:17 ` Wilco Dijkstra
2018-02-28 21:56 ` Carlos O'Donell
2018-02-28 21:56 ` Ondřej Bílka
[not found] ` <xnmuzssrqr.fsf@greed.delorie.com>
2018-03-01 11:24 ` Ondřej Bílka
2017-12-18 23:02 ` [PATCH] " DJ Delorie
2017-12-28 14:09 ` Wilco Dijkstra
2017-12-28 19:01 ` DJ Delorie
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=b06da97c-3336-4385-377f-ac2872e48b88@linaro.org \
--to=adhemerval.zanella@linaro.org \
--cc=carlos@redhat.com \
--cc=libc-alpha@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).