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

Restore causes extra MSBuild evaluations when child projects' TFM do not match with the parent project's #6311

Closed
emgarten opened this issue Dec 13, 2017 · 0 comments

Comments

@emgarten
Copy link
Member

emgarten commented Dec 13, 2017

Restore evaluates child projects using the parent project target framework.

  • This causes extra evaluations when the TFM is different between the parent and child projects, decreasing perf.
  • Potentially this could cause project references to be missed for single TFM child projects if the references are conditioned in a way that will change the result.

This extra iteration isn't needed:
https://github.com/NuGet/NuGet.Client/blob/cf779e8ba381fdef571f351c2956873ce3b5bb66/src/NuGet.Core/NuGet.Build.Tasks/NuGet.targets#L797

@emgarten emgarten added this to the 4.6 milestone Dec 13, 2017
@emgarten emgarten added the Tenet:Performance Performance issues label Dec 13, 2017
emgarten added a commit to NuGet/NuGet.Client that referenced this issue Dec 14, 2017
* Add BuildInParallel to MSBuild tasks
* Add SkipNonexistentTarget support
* Reduce TargetFramework iteration

Fixes NuGet/Home#6310
Fixes NuGet/Home#6311
Fixes NuGet/Home#6312
Fixes NuGet/Home#6061
@anangaur anangaur changed the title Restore evaluates child projects using the parent project target framework Restore causes extra MSBuild evaluations when child projects' TFM do not match with the parent project's Mar 8, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant