Skip to content

Commit

Permalink
Update CI to macos-13
Browse files Browse the repository at this point in the history
  • Loading branch information
MarcusTomlinson committed Nov 18, 2024
1 parent dda66d7 commit a291e15
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/build_and_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macos-12, ubuntu-20.04, windows-2019]
os: [macos-13, ubuntu-20.04, windows-2019]

steps:
- if: matrix.os == 'windows-2019'
Expand All @@ -26,10 +26,10 @@ jobs:
name: Configure MSVC (Windows)
uses: ilammy/msvc-dev-cmd@v1

- if: matrix.os == 'macos-12'
- if: matrix.os == 'macos-13'
name: Configure Xcode (MacOS)
run: |
sudo xcode-select -s /Applications/Xcode_13.1.app/Contents/Developer
sudo xcode-select -s /Applications/Xcode_14.1.app/Contents/Developer
- name: Configure Python
uses: actions/setup-python@v4
Expand Down
11 changes: 11 additions & 0 deletions include/dspatch/Component.h
Original file line number Diff line number Diff line change
Expand Up @@ -591,6 +591,17 @@ inline void Component::_GetOutputParallel( int bufferNo, int fromOutput, int toI
if ( !signal.has_value() )
{
toBus.ClearValue( toInput );
if ( ref.total != 1 )
{
if ( ++ref.count != ref.total )
{
ref.readyFlag.Set();
}
else
{
ref.count = 0;
}
}
return;
}

Expand Down
5 changes: 5 additions & 0 deletions tests/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -909,6 +909,8 @@ TEST_CASE( "TenThousandComponents" )

int iterationCount = 1000;

double total_ms = 0.0;

for ( unsigned int i = 0; i <= std::thread::hardware_concurrency(); ++i )
{
circuit->SetBufferCount( i );
Expand All @@ -928,11 +930,14 @@ TEST_CASE( "TenThousandComponents" )
end = std::chrono::high_resolution_clock::now();

diff_ms = std::chrono::duration_cast<std::chrono::microseconds>( end - begin ).count() / 1000.0;
total_ms += diff_ms / iterationCount;

std::cout << i << "x Buffers, " << j << "x Threads, 10000x Components: " << diff_ms / iterationCount << "ms\n";
}
}

std::cout << "Average: " << total_ms / pow( (double)std::thread::hardware_concurrency() + 1.0, 2.0 ) << "ms\n";

begin = std::chrono::high_resolution_clock::now();

circuit.reset();
Expand Down

0 comments on commit a291e15

Please sign in to comment.