Skip to content

perf(core): speed up retrieval of DestroyRef in EventEmitter#54748

Closed
devversion wants to merge 1 commit intoangular:mainfrom
devversion:perf-event-emitter
Closed

perf(core): speed up retrieval of DestroyRef in EventEmitter#54748
devversion wants to merge 1 commit intoangular:mainfrom
devversion:perf-event-emitter

Conversation

@devversion
Copy link
Member

Speeds up the retrieval of DestroyRef in EventEmitter because try/catch is expensive if
there is no injection context.

We saw a script time regression in Cloud.

@pkozlowski-opensource pkozlowski-opensource added area: core Issues related to the framework runtime target: rc This PR is targeted for the next release-candidate labels Mar 7, 2024
@ngbot ngbot bot added this to the Backlog milestone Mar 7, 2024
@devversion devversion force-pushed the perf-event-emitter branch from 6cf75f5 to 919c864 Compare March 7, 2024 15:54
Copy link
Member

@crisbeto crisbeto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, one non-blocking comment

@devversion devversion force-pushed the perf-event-emitter branch from 919c864 to 87dc868 Compare March 7, 2024 17:23
@devversion devversion added the action: global presubmit The PR is in need of a google3 global presubmit label Mar 7, 2024
@devversion
Copy link
Member Author

Passing TGP

@devversion devversion added action: merge The PR is ready for merge by the caretaker and removed action: global presubmit The PR is in need of a google3 global presubmit labels Mar 8, 2024
alxhub
alxhub previously requested changes Mar 9, 2024
Speeds up the retrieval of `DestroyRef` in `EventEmitter` because
`try/catch` is expensive if there is no injection context.

We saw a script time regression in Cloud.

The goldens had to be updated because `getInjectImplementation` is now
referenced. `inject` also references the underlying field, but directly.
This is super minimal overhead of a function exposing the internal
field.
@devversion devversion dismissed alxhub’s stale review March 11, 2024 11:56

Addressed feedback; unblocking

@devversion
Copy link
Member Author

devversion commented Mar 11, 2024

Caretaker note: Pre-existing failures— fixed via #54791

@devversion devversion added the merge: caretaker note Alert the caretaker performing the merge to check the PR for an out of normal action needed or note label Mar 11, 2024
@atscott
Copy link
Contributor

atscott commented Mar 11, 2024

This PR was merged into the repository by commit 142825d.

atscott pushed a commit that referenced this pull request Mar 11, 2024
)

Speeds up the retrieval of `DestroyRef` in `EventEmitter` because
`try/catch` is expensive if there is no injection context.

We saw a script time regression in Cloud.

The goldens had to be updated because `getInjectImplementation` is now
referenced. `inject` also references the underlying field, but directly.
This is super minimal overhead of a function exposing the internal
field.

PR Close #54748
@atscott atscott closed this in 142825d Mar 11, 2024
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Apr 11, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

action: merge The PR is ready for merge by the caretaker area: core Issues related to the framework runtime merge: caretaker note Alert the caretaker performing the merge to check the PR for an out of normal action needed or note target: rc This PR is targeted for the next release-candidate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants