Commit 5448ffb2 authored by Li-Ta Lo's avatar Li-Ta Lo
Browse files

decouple Timer.h from device compiler

parent e90b186b
Pipeline #251273 failed with stages
in 29 minutes and 44 seconds
......@@ -7,6 +7,8 @@
// the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
// PURPOSE. See the above copyright notice for more information.
//============================================================================
#include <vtkm/cont/DeviceAdapter.h>
#include <vtkm/cont/DeviceAdapterList.h>
#include <vtkm/cont/Logging.h>
#include <vtkm/cont/RuntimeDeviceTracker.h>
#include <vtkm/cont/Timer.h>
......
......@@ -10,9 +10,7 @@
#ifndef vtk_m_cont_Timer_h
#define vtk_m_cont_Timer_h
#include <vtkm/List.h>
#include <vtkm/cont/DeviceAdapter.h>
#include <vtkm/cont/DeviceAdapterList.h>
#include <vtkm/cont/DeviceAdapterTag.h>
#include <vtkm/cont/vtkm_cont_export.h>
......
......@@ -10,13 +10,13 @@
#include <vtkm/source/Oscillator.h>
//#include <vtkm/cont/Timer.h>
#include <vtkm/cont/Timer.h>
#include <vtkm/cont/testing/Testing.h>
void OscillatorSourceTest()
{
// vtkm::cont::Timer timer;
// timer.Start();
vtkm::cont::Timer timer;
timer.Start();
vtkm::source::Oscillator source(vtkm::Id3{ 20, 20, 20 });
source.SetTime(0.5);
......@@ -26,9 +26,9 @@ void OscillatorSourceTest()
vtkm::cont::DataSet ds = source.Execute();
//double time = timer.GetElapsedTime();
double time = timer.GetElapsedTime();
//std::cout << "Default oscillator took " << time << "s.\n";
std::cout << "Default oscillator took " << time << "s.\n";
{
auto coords = ds.GetCoordinateSystem("coordinates");
......
......@@ -10,21 +10,21 @@
#include <vtkm/source/Tangle.h>
//#include <vtkm/cont/Timer.h>
#include <vtkm/cont/Timer.h>
#include <vtkm/cont/testing/Testing.h>
void TangleSourceTest()
{
// vtkm::cont::Timer timer;
// timer.Start();
vtkm::cont::Timer timer;
timer.Start();
vtkm::source::Tangle source(vtkm::Id3{ 20, 20, 20 });
vtkm::cont::DataSet ds = source.Execute();
// double time = timer.GetElapsedTime();
double time = timer.GetElapsedTime();
// std::cout << "Default tangle took " << time << "s.\n";
std::cout << "Default tangle took " << time << "s.\n";
{
auto coords = ds.GetCoordinateSystem("coordinates");
......
......@@ -10,7 +10,6 @@
#include <vtkm/source/Wavelet.h>
//#include <vtkm/cont/Timer.h>
#include <vtkm/cont/testing/Testing.h>
void WaveletSourceTest()
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment