From: Lars-Peter Clausen <lars@metafoo.de>
To: noman pouigt <variksla@gmail.com>, alsa-devel@alsa-project.org
Subject: Re: [PATCH v2 8/8] ASoC: dapm: Use more aggressive caching
Date: Mon, 27 Oct 2014 13:10:23 +0100 [thread overview]
Message-ID: <544E362F.2050100@metafoo.de> (raw)
In-Reply-To: <CAES_P+8Z2BO46XuLokSXsgfNQud3VfNTXKOno9VinTsM=cyXBQ@mail.gmail.com>
On 10/26/2014 08:29 PM, noman pouigt wrote:
>> E.g. imagine the following example:
>>
>> A --> B ----.
>> v
>> M --> N --> Z <-- S <-- R
>> |
>> v
>> X>
>>
>> Widget Z has multiple input paths, if any change was made that cause Z to be
>> marked as dirty the power state of Z has to be re-computed. This requires to
>> know the number of inputs and outputs of Z, which requires to know the
>> number of inputs and outputs of all widgets on all paths from or to Z.
>> Previously this meant re-computing all inputs and outputs of all the path
>> going into or out of Z. With this patch in place only paths that actually
>> have changed need to be re-computed.
> so suppose "B" was the widget which caused "Z" to be dirtied then with your
> patch only you will calculate A->B->N->Z ?
It will only re-compute the inputs and outputs on those path that may have
changed. E.g. if Z is a mixer and the switch between N and Z is changed it
will only re-compute the number of outputs for M and N and the number of
outputs for Z and X. But keep the cached numbers for all other widgets.
>
> Is my understanding right?
>
> A->B->C
> |
> v
> G->P
> v
> |
> D->E->F
>
> What will happen in the above diagram if P gets dirtied?
That depends on the reason why it was marked as dirty. Different operations
have different impacts on the validity of the cached input/output numbers.
This series does not change which widgets get mark as dirty or how dirty
widgets are handled. It introduces caching for the number of connected paths
that go to a sink and the number of paths that come from source.
- Lars
next prev parent reply other threads:[~2014-10-27 12:10 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-10-26 19:29 [PATCH v2 8/8] ASoC: dapm: Use more aggressive caching noman pouigt
2014-10-27 12:10 ` Lars-Peter Clausen [this message]
-- strict thread matches above, loose matches on Subject: below --
2014-10-25 15:41 [PATCH v2 0/8] ASoC: dapm: Cleanups and speed-ups Lars-Peter Clausen
2014-10-25 15:42 ` [PATCH v2 8/8] ASoC: dapm: Use more aggressive caching Lars-Peter Clausen
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=544E362F.2050100@metafoo.de \
--to=lars@metafoo.de \
--cc=alsa-devel@alsa-project.org \
--cc=variksla@gmail.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.