This repository has been archived by the owner on Dec 17, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'move-to-dotnet2.0' into 'master'
feat: prepare for release See merge request Linaro/WindowsPerf/wpa-plugin-etl!1
- Loading branch information
Showing
17 changed files
with
1,074 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
*.swp | ||
*.*~ | ||
project.lock.json | ||
.DS_Store | ||
*.pyc | ||
nupkg/ | ||
packages/* | ||
# Visual Studio Code | ||
.vscode | ||
|
||
# Rider | ||
.idea | ||
|
||
# User-specific files | ||
*.suo | ||
*.user | ||
*.userosscache | ||
*.sln.docstates | ||
|
||
# Build results | ||
[Dd]ebug/ | ||
[Dd]ebugPublic/ | ||
[Rr]elease/ | ||
[Rr]eleases/ | ||
x64/ | ||
x86/ | ||
build/ | ||
bld/ | ||
[Bb]in/ | ||
[Oo]bj/ | ||
[Oo]ut/ | ||
msbuild.log | ||
msbuild.err | ||
msbuild.wrn | ||
|
||
# Visual Studio 2015 | ||
.vs/ | ||
TestResult.xml | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# You can override the included template(s) by including variable overrides | ||
# SAST customization: https://docs.gitlab.com/ee/user/application_security/sast/#customizing-the-sast-settings | ||
# Secret Detection customization: https://docs.gitlab.com/ee/user/application_security/secret_detection/#customizing-settings | ||
# Dependency Scanning customization: https://docs.gitlab.com/ee/user/application_security/dependency_scanning/#customizing-the-dependency-scanning-settings | ||
# Container Scanning customization: https://docs.gitlab.com/ee/user/application_security/container_scanning/#customizing-the-container-scanning-settings | ||
# Note that environment variables can be set in several places | ||
# See https://docs.gitlab.com/ee/ci/variables/#cicd-variable-precedence | ||
stages: | ||
- test | ||
sast: | ||
stage: test | ||
include: | ||
- template: Security/SAST.gitlab-ci.yml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
# Contributing Guidelines | ||
|
||
[[_TOC_]] | ||
|
||
# Basic guidelines | ||
|
||
All changes you commit or submit by merge request should follow these simple guidelines: | ||
* Use merge requests. | ||
* Should build without new warnings or errors. Please use the project's solution file to drive the build and test process. | ||
* Please do not squash your Merge Request commits into one commit. Split PR into many meaningful commits, we can review separately. | ||
* Code should be free from profanities in any language. | ||
|
||
# Commits in your merge requests should | ||
|
||
* One commit should represent one meaningful change. E.g. Please do not add a new header file and in the same commit update project solution. | ||
* Have short (72 chars or less) meaningful subjects. | ||
* Separate subject from body with a blank line. | ||
* Use the imperative mood in the subject line. | ||
* Wrap lines at 72 characters if possible (E.g.: URLs are very hard to wrap). | ||
* Use the body to explain what and why you have done something. In most cases, you can leave out details about how a change has been made ( Good commit message examples can be found [here](https://wiki.openstack.org/wiki/GitCommitMessages#Information_in_commit_messages).) | ||
* Your merge request title should contain WindowsPerf JIRA ticket, which is prefixed WPERF-. Note: our GitLab JIRA integration requires developers to add it. | ||
* You can post your MR without JIRA ticket but we will require ticket number to merge. | ||
* WindowsPerf JIRA tickets are in format: WPERF-[0-9]+. | ||
# Advice on merge requests | ||
|
||
* Applying the single responsibility principle to merge requests is always a good idea. Try not to include some additional stuff into the merge request. For example, do not fix any typos other than your current context or do not add a tiny bug fix to a feature. | ||
* Title and description is the first place where you can inform other developers about the changes | ||
* Description of a merge request should always be prepared with the same attention, whether the merge request has a small or huge change. | ||
* Always think that anybody could read your merge request anytime. | ||
* You should build your code and test (if possible) before creating the merge request. | ||
* Both reviewers and the author should be polite in the comments. | ||
|
||
# If you have commit access | ||
|
||
* Do NOT use `git push --force`. | ||
* Use Merge Requests to suggest changes to other maintainers. | ||
|
||
# Testing your changes | ||
|
||
As of right now, unit and integration testing are not implemented in this project, so any | ||
contribution related to tests would be appreciated. | ||
|
||
Before submitting a patch please make sure that the project builds correctly, | ||
and that the plotted graphs match the examples in the [Wiki](https://gitlab.com/Linaro/WindowsPerf/wpa-plugin/-/wikis/Tables) | ||
|
||
# Reporting Bugs | ||
|
||
A good bug report, which is complete and self-contained, enables us to fix the bug. Before you report a bug, please check the list of [issues](https://gitlab.com/Linaro/WindowsPerf/vs-extension/-/issues) and, if possible, try a bleeding edge code (latest source tree commit). | ||
|
||
|
||
# Common LICENSE tags | ||
|
||
(Complete list can be found at: https://spdx.org/licenses) | ||
|
||
| Identifier | Full name | | ||
| ------------ | --------------------------------------- | | ||
| BSD-3-Clause | BSD 3-Clause "New" or "Revised" License | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,25 @@ | ||
|
||
Microsoft Visual Studio Solution File, Format Version 12.00 | ||
# Visual Studio Version 17 | ||
VisualStudioVersion = 17.10.34707.107 | ||
VisualStudioVersion = 17.9.34622.214 | ||
MinimumVisualStudioVersion = 10.0.40219.1 | ||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "wpa-plugin-etl", "wpa-plugin-etl.csproj", "{B7C4374E-0236-4C7C-9565-9A142858F381}" | ||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "wpa-plugin-etl", "wpa-plugin-etl\wpa-plugin-etl.csproj", "{4C34C05A-F6CB-4027-9D41-B3D0DC1F99DB}" | ||
EndProject | ||
Global | ||
GlobalSection(SolutionConfigurationPlatforms) = preSolution | ||
Debug|Any CPU = Debug|Any CPU | ||
Release|Any CPU = Release|Any CPU | ||
EndGlobalSection | ||
GlobalSection(ProjectConfigurationPlatforms) = postSolution | ||
{B7C4374E-0236-4C7C-9565-9A142858F381}.Debug|Any CPU.ActiveCfg = Debug|Any CPU | ||
{B7C4374E-0236-4C7C-9565-9A142858F381}.Debug|Any CPU.Build.0 = Debug|Any CPU | ||
{B7C4374E-0236-4C7C-9565-9A142858F381}.Release|Any CPU.ActiveCfg = Release|Any CPU | ||
{B7C4374E-0236-4C7C-9565-9A142858F381}.Release|Any CPU.Build.0 = Release|Any CPU | ||
{4C34C05A-F6CB-4027-9D41-B3D0DC1F99DB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU | ||
{4C34C05A-F6CB-4027-9D41-B3D0DC1F99DB}.Debug|Any CPU.Build.0 = Debug|Any CPU | ||
{4C34C05A-F6CB-4027-9D41-B3D0DC1F99DB}.Release|Any CPU.ActiveCfg = Release|Any CPU | ||
{4C34C05A-F6CB-4027-9D41-B3D0DC1F99DB}.Release|Any CPU.Build.0 = Release|Any CPU | ||
EndGlobalSection | ||
GlobalSection(SolutionProperties) = preSolution | ||
HideSolutionNode = FALSE | ||
EndGlobalSection | ||
GlobalSection(ExtensibilityGlobals) = postSolution | ||
SolutionGuid = {C4B5BEAE-EE6A-4348-8A91-35F35D7303CA} | ||
SolutionGuid = {8DFBE6EE-B90C-4BD3-BA88-EE4702951389} | ||
EndGlobalSection | ||
EndGlobal |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<Weavers xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="FodyWeavers.xsd"> | ||
<Costura> | ||
<IncludeAssemblies> | ||
Microsoft.Diagnostics.Tracing.TraceEvent | ||
Microsoft.Diagnostics.FastSerialization | ||
Dia2Lib | ||
TraceReloggerLib | ||
</IncludeAssemblies> | ||
</Costura> | ||
</Weavers> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,141 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"> | ||
<!-- This file was generated by Fody. Manual changes to this file will be lost when your project is rebuilt. --> | ||
<xs:element name="Weavers"> | ||
<xs:complexType> | ||
<xs:all> | ||
<xs:element name="Costura" minOccurs="0" maxOccurs="1"> | ||
<xs:complexType> | ||
<xs:all> | ||
<xs:element minOccurs="0" maxOccurs="1" name="ExcludeAssemblies" type="xs:string"> | ||
<xs:annotation> | ||
<xs:documentation>A list of assembly names to exclude from the default action of "embed all Copy Local references", delimited with line breaks</xs:documentation> | ||
</xs:annotation> | ||
</xs:element> | ||
<xs:element minOccurs="0" maxOccurs="1" name="IncludeAssemblies" type="xs:string"> | ||
<xs:annotation> | ||
<xs:documentation>A list of assembly names to include from the default action of "embed all Copy Local references", delimited with line breaks.</xs:documentation> | ||
</xs:annotation> | ||
</xs:element> | ||
<xs:element minOccurs="0" maxOccurs="1" name="ExcludeRuntimeAssemblies" type="xs:string"> | ||
<xs:annotation> | ||
<xs:documentation>A list of runtime assembly names to exclude from the default action of "embed all Copy Local references", delimited with line breaks</xs:documentation> | ||
</xs:annotation> | ||
</xs:element> | ||
<xs:element minOccurs="0" maxOccurs="1" name="IncludeRuntimeAssemblies" type="xs:string"> | ||
<xs:annotation> | ||
<xs:documentation>A list of runtime assembly names to include from the default action of "embed all Copy Local references", delimited with line breaks.</xs:documentation> | ||
</xs:annotation> | ||
</xs:element> | ||
<xs:element minOccurs="0" maxOccurs="1" name="Unmanaged32Assemblies" type="xs:string"> | ||
<xs:annotation> | ||
<xs:documentation>A list of unmanaged 32 bit assembly names to include, delimited with line breaks.</xs:documentation> | ||
</xs:annotation> | ||
</xs:element> | ||
<xs:element minOccurs="0" maxOccurs="1" name="Unmanaged64Assemblies" type="xs:string"> | ||
<xs:annotation> | ||
<xs:documentation>A list of unmanaged 64 bit assembly names to include, delimited with line breaks.</xs:documentation> | ||
</xs:annotation> | ||
</xs:element> | ||
<xs:element minOccurs="0" maxOccurs="1" name="PreloadOrder" type="xs:string"> | ||
<xs:annotation> | ||
<xs:documentation>The order of preloaded assemblies, delimited with line breaks.</xs:documentation> | ||
</xs:annotation> | ||
</xs:element> | ||
</xs:all> | ||
<xs:attribute name="CreateTemporaryAssemblies" type="xs:boolean"> | ||
<xs:annotation> | ||
<xs:documentation>This will copy embedded files to disk before loading them into memory. This is helpful for some scenarios that expected an assembly to be loaded from a physical file.</xs:documentation> | ||
</xs:annotation> | ||
</xs:attribute> | ||
<xs:attribute name="IncludeDebugSymbols" type="xs:boolean"> | ||
<xs:annotation> | ||
<xs:documentation>Controls if .pdbs for reference assemblies are also embedded.</xs:documentation> | ||
</xs:annotation> | ||
</xs:attribute> | ||
<xs:attribute name="IncludeRuntimeReferences" type="xs:boolean"> | ||
<xs:annotation> | ||
<xs:documentation>Controls if runtime assemblies are also embedded.</xs:documentation> | ||
</xs:annotation> | ||
</xs:attribute> | ||
<xs:attribute name="UseRuntimeReferencePaths" type="xs:boolean"> | ||
<xs:annotation> | ||
<xs:documentation>Controls whether the runtime assemblies are embedded with their full path or only with their assembly name.</xs:documentation> | ||
</xs:annotation> | ||
</xs:attribute> | ||
<xs:attribute name="DisableCompression" type="xs:boolean"> | ||
<xs:annotation> | ||
<xs:documentation>Embedded assemblies are compressed by default, and uncompressed when they are loaded. You can turn compression off with this option.</xs:documentation> | ||
</xs:annotation> | ||
</xs:attribute> | ||
<xs:attribute name="DisableCleanup" type="xs:boolean"> | ||
<xs:annotation> | ||
<xs:documentation>As part of Costura, embedded assemblies are no longer included as part of the build. This cleanup can be turned off.</xs:documentation> | ||
</xs:annotation> | ||
</xs:attribute> | ||
<xs:attribute name="LoadAtModuleInit" type="xs:boolean"> | ||
<xs:annotation> | ||
<xs:documentation>Costura by default will load as part of the module initialization. This flag disables that behavior. Make sure you call CosturaUtility.Initialize() somewhere in your code.</xs:documentation> | ||
</xs:annotation> | ||
</xs:attribute> | ||
<xs:attribute name="IgnoreSatelliteAssemblies" type="xs:boolean"> | ||
<xs:annotation> | ||
<xs:documentation>Costura will by default use assemblies with a name like 'resources.dll' as a satellite resource and prepend the output path. This flag disables that behavior.</xs:documentation> | ||
</xs:annotation> | ||
</xs:attribute> | ||
<xs:attribute name="ExcludeAssemblies" type="xs:string"> | ||
<xs:annotation> | ||
<xs:documentation>A list of assembly names to exclude from the default action of "embed all Copy Local references", delimited with |</xs:documentation> | ||
</xs:annotation> | ||
</xs:attribute> | ||
<xs:attribute name="IncludeAssemblies" type="xs:string"> | ||
<xs:annotation> | ||
<xs:documentation>A list of assembly names to include from the default action of "embed all Copy Local references", delimited with |.</xs:documentation> | ||
</xs:annotation> | ||
</xs:attribute> | ||
<xs:attribute name="ExcludeRuntimeAssemblies" type="xs:string"> | ||
<xs:annotation> | ||
<xs:documentation>A list of runtime assembly names to exclude from the default action of "embed all Copy Local references", delimited with |</xs:documentation> | ||
</xs:annotation> | ||
</xs:attribute> | ||
<xs:attribute name="IncludeRuntimeAssemblies" type="xs:string"> | ||
<xs:annotation> | ||
<xs:documentation>A list of runtime assembly names to include from the default action of "embed all Copy Local references", delimited with |.</xs:documentation> | ||
</xs:annotation> | ||
</xs:attribute> | ||
<xs:attribute name="Unmanaged32Assemblies" type="xs:string"> | ||
<xs:annotation> | ||
<xs:documentation>A list of unmanaged 32 bit assembly names to include, delimited with |.</xs:documentation> | ||
</xs:annotation> | ||
</xs:attribute> | ||
<xs:attribute name="Unmanaged64Assemblies" type="xs:string"> | ||
<xs:annotation> | ||
<xs:documentation>A list of unmanaged 64 bit assembly names to include, delimited with |.</xs:documentation> | ||
</xs:annotation> | ||
</xs:attribute> | ||
<xs:attribute name="PreloadOrder" type="xs:string"> | ||
<xs:annotation> | ||
<xs:documentation>The order of preloaded assemblies, delimited with |.</xs:documentation> | ||
</xs:annotation> | ||
</xs:attribute> | ||
</xs:complexType> | ||
</xs:element> | ||
</xs:all> | ||
<xs:attribute name="VerifyAssembly" type="xs:boolean"> | ||
<xs:annotation> | ||
<xs:documentation>'true' to run assembly verification (PEVerify) on the target assembly after all weavers have been executed.</xs:documentation> | ||
</xs:annotation> | ||
</xs:attribute> | ||
<xs:attribute name="VerifyIgnoreCodes" type="xs:string"> | ||
<xs:annotation> | ||
<xs:documentation>A comma-separated list of error codes that can be safely ignored in assembly verification.</xs:documentation> | ||
</xs:annotation> | ||
</xs:attribute> | ||
<xs:attribute name="GenerateXsd" type="xs:boolean"> | ||
<xs:annotation> | ||
<xs:documentation>'false' to turn off automatic generation of the XML Schema file.</xs:documentation> | ||
</xs:annotation> | ||
</xs:attribute> | ||
</xs:complexType> | ||
</xs:element> | ||
</xs:schema> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{ | ||
"profiles": { | ||
"Debug": { | ||
"commandName": "Executable", | ||
"executablePath": "C:\\Program Files (x86)\\Windows Kits\\10\\Windows Performance Toolkit\\wpa.exe", | ||
"commandLineArgs": "-nodefault -addsearchdir \"%USERPROFILE%\\devProjects\\wpa-plugin-etl\\wpa-plugin-etl\\bin\\Debug\\netstandard2.0\"" | ||
}, | ||
"Release": { | ||
"commandName": "Executable", | ||
"executablePath": "C:\\Program Files (x86)\\Windows Kits\\10\\Windows Performance Toolkit\\wpa.exe", | ||
"commandLineArgs": "-nodefault -addsearchdir \"%USERPROFILE%\\devProjects\\wpa-plugin-etl\\wpa-plugin-etl\\bin\\Release\\netstandard2.0\"" | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
// BSD 3-Clause License | ||
// | ||
// Copyright (c) 2024, Arm Limited | ||
// All rights reserved. | ||
// | ||
// Redistribution and use in source and binary forms, with or without | ||
// modification, are permitted provided that the following conditions are met: | ||
// | ||
// 1. Redistributions of source code must retain the above copyright notice, this | ||
// list of conditions and the following disclaimer. | ||
// | ||
// 2. Redistributions in binary form must reproduce the above copyright notice, | ||
// this list of conditions and the following disclaimer in the documentation | ||
// and/or other materials provided with the distribution. | ||
// | ||
// 3. Neither the name of the copyright holder nor the names of its | ||
// contributors may be used to endorse or promote products derived from | ||
// this software without specific prior written permission. | ||
// | ||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" | ||
// AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | ||
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE | ||
// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE | ||
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | ||
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR | ||
// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER | ||
// CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, | ||
// OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | ||
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | ||
|
||
using Microsoft.Performance.SDK.Extensibility.DataCooking; | ||
using Microsoft.Performance.SDK.Extensibility; | ||
using Microsoft.Performance.SDK; | ||
using Microsoft.Performance.SDK.Extensibility.DataCooking.SourceDataCooking; | ||
using System.Collections.Generic; | ||
using System.Collections.ObjectModel; | ||
using System.Threading; | ||
|
||
namespace wpa_plugin_etl | ||
{ | ||
public class ReadGPCAppDataCooker : SourceDataCooker<ReadGPCEvent, WpaPluginEtlSourceParser, string> | ||
{ | ||
public static readonly DataCookerPath DataCookerPath = DataCookerPath.ForSource(nameof(WpaPluginEtlSourceParser), nameof(ReadGPCAppDataCooker)); | ||
private readonly List<ReadGPCEvent> eventsList; | ||
|
||
[DataOutput] | ||
public IReadOnlyList<ReadGPCEvent> Events { get; } | ||
|
||
public override string Description => "Passes the ReadGPC event data from app"; | ||
|
||
public ReadGPCAppDataCooker() : base(ReadGPCAppDataCooker.DataCookerPath) | ||
{ | ||
eventsList = new List<ReadGPCEvent>(); | ||
Events = new ReadOnlyCollection<ReadGPCEvent>(eventsList); | ||
} | ||
|
||
public override ReadOnlyHashSet<string> DataKeys => | ||
new ReadOnlyHashSet<string>( | ||
new HashSet<string> | ||
{ | ||
"WindowsPerf App", | ||
nameof(ReadGPCEvent) | ||
}); | ||
|
||
public override DataProcessingResult CookDataElement(ReadGPCEvent data, WpaPluginEtlSourceParser context, CancellationToken cancellationToken) | ||
{ | ||
if (data.Key.IndexOf("WindowsPerf App") != -1) | ||
{ | ||
eventsList.Add(data); | ||
} | ||
return DataProcessingResult.Processed; | ||
} | ||
} | ||
} |
Oops, something went wrong.