This is the mail archive of the elfutils-devel@sourceware.org mailing list for the elfutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Inline instance cache


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Petr Machata wrote:
> It turns out that most of the time is spend iterating inline instances 
> (dwarf_func_inline_instances).   So I created a straightforward cache 
> that simply finds all the inline instances in given CU, and stuffs them 
> into one array.  It's a quick work, I just want opinions before I end up 
> inventing crazy caching schemes in a wrong place.

So, why not provide an iterator over the inline functions and have the
caller create whatever data structure they need?  This seems more
generic since then the search can be customized.  Plus, it doesn't
punish users which make only a few such calls.

- --
➧ Ulrich Drepper ➧ Red Hat, Inc. ➧ 444 Castro St ➧ Mountain View, CA ❖
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)

iEYEARECAAYFAkjs3A0ACgkQ2ijCOnn/RHQEkgCfVfl3Py1Bl0sTpss1CQtFwIea
3EEAnRe36Ui+uexkc6x9auB4Il7CZoUt
=BRfG
-----END PGP SIGNATURE-----

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]