Skip to content

Commit d54df8b

Browse files
author
jgtong
authored
Merge pull request #50 from oneapi-src/jgt/easywave
Updating CMakeLists.txt for easywave CUDA
2 parents c10829e + 2ad2e18 commit d54df8b

File tree

4 files changed

+18
-18
lines changed

4 files changed

+18
-18
lines changed

easywave/CUDA/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ endif()
8383
add_compile_options(-DUSE_CUDA)
8484
add_compile_options(-DENABLE_CUDA_LOGGING)
8585

86-
set(CUDA_NVCC_FLAGS -std=c++17)
86+
#set(CUDA_NVCC_FLAGS -std=c++17)
8787
if(ENABLE_GPU_TIMINGS)
8888
message(STATUS "GPU Timings will be displayed")
8989
add_compile_options(-DENABLE_GPU_TIMINGS)

easywave/SYCL/src/EasyWave.cpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -85,11 +85,11 @@ int main(int argc, char **argv)
8585
{
8686
Timer tWallClock("WallClock");
8787
tWallClock.Start();
88-
LOG("Starting SYCL main program. Process ID: " << Utility::GetProcessID());
88+
LOG("Starting SYCL main program"); ///. Process ID: " << Utility::GetProcessID());
8989

9090
std::vector<std::string> eWaveFiles(Utility::FileHandler::GetFilesFromDirectory(Utility::FileHandler::GetCurrentDirectory()));
9191
if (!eWaveFiles.empty()) {
92-
LOG("Attempting to clean up previous eWave tsunami files in " << Utility::FileHandler::GetCurrentDirectory());
92+
LOG("Attempting to clean up previous eWave tsunami files"); ///in " << Utility::FileHandler::GetCurrentDirectory());
9393
eWaveFiles.erase(std::remove_if(eWaveFiles.begin(), eWaveFiles.end(), [](std::string const &sPath) { return sPath.rfind("eWave") == std::string::npos; }), eWaveFiles.end());
9494
size_t const uNumberOfeWaveFiles(eWaveFiles.size());
9595
size_t const uNumberOfDeletedFiles(Utility::FileHandler::RemoveFiles(eWaveFiles));
@@ -181,7 +181,7 @@ int main(int argc, char **argv)
181181

182182
if (Par.outProgress) {
183183
if (lastProgress >= Par.outProgress) {
184-
LOG("Model time: " << utlTimeSplitString(Par.time)); //// << " Elapsed: " << tCumulatedComputeTime.GetTimeAsString(Timer::Units::SECONDS));
184+
/////LOG("Model time: " << utlTimeSplitString(Par.time)); //// << " Elapsed: " << tCumulatedComputeTime.GetTimeAsString(Timer::Units::SECONDS));
185185
/////printf( "Model time = %s, elapsed: %ld msec\n", utlTimeSplitString(Par.time), elapsed );
186186
//
187187
#ifdef SHOW_GRID
@@ -216,7 +216,7 @@ int main(int argc, char **argv)
216216
}
217217

218218
} // main loop
219-
LOG("Compute loop completed");
219+
////LOG("Compute loop completed");
220220

221221
// clock_gettime(CLOCK_MONOTONIC, &end);
222222
Log.print("Finishing main loop");
@@ -238,8 +238,8 @@ int main(int argc, char **argv)
238238

239239
LOG("Program successfully completed");
240240
tWallClock.Stop();
241-
LOG("I/O Time : " << dAccumulatedIOWriteTime - dAccumulateIOReadTime << " s");
242-
LOG("Total Execution Time: " << tWallClock.GetTime() - dAccumulatedIOWriteTime - dAccumulateIOReadTime << " s");
241+
/////LOG("I/O Time : " << dAccumulatedIOWriteTime - dAccumulateIOReadTime << " s");
242+
/////LOG("Total Execution Time: " << tWallClock.GetTime() - dAccumulatedIOWriteTime - dAccumulateIOReadTime << " s");
243243
return 0;
244244
}
245245

easywave/SYCL/src/ewGpuNode.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ void CGpuNode::PrintTimingStats()
118118
int CGpuNode::mallocMem()
119119
{
120120
try {
121-
LOG("Allocating GPU memory");
121+
////LOG("Allocating GPU memory");
122122

123123
CArrayNode::mallocMem();
124124

infrastructure/SYCL.cpp

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -112,25 +112,25 @@ void SYCL::DisplayProperties() //sycl::device const &Device)
112112
{
113113
LOG("\t Using SYCL device : " << m_syclQueue.get_device().get_info<sycl::info::device::name>() << " (Driver version " << m_syclQueue.get_device().get_info<sycl::info::device::driver_version>() << ")");
114114
LOG("\t Platform : " << m_syclQueue.get_device().get_platform().get_info<sycl::info::platform::name>());
115-
LOG("\t Vendor : " << m_syclQueue.get_device().get_info<sycl::info::device::vendor>());
116-
LOG("\t Max compute units : " << m_syclQueue.get_device().get_info<sycl::info::device::max_compute_units>());
117-
LOG("\t Queue type : " << (m_syclQueue.is_in_order() ? "In order" : "Out of order"));
115+
////LOG("\t Vendor : " << m_syclQueue.get_device().get_info<sycl::info::device::vendor>());
116+
////LOG("\t Max compute units : " << m_syclQueue.get_device().get_info<sycl::info::device::max_compute_units>());
117+
////LOG("\t Queue type : " << (m_syclQueue.is_in_order() ? "In order" : "Out of order"));
118118

119119
std::vector<std::string> const vLDDPaths(Utility::ExtractLDDPathNameFromProcess({"libOpenCL", "libsycl", "libComputeCpp", "libze"})); //[0] OCL, [1] Intel's SYCL, [2] ComputeCpp SYCL
120120
if (vLDDPaths.empty()) {
121121
LOG_WARNING("Unable to print OpenCL and SYCL dependent libraries! The LD_LIBRARY_PATH may be incorrectly set"); // Should not reach to this case
122122
return;
123123
}
124124

125-
LOG("\t Using OpenCL library : " << (!vLDDPaths[0].empty() ? vLDDPaths[0] : "WARNING! OpenCL library not found!"));
125+
////LOG("\t Using OpenCL library : " << (!vLDDPaths[0].empty() ? vLDDPaths[0] : "WARNING! OpenCL library not found!"));
126126

127-
if (!vLDDPaths[1].empty()) { // Implies we are using Intel's DPC++ compiler
128-
LOG("\t Using OneAPI SYCL library : " << vLDDPaths[1]);
129-
LOG("\t Using Level Zero library : " << (!vLDDPaths[3].empty() ? vLDDPaths[3] : "WARNING! Level zero library not found! L0 backend may not be available!"));
130-
}
127+
////if (!vLDDPaths[1].empty()) { // Implies we are using Intel's DPC++ compiler
128+
//// LOG("\t Using OneAPI SYCL library : " << vLDDPaths[1]);
129+
//// LOG("\t Using Level Zero library : " << (!vLDDPaths[3].empty() ? vLDDPaths[3] : "WARNING! Level zero library not found! L0 backend may not be available!"));
130+
////}
131131

132-
if (!vLDDPaths[2].empty())
133-
LOG("\t Using ComputeCPP library : " << vLDDPaths[2]);
132+
////if (!vLDDPaths[2].empty())
133+
//// LOG("\t Using ComputeCPP library : " << vLDDPaths[2]);
134134
}
135135

136136
std::chrono::steady_clock::duration SYCL::ConvertKernelTimeToDuration(sycl::event const &Event)

0 commit comments

Comments
 (0)