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

Miscellaneous event tweaks #6725

Merged
merged 4 commits into from
Aug 9, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
66 changes: 33 additions & 33 deletions src/Framework/MSBuildEventSource.cs
Original file line number Diff line number Diff line change
Expand Up @@ -103,100 +103,100 @@ public void EvaluateConditionStop(string condition, bool result)
/// <summary>
/// Call this method to notify listeners of how the project data was evaluated.
/// </summary>
/// <param name="projectFile">Relevant information about where in the run of the progam it is.</param>
[Event(11, Keywords = Keywords.All)]
/// <param name="projectFile">Filename of the project being evaluated.</param>
Copy link
Member

Choose a reason for hiding this comment

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

I don't think the previous comment was particularly helpful, but I'm not sure this one is either. It just sounds like an English version of "projectFile for Evaluate," which you could get from the parameter's name and the function name. Be nice if we could just drop them, but I'm guessing some style checker would complain.

[Event(11, Keywords = Keywords.All | Keywords.PerformanceLog)]
public void EvaluateStart(string projectFile)
{
WriteEvent(11, projectFile);
}

/// <param name="projectFile">Relevant information about where in the run of the progam it is.</param>
[Event(12, Keywords = Keywords.All)]
public void EvaluatePass0Start(string projectFile)
/// <param name="projectFile">Filename of the project being evaluated.</param>
[Event(12, Keywords = Keywords.All | Keywords.PerformanceLog)]
public void EvaluateStop(string projectFile)
{
WriteEvent(12, projectFile);
}

/// <param name="projectFile">Relevant information about where in the run of the progam it is.</param>
/// <param name="projectFile">Filename of the project being evaluated.</param>
[Event(13, Keywords = Keywords.All)]
public void EvaluatePass0Stop(string projectFile)
public void EvaluatePass0Start(string projectFile)
{
WriteEvent(13, projectFile);
}

/// <param name="projectFile">Relevant information about where in the run of the progam it is.</param>
/// <param name="projectFile">Filename of the project being evaluated.</param>
[Event(14, Keywords = Keywords.All)]
public void EvaluatePass1Start(string projectFile)
public void EvaluatePass0Stop(string projectFile)
{
WriteEvent(14, projectFile);
}

/// <param name="projectFile">Relevant information about where in the run of the progam it is.</param>
/// <param name="projectFile">Filename of the project being evaluated.</param>
[Event(15, Keywords = Keywords.All)]
public void EvaluatePass1Stop(string projectFile)
public void EvaluatePass1Start(string projectFile)
{
WriteEvent(15, projectFile);
}

/// <param name="projectFile">Relevant information about where in the run of the progam it is.</param>
/// <param name="projectFile">Filename of the project being evaluated.</param>
[Event(16, Keywords = Keywords.All)]
public void EvaluatePass2Start(string projectFile)
public void EvaluatePass1Stop(string projectFile)
{
WriteEvent(16, projectFile);
}

/// <param name="projectFile">Relevant information about where in the run of the progam it is.</param>
/// <param name="projectFile">Filename of the project being evaluated.</param>
[Event(17, Keywords = Keywords.All)]
public void EvaluatePass2Stop(string projectFile)
public void EvaluatePass2Start(string projectFile)
{
WriteEvent(17, projectFile);
}

/// <param name="projectFile">Relevant information about where in the run of the progam it is.</param>
/// <param name="projectFile">Filename of the project being evaluated.</param>
[Event(18, Keywords = Keywords.All)]
public void EvaluatePass3Start(string projectFile)
public void EvaluatePass2Stop(string projectFile)
{
WriteEvent(18, projectFile);
}

/// <param name="projectFile">Relevant information about where in the run of the progam it is.</param>
/// <param name="projectFile">Filename of the project being evaluated.</param>
[Event(19, Keywords = Keywords.All)]
public void EvaluatePass3Stop(string projectFile)
public void EvaluatePass3Start(string projectFile)
{
WriteEvent(19, projectFile);
}

/// <param name="projectFile">Relevant information about where in the run of the progam it is.</param>
/// <param name="projectFile">Filename of the project being evaluated.</param>
[Event(20, Keywords = Keywords.All)]
public void EvaluatePass4Start(string projectFile)
public void EvaluatePass3Stop(string projectFile)
{
WriteEvent(20, projectFile);
}

/// <param name="projectFile">Relevant information about where in the run of the progam it is.</param>
/// <param name="projectFile">Filename of the project being evaluated.</param>
[Event(21, Keywords = Keywords.All)]
public void EvaluatePass4Stop(string projectFile)
public void EvaluatePass4Start(string projectFile)
{
WriteEvent(21, projectFile);
}

/// <param name="projectFile">Relevant information about where in the run of the progam it is.</param>
/// <param name="projectFile">Filename of the project being evaluated.</param>
[Event(22, Keywords = Keywords.All)]
public void EvaluatePass5Start(string projectFile)
public void EvaluatePass4Stop(string projectFile)
{
WriteEvent(22, projectFile);
}

/// <param name="projectFile">Relevant information about where in the run of the progam it is.</param>
/// <param name="projectFile">Filename of the project being evaluated.</param>
[Event(23, Keywords = Keywords.All)]
public void EvaluatePass5Stop(string projectFile)
public void EvaluatePass5Start(string projectFile)
{
WriteEvent(23, projectFile);
}

/// <param name="projectFile">Relevant information about where in the run of the progam it is.</param>
/// <param name="projectFile">Filename of the project being evaluated.</param>
[Event(24, Keywords = Keywords.All)]
public void EvaluateStop(string projectFile)
public void EvaluatePass5Stop(string projectFile)
{
WriteEvent(24, projectFile);
}
Expand Down Expand Up @@ -278,15 +278,15 @@ public void RarLogResultsStop()
/// <summary>
/// Call this method to notify listeners of profiling for the function that parses an XML document into a ProjectRootElement.
/// </summary>
/// <param name="projectFileName">Relevant information about where in the run of the progam it is.</param>
[Event(33, Keywords = Keywords.All | Keywords.PerformanceLog)]
/// <param name="projectFileName">Filename of the project being evaluated.</param>
[Event(33, Keywords = Keywords.All)]
public void ParseStart(string projectFileName)
{
WriteEvent(33, projectFileName);
}

/// <param name="projectFileName">Relevant information about where in the run of the progam it is.</param>
[Event(34, Keywords = Keywords.All | Keywords.PerformanceLog)]
/// <param name="projectFileName">Filename of the project being evaluated.</param>
[Event(34, Keywords = Keywords.All)]
Copy link
Member

Choose a reason for hiding this comment

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

What does Keywords.PerformanceLog do here, and why remove it from ParseStartStop?

Copy link
Member Author

Choose a reason for hiding this comment

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

Events tagged with PerformanceLog are included in the text perf log emitted when configured (#5861).

As to why remove this, I put this in the commit message

It's pretty rare that the XML parse phase of project load is a significant part of evaluation time; it's usually a tiny fraction of overall evaluation.

public void ParseStop(string projectFileName)
{
WriteEvent(34, projectFileName);
Expand Down