Skip to content

Commit db35698

Browse files
committed
Fix debug build flag and remove bug from example
1 parent 87d024d commit db35698

File tree

2 files changed

+3
-6
lines changed

2 files changed

+3
-6
lines changed

CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ if(WIN32)
149149
message(STATUS "Compiling on windows with CLANG!")
150150
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Xclang -fcxx-exceptions")
151151

152-
set(CMAKE_CXX_FLAGS_DEBUG "/MD /Z7")
152+
set(CMAKE_CXX_FLAGS_DEBUG "/MDd /Z7")
153153
set(CMAKE_CXX_FLAGS_RELEASE "/MD /EHsc /std:c++17 /arch:AVX2 -Xclang -O3 /nologo /fp:fast") #-flto=thin -march=native /O2 /Ob2
154154

155155
endif()
@@ -158,7 +158,7 @@ if(WIN32)
158158
message(STATUS "Compiling on windows with MSVC!")
159159

160160
set(CMAKE_CXX_FLAGS_RELEASE "/MD /EHsc /std:c++17 /arch:AVX2 /O2 /Ob2 /nologo /fp:fast")
161-
set(CMAKE_CXX_FLAGS_DEBUG "/MD /Z7")
161+
set(CMAKE_CXX_FLAGS_DEBUG "/MDd /Z7")
162162

163163
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DWIN_VS")
164164
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DWIN_VS")

examples/Example_apr_iterate.cpp

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -117,8 +117,6 @@ int main(int argc, char **argv) {
117117
timer.stop_timer();
118118

119119

120-
121-
122120
////////////////////////////
123121
///
124122
/// OpenMP Parallel loop iteration (For use with neighbour access see Example_apr_neighbour_access)
@@ -184,9 +182,8 @@ int main(int argc, char **argv) {
184182
for (x = 0; x < it.x_num(level); ++x) {
185183
for (it.begin(level, z, x); it < it.end();
186184
it++) {
187-
185+
calc_ex[it] = pow(calc_ex[it], 2.0f);
188186
}
189-
calc_ex[it] = pow(calc_ex[it], 2.0f);
190187
}
191188
}
192189
}

0 commit comments

Comments
 (0)