Commit Graph

61 Commits

Author SHA1 Message Date
Matt Larsen
43131ee02b Adding comments about CAS 2016-03-08 09:58:20 -08:00
Matt Larsen
40b6db7eee Inserted missing , 2016-03-08 09:51:50 -08:00
Matt Larsen
3b46706e1f Adding compare and swap and removing unsigned atomics 2016-03-08 09:41:02 -08:00
Matt Larsen
12632de34b Casting Uint64 to long long 2016-03-04 15:17:56 -08:00
Matt Larsen
ecc12dddb7 using reinterpret cast and removing warning from atomic array test 2016-03-04 14:46:45 -08:00
Matt Larsen
72f2549bb9 Removing shadow variable 2016-03-04 12:12:25 -08:00
Matt Larsen
f3c7f188ee Fixing problem with function signatures matching long * to int * 2016-03-04 11:52:52 -08:00
Matt Larsen
733edc8325 changing MS method signatures to long instead of int 2016-03-04 11:13:53 -08:00
Matt Larsen
47452d82bc fixing typo 2016-03-04 10:49:43 -08:00
Matt Larsen
6d63961311 Misplaced bracket 2016-03-04 10:42:07 -08:00
Matt Larsen
da66ea6a15 Refactoring TBB atomics 2016-03-04 10:18:35 -08:00
Matt Larsen
f0f8f0b556 attempt 6 2016-03-03 23:36:21 -05:00
Matt Larsen
5df9088e1d Adding volatile 2016-03-03 23:13:26 -05:00
Matt Larsen
25604a0288 Another typo 2016-03-03 22:46:15 -05:00
Matt Larsen
4a28124658 Fixing typo 2016-03-03 22:17:29 -05:00
Matt Larsen
29ca4f38f6 Attempting type match 2016-03-03 19:42:35 -05:00
Matt Larsen
1448d0d3b4 Adding another typename 2016-03-03 16:04:04 -05:00
Matt Larsen
23e801da55 Adding typename 2016-03-03 15:34:44 -05:00
Matt Larsen
f0c20903b3 Sorting out iterator type 2016-03-03 15:30:28 -05:00
mclarsen
78888e6542 Testing Interlock exchange 2016-03-02 13:53:28 -08:00
mclarsen
ca37b2e9cb Fixed compiler error with atomics 2016-02-10 08:21:38 -08:00
Matt Larsen
2baac9cd8b initial commit of atomic adds 2016-02-10 07:51:31 -08:00
Sujin Philip
6efc1920df Fix VTKM_VECTORIZATION_IN_LOOP placement
It is only applicable on the statement on following line.
2016-01-25 10:59:08 -05:00
Robert Maynard
b8e5923ae1 FunctorsTBB now uses VTKM_VECTORIZATION_X macros everywhere. 2016-01-12 08:43:06 -05:00
Robert Maynard
c7756c78bb TBB SortByKey works now when the key is a ArrayHandleZip.
The issue was that the temporary index array storage container
was the same as the input ArrayHandleZip which is not correct.
2016-01-04 16:55:47 -05:00
Robert Maynard
c70da5fc23 Extend vtkm::DeviceAdapterTraits to include a unique numeric identifier.
Previously each device adapter only had a unique string name. This was
not the best when it came to developing data structures to track the status
of a given device at runtime.

This adds in a unique numeric identifier to each device adapter. This will
allow classes to easily create bitmasks / lookup tables for the validity of
devices.
2015-12-16 11:18:52 -05:00
Robert Maynard
bfb6c26a98 Simplify the design of vectorization support.
Remove the configured file variables, as that causes problems
when using an installed version of VTK-m.
2015-12-01 11:37:41 -05:00
Robert Maynard
4ceb111a68 Enable vectorization inside the Serial and TBB backends. 2015-11-25 15:59:13 -05:00
Robert Maynard
8816642dfd Move algorithms out of DeviceAdapterAlgorithmGeneral to reduce compilation size 2015-10-26 17:22:49 -04:00
Robert Maynard
c78e54facc Move algorithms out of DeviceAdapterAlgorithmTBB to reduce compilation size. 2015-10-26 09:47:13 -04:00
Robert Maynard
8de216c088 Propagate vtkm::Id3 scheduling down to the ThreadIndex classes.
This now allows for even more efficient construction of uniform point
coordinates when running under the 3d scheduler, since we don't need to go
from 3d index to flat index to 3d index, instead we stay in 3d index
2015-10-20 09:29:41 -04:00
Robert Maynard
b1c96381de Merge branch 'multiple_backend_example' into 'master'
Correct the tbb install rules when tbb is disabled.

See merge request !201
2015-09-17 14:04:37 -04:00
Robert Maynard
0b97d4c458 Correct the tbb install rules when tbb is disabled. 2015-09-17 13:59:26 -04:00
Robert Maynard
9b877ef49b Merge topic 'multiple_backend_example'
fd685210 Always install all device headers even when device isn't enabled.
b1663b24 Add an example of using multiple backends from a single translation unit.
fc0ff69d Methods with try/catch need to be host only.
4d635d64 DeviceAdapter Tags now always exist, and contain if the device is valid.
cf32b430 Teach Configure.h to store if TBB and CUDA are enabled.

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Kenneth Moreland <kmorel@sandia.gov>
Merge-request: !198
2015-09-17 09:49:49 -04:00
Robert Maynard
fd68521066 Always install all device headers even when device isn't enabled.
vtkm_declare_headers now is able to not test headers, by using the
TESTABLE keyword.
2015-09-17 09:28:21 -04:00
Robert Maynard
fc0ff69d04 Methods with try/catch need to be host only.
When compiling with cuda and tbb enabled in a single translation unit you
need to make sure all try/catch blocks are marked as host only otherwise
the cuda compiler will error out.
2015-09-17 09:28:21 -04:00
Robert Maynard
4d635d642b DeviceAdapter Tags now always exist, and contain if the device is valid.
Previously it was really hard to verify if a device adapter was valid. Since
you would have to check for the existence of the tag. Now the tag always
exists, but instead you query the traits of the DeviceAdapter to see if
it is a valid adapter.

This makes compiling with multiple backends alot easier.
2015-09-17 09:28:21 -04:00
Kenneth Moreland
e23649d290 Fix use of ArrayHandleCounting in TBB device adapter 2015-09-15 14:19:10 -06:00
Robert Maynard
fd982f1b93 Don't use guards in parallel_sort as it doesn't use vtkm configure. 2015-08-13 10:50:17 -04:00
Robert Maynard
ab59e34a2f Rename pragma header guard so it makes sense for tbb and thrust.
Boost is not the only thirdparty that we are supressing warnings for, so
make the name more generic.
2015-08-13 09:04:23 -04:00
Robert Maynard
8204db2f6a Use VTKM_BOOST_PRE_INCLUDE around thrust headers too. 2015-08-13 08:26:41 -04:00
Kenneth Moreland
923fac45dd Allow TBB back to version 4.0.
Robert Maynard tells me that the TBB backend has been tried on versions
of TBB back to 4.0. Since the patch appears to work across them, allow
those versions too.
2015-08-04 10:13:43 -06:00
Kenneth Moreland
ce8ecf9e8b Don't use patched version of TBB on newer versions.
We have a patched version of TBB's parallel_for.h in our files that
fixes a problem with using std::swap. This issue has since been fixed in
TBB, so for newer versions we should revert back to TBB's
implementation.
2015-08-04 09:14:24 -06:00
Kenneth Moreland
21b3b318ba Always disable conversion warnings when including boost header files
On one of my compile platforms, GCC was giving conversion warnings from
any boost include that was not wrapped in pragmas to disable conversion
warnings. To make things easier and more robust, I created a pair of
macros, VTKM_BOOST_PRE_INCLUDE and VTKM_BOOST_POST_INCLUDE, that should
be wrapped around any #include of a boost header file.
2015-07-30 17:40:40 -06:00
Kenneth Moreland
57d64f4a20 Use ptrdiff_t instead of size_t with TBB iterators.
Math on random iterators needs signed numbers, otherwise signed/unsigned
warnings can occur.
2015-07-29 19:13:30 -06:00
Kenneth Moreland
be045d7a77 Fix warnings about implicit conversions in MSVC.
These occur in the TBB device adapter code.
2015-07-28 14:10:18 -06:00
Robert Maynard
765cc36ba5 Guard against tbb including windows.h in a damaging fashion.
tbb includes windows.h, and doesn't use the NOMINMAX so we need to do
that ourselves so that we can use std::min/max and limits<T>::min/max.

At the same we also define WIN32_LEAN_AND_MEAN so that the total number of
macros that windows.h defines is reduced.
2015-07-15 09:51:46 -04:00
Robert Maynard
c28ca7aa41 Up the default tbb grain size, and use the grain size everywhere. 2015-07-09 15:51:29 -04:00
Kenneth Moreland
4fc3626712 Fix compiler directives for icc
The Intel icc compiler tries to pretend it is gcc, but it sometimes
behaves differently. Add more explicit checks for what compiler is
being used.
2015-07-06 10:35:06 -06:00
Sujin Philip
273281f581 Fix Parallel Scan implementation for TBB Device
The previous implementation assumed the identity value to be zero, which does
not work for multiplication. Changed the interface to require an initial value
for Exclusive Scan with custom operator (TBB Device only, for now).
2015-06-24 09:24:58 -04:00