...
 
Commits (3)
cmake_minimum_required(VERSION 3.6) cmake_minimum_required(VERSION 3.6)
project(ego2) project(hilbertJoin)
## set gcc compiler, tested with gcc 6.1.0 ## set gcc compiler, tested with gcc 6.1.0
# export CC=/opt/gcc6.1.0/usr/local/bin/gcc # export CC=/opt/gcc6.1.0/usr/local/bin/gcc
...@@ -19,7 +19,9 @@ set(SOURCE_FILES_JOIN mainJoin.cpp hilbertjoin/egojoin.cpp hilbertjoin/hilloop.c ...@@ -19,7 +19,9 @@ set(SOURCE_FILES_JOIN mainJoin.cpp hilbertjoin/egojoin.cpp hilbertjoin/hilloop.c
# adding MKL include directory # adding MKL include directory
include_directories($ENV{MKLROOT}/include) include_directories($ENV{MKLROOT}/include)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -march=knl -mtune=knl -ffast-math -fassociative-math -O3 -fopenmp -lmkl_core -lmkl_intel_lp64 -lmkl_intel_thread -liomp5 -lboost_system") # set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -march=knl -mtune=knl -ffast-math -fassociative-math -O3 -fopenmp -lmkl_core -lmkl_intel_lp64 -lmkl_intel_thread -liomp5 -lboost_system")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -march=knl -mtune=knl -ffast-math -fassociative-math -O3 -fopenmp -lmkl_core -lmkl_intel_lp64 -lmkl_intel_thread -liomp5")
# xeon-phi # xeon-phi
link_directories($ENV{MKLROOT}/lib/intel64) link_directories($ENV{MKLROOT}/lib/intel64)
...@@ -42,28 +44,30 @@ find_library ( mkl_omp_LIB NAMES libiomp5.a ...@@ -42,28 +44,30 @@ find_library ( mkl_omp_LIB NAMES libiomp5.a
#################### ####################
# cmake -DCMAKE_BUILD_TYPE=Debug .. # cmake -DCMAKE_BUILD_TYPE=Debug ..
# and ignore the warning: "Manually-specified variables were not used by the project: CMAKE_BUID_TYPE" # and ignore the warning: "Manually-specified variables were not used by the project: CMAKE_BUID_TYPE"
set(CMAKE_CXX_FLAGS_DEBUG "-std=c++11 -march=knl -mtune=knl -fpic -ffast-math -O0 -DNDDEBUG -fopenmp -lboost_system -lmkl_core -lmkl_intel_lp64 -lmkl_intel_thread -liomp5")
# set(CMAKE_CXX_FLAGS_DEBUG "-std=c++11 -march=knl -mtune=knl -fpic -ffast-math -O0 -DNDDEBUG -fopenmp -lboost_system -lmkl_core -lmkl_intel_lp64 -lmkl_intel_thread -liomp5")
set(CMAKE_CXX_FLAGS_DEBUG "-std=c++11 -march=knl -mtune=knl -fpic -ffast-math -O0 -DNDDEBUG -fopenmp -lmkl_core -lmkl_intel_lp64 -lmkl_intel_thread -liomp5")
# add_executable(egoHilb ${SOURCE_FILES}) # add_executable(egoHilb ${SOURCE_FILES})
add_executable(hilbertJoinCardinality ${SOURCE_FILES_JOIN}) add_executable(hilbertJoinCountOnly ${SOURCE_FILES_JOIN})
add_executable(hilbertSelfJoinCardinality ${SOURCE_FILES_SELF}) add_executable(hilbertSelfJoinCountOnly ${SOURCE_FILES_SELF})
target_compile_definitions(hilbertJoinCardinality PRIVATE -DCOUNT_ONLY) target_compile_definitions(hilbertJoinCountOnly PRIVATE -DCOUNT_ONLY)
target_compile_definitions(hilbertSelfJoinCardinality PRIVATE -DCOUNT_ONLY) target_compile_definitions(hilbertSelfJoinCountOnly PRIVATE -DCOUNT_ONLY)
## for a more verbose version comment out the next two lines ## for a non-verbose version comment out the next two lines
# target_compile_definitions(hilbertJoinCardinality PRIVATE -DOUTPUT) target_compile_definitions(hilbertJoinCountOnly PRIVATE -DOUTPUT)
# target_compile_definitions(hilbertSelfJoinCardinality PRIVATE -DOUTPUT) target_compile_definitions(hilbertSelfJoinCountOnly PRIVATE -DOUTPUT)
if ($ENV{KBLOCK}) if ($ENV{KBLOCK})
target_compile_definitions(hilbertJoinCardinality PRIVATE -DKBLOCK=$ENV{KBLOCK}) target_compile_definitions(hilbertJoinCountOnly PRIVATE -DKBLOCK=$ENV{KBLOCK})
target_compile_definitions(hilbertSelfJoinCardinality PRIVATE -DKBLOCK=$ENV{KBLOCK}) target_compile_definitions(hilbertSelfJoinCountOnly PRIVATE -DKBLOCK=$ENV{KBLOCK})
endif() endif()
if ($ENV{OMP_NUM_THREADS}) if ($ENV{OMP_NUM_THREADS})
target_compile_definitions(hilbertJoinCardinality PRIVATE -DNUM_THREADS=$ENV{OMP_NUM_THREADS}) target_compile_definitions(hilbertJoinCountOnly PRIVATE -DNUM_THREADS=$ENV{OMP_NUM_THREADS})
target_compile_definitions(hilbertSelfJoinCardinality PRIVATE -DNUM_THREADS=$ENV{OMP_NUM_THREADS}) target_compile_definitions(hilbertSelfJoinCountOnly PRIVATE -DNUM_THREADS=$ENV{OMP_NUM_THREADS})
endif() endif()
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
#endif #endif
#endif #endif
#include <hbwmalloc.h> // #include <hbwmalloc.h>
#include <errno.h> #include <errno.h>
#define ALIGNMENT 64 #define ALIGNMENT 64
......