-
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #105 from rbaker26/v2.0.1-rc
Version 2.0.1 Release
- Loading branch information
Showing
251 changed files
with
3,902 additions
and
947 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,25 @@ | ||
|
||
name: Add Benchmark Results | ||
on: [pull_request] | ||
jobs: | ||
build: | ||
name: Build | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-dotnet@v1 | ||
with: | ||
dotnet-version: '3.1.x' # SDK Version to use; x will use the latest version of the 3.1 channe | ||
- name: build project | ||
run: | ||
dotnet build SAP1EMU.Benchmarks --configuration Release | ||
- name: run benchamrks | ||
run: dotnet run --project SAP1EMU.Benchmarks --no-build --configuration Release | ||
- name: copy report | ||
run: cp BenchmarkDotNet.Artifacts/results/SAP1EMU.Benchmarks.EngineBenchmark-report-github.md .github/workflows/ | ||
# && cp ./SAP1EMU.Benchmarks/bin/Release/netcoreapp3.1/BenchmarkDotNet.Artifacts/results/SAP1EMU.Benchmarks.EngineBenchmark-report-github.md . | ||
- uses: harupy/comment-on-pr@master | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
filename: SAP1EMU.Benchmarks.EngineBenchmark-report-github.md |
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,12 +1,13 @@ | ||
language: csharp | ||
solution: SAP1EMU-no-gui.sln | ||
solution: SAP1EMU.sln | ||
mono: none | ||
dotnet: 3.1 | ||
script: | ||
- dotnet build SAP1EMU-no-gui.sln | ||
- dotnet test SAP1EMU-no-gui.sln | ||
- dotnet build SAP1EMU.sln | ||
- dotnet test SAP1EMU.Lib.Test -v n --no-build --collect:"XPlat Code Coverage" | ||
- dotnet test SAP1EMU.CLI.Test -v n --no-build --collect:"XPlat Code Coverage" | ||
- dotnet test SAP1EMU.Assembler.Test -v n --no-build --collect:"XPlat Code Coverage" | ||
- dotnet test SAP1EMU.Engine.Test -v n --no-build --collect:"XPlat Code Coverage" | ||
|
||
after_success: | ||
- cd SAP1EMU.Lib.Test/ | ||
- dotnet add package coverlet.collector | ||
- dotnet test --collect:"XPlat Code Coverage" | ||
- bash <(curl -s https://codecov.io/bash) | ||
- bash <(curl -s https://codecov.io/bash) |
This file was deleted.
Oops, something went wrong.
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,20 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
|
||
<PropertyGroup> | ||
<TargetFramework>netcoreapp3.1</TargetFramework> | ||
|
||
<IsPackable>false</IsPackable> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.5.0" /> | ||
<PackageReference Include="MSTest.TestAdapter" Version="2.1.0" /> | ||
<PackageReference Include="MSTest.TestFramework" Version="2.1.0" /> | ||
<PackageReference Include="coverlet.collector" Version="1.2.0" /> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<ProjectReference Include="..\SAP1EMU.Assembler\SAP1EMU.Assembler.csproj" /> | ||
</ItemGroup> | ||
|
||
</Project> |
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 @@ | ||
using Microsoft.VisualStudio.TestTools.UnitTesting; | ||
|
||
namespace SAP1EMU.Assembler.Test | ||
{ | ||
[TestClass] | ||
public class UnitTest1 | ||
{ | ||
[TestMethod] | ||
public void TestMethod1() | ||
{ | ||
} | ||
} | ||
} |
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,109 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Text; | ||
|
||
using BenchmarkDotNet.Attributes; | ||
|
||
using SAP1EMU.Engine; | ||
using SAP1EMU.Lib; | ||
|
||
namespace SAP1EMU.Benchmarks | ||
{ | ||
public class EngineBenchmark | ||
{ | ||
|
||
RAMProgram RP_HLT { get; set; } | ||
RAMProgram RP_LDA170 { get; set; } | ||
RAMProgram RP_FIB{ get; set; } | ||
IDecoder _decoder = new InstructionDecoder(); | ||
|
||
[GlobalSetup] | ||
public void GlobalSetup() | ||
{ | ||
RP_HLT = new RAMProgram(new List<string>() { | ||
"11110000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000" | ||
}); | ||
|
||
RP_LDA170 = new RAMProgram(new List<string>() { | ||
"00001111", | ||
"11100000", | ||
"11110000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"00000000", | ||
"10101010", | ||
}); | ||
|
||
RP_FIB = new RAMProgram(new List<string>() { | ||
"00001110", | ||
"00011111", | ||
"00111111", | ||
"00001111", | ||
"00111110", | ||
"00001101", | ||
"00011100", | ||
"00111101", | ||
"10011010", | ||
"01000000", | ||
"11100000", | ||
"11110000", | ||
"00000001", | ||
"11111001", | ||
"00000001", | ||
"00000001", | ||
}); | ||
} | ||
|
||
|
||
[Benchmark(Baseline = true)] | ||
public void EngineRun_HLT() | ||
{ | ||
EngineProc engine = new EngineProc(); | ||
|
||
engine.Init(RP_HLT, _decoder); | ||
engine.Run(); | ||
} | ||
|
||
[Benchmark] | ||
public void EngineRun_LDA170() | ||
{ | ||
EngineProc engine = new EngineProc(); | ||
|
||
engine.Init(RP_LDA170, _decoder); | ||
engine.Run(); | ||
} | ||
|
||
[Benchmark] | ||
public void EngineRun_FIB5() | ||
{ | ||
EngineProc engine = new EngineProc(); | ||
|
||
engine.Init(RP_FIB, _decoder); | ||
engine.Run(); | ||
} | ||
} | ||
} |
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 @@ | ||
using System; | ||
|
||
using BenchmarkDotNet.Running; | ||
|
||
namespace SAP1EMU.Benchmarks | ||
{ | ||
class Program | ||
{ | ||
static void Main(string[] args) | ||
{ | ||
BenchmarkRunner.Run<EngineBenchmark>(); | ||
} | ||
} | ||
} |
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,16 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
|
||
<PropertyGroup> | ||
<OutputType>Exe</OutputType> | ||
<TargetFramework>netcoreapp3.1</TargetFramework> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="BenchmarkDotNet" Version="0.12.1" /> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<ProjectReference Include="..\SAP1EMU.Engine\SAP1EMU.Engine.csproj" /> | ||
</ItemGroup> | ||
|
||
</Project> |
Oops, something went wrong.