Reduce number of expf() calls for setTargetAtTime()
Categories
(Core :: Web Audio, enhancement)
Tracking
()
Tracking | Status | |
---|---|---|
firefox120 | --- | fixed |
People
(Reporter: karlt, Assigned: karlt)
References
Details
Attachments
(10 files)
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review |
Bug 1358149 comment 55 indicates that expf() evaluation is having a significant effect on the "Synth" and "Substractive synth" performance benchmarks, which use setTargetAtTime().
Using a linear recurrence relation to skip most of the expf() calls improves performance on "Substractive synth" by 13-23% and on "Synth" by 10-19% .
Assignee | ||
Comment 1•9 months ago
|
||
On top of other recent performance improvements, this now reduces time by 25 - 30% on "Substractive synth".
Assignee | ||
Comment 2•9 months ago
|
||
AudioParam uses ValidateEvent() and InsertEvent().
Assignee | ||
Comment 3•9 months ago
|
||
To simplify parameter sets and clarify which parameters may be in use.
Depends on D189463
Assignee | ||
Comment 4•9 months ago
|
||
Depends on D189464
Assignee | ||
Comment 5•9 months ago
|
||
This is a more natural place to manage the AudioTimelineEvent members.
It will also be a better place for pre-computing a constant exponential for
SetTarget curves in a subsequent patch.
Depends on D189465
Assignee | ||
Comment 6•9 months ago
|
||
Depends on D189466
Assignee | ||
Comment 7•9 months ago
|
||
where SetValueCurve requires different parameters.
These objects are copied when inserted into and moved within the
AudioEventTimeline array.
Depends on D189467
Assignee | ||
Comment 8•9 months ago
|
||
This changes failure messages from
assert_true: sample 1471 should equal 0.24924172461032867 expected true got false
to
assert_approx_equals: sample 1471 expected 0.24924172461032867 +/- 0.000001342 but got 0.24924308061599731
Depends on D189468
Assignee | ||
Comment 9•9 months ago
|
||
Depends on D189469
Assignee | ||
Comment 10•9 months ago
|
||
addressing a cppcoreguidelines-pro-type-member-init warning.
Depends on D189468
Assignee | ||
Comment 11•9 months ago
|
||
Depends on D189628
Comment 12•9 months ago
|
||
Pushed by ktomlinson@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/648bf0239d99 remove unused AudioEventTime methods r=padenot https://hg.mozilla.org/integration/autoland/rev/7139b608a37e use separate constructor for SetValueCurve AudioTimelineEvent r=padenot
Comment 13•9 months ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/648bf0239d99
https://hg.mozilla.org/mozilla-central/rev/7139b608a37e
Comment 14•9 months ago
|
||
Pushed by ktomlinson@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/4f5e812e3ab7 clarify that AudioParam tracks are handled by AudioParamTimeline not AudioEventTimeline r=padenot
Updated•9 months ago
|
Updated•9 months ago
|
Updated•9 months ago
|
Comment 15•9 months ago
|
||
Pushed by ktomlinson@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/f1f858a5c8c2 move ConvertAudioTimelineEventToTicks() to AudioTimelineEvent r=padenot
Comment 16•9 months ago
|
||
bugherder |
Comment 17•9 months ago
|
||
Pushed by ktomlinson@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/d7b66b8f2e34 add getters to AudioTimelineEvent::Value() to assert that members are not accessed for the wrong event types r=padenot
Comment 18•9 months ago
|
||
Pushed by ktomlinson@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/19c7e9c983a2 use a union for more AudioTimelineEvent members r=padenot https://hg.mozilla.org/integration/autoland/rev/b781e655236d use assert_approx_equals for comparison with tolerance r=padenot
Created web-platform-tests PR https://github.com/web-platform-tests/wpt/pull/42267 for changes under testing/web-platform/tests
Comment 20•9 months ago
|
||
Pushed by ktomlinson@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/66bd7c78781a clarify that mCurve and mCurveLength are set in the AudioTimelineEvent constructor r=padenot https://hg.mozilla.org/integration/autoland/rev/f90a7a1b6c24 suppress cppcoreguidelines-pro-type-member-init warning for AudioEventTimeline copy constructor r=padenot
Comment 21•9 months ago
|
||
Pushed by ktomlinson@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/1fd044c18e14 pre-compute constant exponential for inter-tick ratio in setTargetAtTime() curves r=padenot
Assignee | ||
Updated•9 months ago
|
Comment 22•9 months ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/f1f858a5c8c2
https://hg.mozilla.org/mozilla-central/rev/d7b66b8f2e34
https://hg.mozilla.org/mozilla-central/rev/19c7e9c983a2
https://hg.mozilla.org/mozilla-central/rev/b781e655236d
Upstream PR merged by moz-wptsync-bot
Comment 24•9 months ago
|
||
bugherder |
Description
•