Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

perf(ivy): initialise TNode inputs / outputs on the first creation pass #32608

Conversation

@pkozlowski-opensource
Copy link
Member

commented Sep 11, 2019

This perf-focused refactoring moves the TNode's input / output initialization
logic to the first template pass - close to the place where directives are
matched and resolved.

This code change makes it possible to update-mode checks for both property
bindings and listeners registration.

@googlebot googlebot added the cla: yes label Sep 11, 2019
@pkozlowski-opensource pkozlowski-opensource force-pushed the pkozlowski-opensource:ivy_perf_2019_09_19 branch from d289f49 to 63ab8ea Sep 11, 2019
@ngbot ngbot bot modified the milestone: needsTriage Sep 11, 2019
@pkozlowski-opensource pkozlowski-opensource force-pushed the pkozlowski-opensource:ivy_perf_2019_09_19 branch from 63ab8ea to 769392d Sep 12, 2019
@pkozlowski-opensource pkozlowski-opensource marked this pull request as ready for review Sep 12, 2019
@pkozlowski-opensource pkozlowski-opensource requested a review from angular/fw-core as a code owner Sep 12, 2019
inputAliasMap: {[publicName: string]: string}, directiveDefIdx: number,
propStore: PropertyAliases | null): PropertyAliases|null {
for (let publicName in inputAliasMap) {
if (inputAliasMap.hasOwnProperty(publicName)) {

This comment has been minimized.

Copy link
@alfaproject

alfaproject Sep 12, 2019

Contributor

Object.keys is more performant if you can use it

This comment has been minimized.

Copy link
@mhevery

mhevery Sep 12, 2019

Member

That is surprising as Object.keys must allocate an array.

This comment has been minimized.

Copy link
@alfaproject

alfaproject Sep 12, 2019

Contributor

I think in goes through the prototype chain etc, which is pointless here and slower

@kara

This comment has been minimized.

Copy link
Contributor

commented Sep 12, 2019

@pkozlowski-opensource Can you rebase this?

@pkozlowski-opensource pkozlowski-opensource force-pushed the pkozlowski-opensource:ivy_perf_2019_09_19 branch from 769392d to 1e85c3e Sep 12, 2019
This perf-focused refactoring moves the TNode's input / output initialization
logic to the first template pass - close to the place where directives are
matched and resolved.

This code change makes it possible to update-mode checks for both property
bindings and listeners registration.
@pkozlowski-opensource pkozlowski-opensource force-pushed the pkozlowski-opensource:ivy_perf_2019_09_19 branch from 1e85c3e to c09b4e9 Sep 12, 2019
@kara kara closed this in ad178c5 Sep 12, 2019
arnehoek added a commit to arnehoek/angular that referenced this pull request Sep 26, 2019
…ss (angular#32608)

This perf-focused refactoring moves the TNode's input / output initialization
logic to the first template pass - close to the place where directives are
matched and resolved.

This code change makes it possible to update-mode checks for both property
bindings and listeners registration.

PR Close angular#32608
@angular-automatic-lock-bot

This comment has been minimized.

Copy link

commented Oct 13, 2019

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 Oct 13, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
6 participants
You can’t perform that action at this time.