GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Update folder path for storing optimization profile and add test to validate loaded assemblies and libraries on startup by daxian-dbw · Pull Request #8406 · PowerShell/PowerShell

Conversation

@daxian-dbw

@daxian-dbw Dongbo Wang (daxian-dbw) commented Dec 6, 2018 •
edited by adityapatwardhan
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

PR Summary

Two changes in this PR:

  • Update folder path for storing optimization profile
  • Add test to validate loaded assemblies and libraries on startup

Assemblies loaded on startup impact startup time. Sometimes we merge a commit that uses a new type that adds loading a new assembly on startup. We need to catch these and decide if it's worth the impact or delay loading when possible.

Assemblies that are loaded during startup are affected by the profile optimization automatically generated in powershell. The StartupProfileData-xxxx files record assemblies that are potentially used right after powershell starts. With such a file being available, powershell will eagerly load those assemblies using multiple CPU cores, even though some assemblies are not really needed for the current use case.

So, to accurately test the loaded assemblies at startup, we need to remove StartupProfileData-NonInteractive before run pwsh -noprofile -command ...

PR Checklist

  • PR has a meaningful title
    • Use the present tense and imperative mood when describing your changes
  • Summarized changes
  • Change is not breaking
  • Make sure all .h, .cpp, .cs, .ps1 and .psm1 files have the correct copyright header
  • This PR is ready to merge and is not Work in Progress.
    • If the PR is work in progress, please add the prefix WIP: to the beginning of the title and remove the prefix when the PR is ready.
  • User-facing changes
    • Not Applicable
    • OR
    • User-facing Documentation needed
      • Issue filed - Issue link:
  • Testing - New and feature
    • Not Applicable or can only be tested interactively
    • OR
    • Make sure you've added a new test if existing tests do not effectively test the code changed
      • Add [feature] if the change is significant or affects feature tests

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Steve Lee (SteveL-MSFT) and others added 6 commits December 5, 2018 12:43
@SteveL-MSFT @daxian-dbw
add test to validate loaded assemblies on startup
980b038
@SteveL-MSFT @daxian-dbw
address feedback
73c67ef
@SteveL-MSFT @daxian-dbw
add 'System.Collections.Immutable.dll' back as it's loaded on startup
12bb147
@SteveL-MSFT @daxian-dbw
need to add back 'System.Security.Cryptography.Algorithms.dll'
7a3cb58
@SteveL-MSFT @daxian-dbw
add back 'System.Security.Permissions.dll'
06313ee
@daxian-dbw
Update the test and the path for storing the optimization profile
042424e
@daxian-dbw Dongbo Wang (daxian-dbw) self-assigned this Dec 6, 2018
@daxian-dbw
Dongbo Wang (daxian-dbw) requested review from Steve Lee (SteveL-MSFT), Aditya Patwardhan (adityapatwardhan) and Andrew (anmenaga) December 6, 2018 02:22
@daxian-dbw
Dongbo Wang (daxian-dbw) requested a review from Bruce Payette (BrucePay) as a code owner December 6, 2018 02:22
@daxian-dbw Dongbo Wang (daxian-dbw) mentioned this pull request Dec 6, 2018
Add test to validate loaded assemblies and libraries on startup #8331
Closed
7 of 11 tasks
SteveL-MSFT
Steve Lee (SteveL-MSFT) requested changes Dec 6, 2018
View reviewed changes
Comment thread test/powershell/Host/Startup.Tests.ps1 Resolved

Uh oh!

There was an error while loading. Please reload this page.

@daxian-dbw
Sort the assembly list
67e9813
@adityapatwardhan Aditya Patwardhan (adityapatwardhan) added this to the 6.2.0-preview.3 milestone Dec 6, 2018
@adityapatwardhan

Aditya Patwardhan (adityapatwardhan) commented Dec 6, 2018

Copy link
Copy Markdown
Member

Steve Lee (@SteveL-MSFT) Please update your review.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

SteveL-MSFT
Steve Lee (SteveL-MSFT) approved these changes Dec 6, 2018
View reviewed changes
@daxian-dbw
Dongbo Wang (daxian-dbw) merged commit 2dcf52f into PowerShell:master Dec 6, 2018
@daxian-dbw
Dongbo Wang (daxian-dbw) deleted the SteveL-MSFT-startup-test branch December 6, 2018 22:26
@daxian-dbw Dongbo Wang (daxian-dbw) added the CL-Test Indicates that a PR should be marked as a test change in the Change Log label Dec 6, 2018
Thatgfsj (Thatgfsj) pushed a commit to Thatgfsj-contribs/PowerShell that referenced this pull request Aug 6, 2026
@daxian-dbw
Update folder path for storing optimization profile and add test to v…
ddb1cc4
…alidate loaded assemblies and libraries on startup (PowerShell#8406)

- Update folder path for storing optimization profile file.
- Add test to validate loaded assemblies and libraries on startup.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@SteveL-MSFT Steve Lee (SteveL-MSFT) SteveL-MSFT approved these changes
@anmenaga Andrew (anmenaga) Awaiting requested review from anmenaga
@adityapatwardhan Aditya Patwardhan (adityapatwardhan) Awaiting requested review from adityapatwardhan
@BrucePay Bruce Payette (BrucePay) Awaiting requested review from BrucePay

Uh oh!

There was an error while loading. Please reload this page.

Assignees

@daxian-dbw Dongbo Wang (daxian-dbw)

Labels

CL-Test Indicates that a PR should be marked as a test change in the Change Log

Projects

None yet

Milestone

6.2.0-preview.3

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

3 participants

@daxian-dbw @adityapatwardhan @SteveL-MSFT
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402520 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.