There is a limitation in Windows builds using VS2019 where libraries cannot be
bigger than 4GiB. This is normally not an issue but in `VTKm` due to its strong
template usage libraries can reach that size.
The `VTKm` filter library is can easily reach that size and it will halt the
build
This MR tries to avoid reaching those sizes for now by splitting the filter
library into four smaller libraries.
The proposal scheme is:
It splits vtkm-filter into:
- vtkm-common, Classes that are dependencies of other filter libs.
- vtkm-contour, Contour class and its instantiations.
- vtkm-contour, Gradient class and its instantiations.
- vtkm-extra, Classes other than Contour or Gradient that are
not dependencies.
Signed-off-by: Vicente Adolfo Bolea Sanchez <vicente.bolea@kitware.com>
Consumers of VTK-m when enabling of dropping of unused functions
will see VTK-m functions dropped. Previously this didn't happen
as VTK-m didn't build object files with the correct flags for this.
By allowing the linker to remove unused symbols we see a significant
saving the file size of VTK-m tests, examples, and benchmarks.
An OpenMP build of the tests and benchmarks goes from 168MB to
141MB which is roughly a 16% filesize reduction.
Initially I had presumed that these changes would increase link times.
But in measurements the total wall time for compilation of VTK-m has
stayed about the same ( seeing a decrease of 1.5% ). Presumably the
increased computation is offset by the reduction in file writing.
Instead of having to be called for each target you can now
pass multiple targets at once. Do note that if you pass multiple
targets you will need to pass all the sources from those targets
that need to be 'device' compiled.
This is a work around while we wait on requiring CMake 3.15 for all
cuda builds. At that point we can replace this with setting
`requires_static_builds` as part of the EXPORT_PROPERTIES of the
vtkm_cuda target.
This has been tested with the ascent proxy
This is a work around while we wait on requiring CMake 3.15 for all
cuda builds. At that point we can replace this with setting
`cuda_architecture_flags` as part of the EXPORT_PROPERTIES of the
vtkm_cuda target.
This has been tested with the ascent proxy
The VTK-m testing infrastructure isn't public facing so it doesn't
need to be installed or clutter the main VTKmWrappers file.
At the same time I have refactored the code to make it clearer
to understand, and remove unused options.
We want the option name to be clear that it might be applicable for
more than just CUDA. If VTK-m ever supported something like SYCL
it would not be clear that those sources should go in `WRAP_FOR_CUDA`.
Previously an installed version of VTK-m wasn't relocatable as
it had system MPI paths. Additionally the installed vtkm_diy target
would depend on MPI but not `find_package(MPI)`
It is very easy to cause ODR violations with DeviceAdapterTagCuda.
If you include that header from a C++ file and a CUDA file inside
the same program we an ODR violation. The reasons is that the C++
versions will say the tag is invalid, and the CUDA will say the
tag is valid.
The solution to this is that any compilation unit that includes
DeviceAdapterTagCuda from a version of VTK-m that has CUDA enabled
must be invoked by the cuda compiler.
We now have a couple of the examples also being built against
the installed version of VTK-m as a test. This allow us to verify
that VTK-m installs and can be found properly.
The purpose of the TestBuild infrastructure was to confirm that
VTK-m didn't have any lexical issues when it was a pure header
only project. As we now move to have more compiled components
the need for this form of testing is mitigated. Combined
with the issue of TestBuilds causing MSVC issues, we should
just remove this infrastructure.
Also
- Renamed vtkm::cont::make_DeviceAdapterIdFromName to just overload
make_DeviceAdapterId.
- Refactored CMake logic for unit tests
- Since we're now querying the device tracker for the names, they
cannot be all caps.
- Updated usages of InitLogging to use Initialize instead.
- Added changelog.
VTK-m has been updated to replace old per device worklet testing executables with a device
dependent shared library so that it's able to accept a device adapter
at runtime.
Meanwhile, it updates the testing infrastructure APIs. vtkm::cont::testing::Run
function would call ForceDevice when needed and if users need the device
adapter info at runtime, RunOnDevice function would pass the adapter into the functor.
Optional Parser is bumped from 1.3 to 1.7.
Fixes issue #276.
OpenMP tests when run in parallel exhibit negative scaling as we
have N openMP processes each spawning N threads. We speculate that
this causes excessive context switching and swapping and reduces
performance.
Found via `codespell` and `grep`
more typos
includes source typo change and a typo that needs further review
follow-up typos
Follow-up typos
Revert a commit
d393468e Add any OpenGL link targets to test builds
8b9c0f50 Re-add non testable files to test build sources
ffd98463 Load correct file extension in header test build
7c5f44a6 Fix warnings about no symbols
289a4bc1 Differentiate between header files with different extensions
9571c9b5 Fix vtkm_add_header_build_test
Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Robert Maynard <robert.maynard@kitware.com>
Merge-request: !1160
The vtkm_add_header_build_test was changed to identify "valid" header
files that were actually tested and only adding those to the source
list. This was a mistake. A big part of the point of adding headers that
are not tested to the test build sources is to list them to an IDE.