forked from HDFGroup/hdf5
-
Notifications
You must be signed in to change notification settings - Fork 3
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
Support multi-threaded H5VL operations #7
Closed
mattjala
wants to merge
40
commits into
LifeboatLLC:1_14_2_multithread
from
mattjala:multithread_h5vl_2
Closed
Changes from all commits
Commits
Show all changes
40 commits
Select commit
Hold shift + click to select a range
444a986
Support API tests with autotools
mattjala 054bf12
Support parallel execution of API tests
mattjala 1fabd29
Integrate API tests with framework
mattjala 417737c
Add testmthdf with MT VL tests
mattjala 9a69086
Disable free list check when multithread enabled
mattjala 618e3eb
Implement MT Native Wrapper VOL
mattjala 1d1854e
Implement MT passthru wrapper VOL
mattjala e80d8be
Make registration of optional VOL ops locally threadsafe
mattjala 04336f9
Make H5VL object ref counts atomic
mattjala 4e1ec36
Add additional const qualifiers for connector info
mattjala ae7de28
Treat global VOL IDs in multi-threadsafe manner
mattjala 8fd993c
Implement threadsafe search for existing connector
mattjala 43ad06e
File open threadsafety
mattjala caab99e
Properly initialize atomic variables
mattjala 88c6e79
Acquire global lock duirng dyn ops/H5T routines
mattjala c2875c0
Fix app ref count error
mattjala af02315
Acquire global lock on entry to non threadsafe VOL
mattjala 5a78e84
Refcount VOL wrap context atomically
mattjala 29adc33
Initialize properly when H5VL_NATIVE used early
mattjala 3b445ea
Fix API context lib state copy
mattjala fa26e60
Check arguments in get_wrap_ctx()
mattjala fb97a90
Free vol obj memory if creation fails
mattjala 373e5fc
Check VOL obj rc during free in threadsafe manner
mattjala 75373bc
Remove global mutex from VOL API calls
mattjala 5a38874
Remove global mutex from H5VL.c
mattjala 5cb8f35
Adding missing locks around ID releases
mattjala 42e2722
Guard ID iteration in connector search
mattjala bc8e136
Remove global lock from passthrough VOL callbacks
mattjala 5d63e09
Fix deadlock due to bad exit macro
mattjala 2837e61
Skip file open fail test for non-native VOLs
mattjala c488fe2
Add test workflow
mattjala fcb7c2a
Modify README to allow version parsing
mattjala 1a58367
Test single/multi thread in CI
mattjala 73b6a36
Remove unnecessary includes from MT wrapper VOLs
mattjala 1bab9a0
Remove unnecessary test use of dyn op registration VOL
mattjala 83f7cb4
Clarify autotools helper macro
mattjala 3f05a46
Move atomic type specification into macros
mattjala c599c85
Add Makefile.am to thread test subdirs
mattjala 5748722
Add TestFrameworkFlags param to AddTest
mattjala 2d124c5
Rework testframe to use framework flags
mattjala File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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,103 @@ | ||
name: Build and Test Multithreaded HDF5 Library | ||
|
||
on: | ||
push: | ||
branches: | ||
- '*' | ||
|
||
env: | ||
HDF5TestExpress: 1 | ||
|
||
jobs: | ||
build-and-test: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
api_tests: ["--enable-api-tests", "--disable-api-tests"] | ||
multi_thread: ["--enable-multithread --disable-hl", "--disable-multithread --enable-threadsafe --disable-hl", "--disable-multithread --disable-threadsafe"] | ||
build_mode: ["production", "debug"] | ||
fail-fast: false | ||
|
||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up autotools | ||
run: | | ||
sudo apt install automake autoconf libtool libtool-bin | ||
sudo apt install libaec0 libaec-dev valgrind | ||
|
||
- name: Configure HDF5 | ||
working-directory: ${{github.workspace}} | ||
run: | | ||
sh ./autogen.sh | ||
./configure --enable-shared --enable-tests ${{ matrix.multi_thread }} ${{ matrix.api_tests }} --enable-build-mode=${{ matrix.build_mode }} | ||
|
||
- name: Build HDF5 | ||
working-directory: ${{github.workspace}} | ||
run: | | ||
make -j | ||
|
||
- name: API Tests - Native (Single thread) | ||
if: matrix.api_tests == '--enable-api-tests' | ||
working-directory: ${{github.workspace}} | ||
run: | | ||
valgrind ./test/API/api_tests -maxthreads 1 | ||
|
||
- name: API Tests (Multi thread) | ||
if: matrix.api_tests == '--enable-api-tests' && matrix.multi_thread == '--enable-multithread --disable-hl' | ||
working-directory: ${{github.workspace}} | ||
run: | | ||
valgrind ./test/API/api_tests -maxthreads 16 | ||
|
||
- name: API Tests - MT Native Wrapper (Single thread) | ||
if: matrix.api_tests == '--enable-api-tests' && matrix.multi_thread == '--enable-multithread --disable-hl' | ||
working-directory: ${{github.workspace}} | ||
env: | ||
HDF5_PLUGIN_PATH: ${{github.workspace}}/test/.libs | ||
HDF5_VOL_CONNECTOR: "mt_native_wrapper_vol_connector" | ||
run: | | ||
valgrind ./test/API/api_tests -maxthreads 1 | ||
|
||
- name: API Tests - MT Native Wrapper (Multi thread) | ||
if: matrix.api_tests == '--enable-api-tests' && matrix.multi_thread == '--enable-multithread --disable-hl' | ||
working-directory: ${{github.workspace}} | ||
env: | ||
HDF5_PLUGIN_PATH: ${{github.workspace}}/test/.libs | ||
HDF5_VOL_CONNECTOR: "mt_native_wrapper_vol_connector" | ||
run: | | ||
valgrind ./test/API/api_tests -maxthreads 16 | ||
|
||
- name: API Tests - MT Passthru Wrapper (Single thread) | ||
if: matrix.api_tests == '--enable-api-tests' && matrix.multi_thread == '--enable-multithread --disable-hl' | ||
working-directory: ${{github.workspace}} | ||
env: | ||
HDF5_PLUGIN_PATH: ${{github.workspace}}/test/.libs | ||
HDF5_VOL_CONNECTOR: "mt_passthru_wrapper_vol_connector under_vol=0\\;under_info={}" | ||
run: | | ||
valgrind ./test/API/api_tests -maxthreads 1 | ||
|
||
- name: API Tests - MT Passthru Wrapper (Multi thread) | ||
if: matrix.api_tests == '--enable-api-tests' && matrix.multi_thread == '--enable-multithread --disable-hl' | ||
working-directory: ${{github.workspace}} | ||
env: | ||
HDF5_PLUGIN_PATH: ${{github.workspace}}/test/.libs | ||
HDF5_VOL_CONNECTOR: "mt_passthru_wrapper_vol_connector under_vol=0\\;under_info={}" | ||
run: | | ||
valgrind ./test/API/api_tests -maxthreads 16 | ||
|
||
- name: MT VL Tests (Single thread) | ||
working-directory: ${{github.workspace}}/test/ | ||
run: | | ||
valgrind ./threads/testmthdf5 -maxthreads 1 | ||
|
||
- name: MT VL Tests (Multi thread) | ||
if: matrix.multi_thread == '--enable-multithread --disable-hl' | ||
working-directory: ${{github.workspace}}/test/ | ||
run: | | ||
valgrind ./threads/testmthdf5 -maxthreads 16 | ||
|
||
- name: Other HDF5 Tests | ||
working-directory: ${{github.workspace}} | ||
run: | | ||
make check |
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
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Already below past the dashed-line separator
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One of the h5repack tests parses the current version of HDF5 from the third word in the README file and breaks if this is moved.