Skip to content

Commit

Permalink
completed incremental pfxt, to fix inc_pfxt unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
Randy1005 committed Aug 31, 2023
1 parent d7389f2 commit 5d7e33c
Show file tree
Hide file tree
Showing 26 changed files with 610 additions and 109 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ install_manifest.txt
compile_commands.json
CTestTestfile.cmake
_deps
*.cmake

# build folder
[Bb]uild/
Expand Down
29 changes: 21 additions & 8 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,19 +1,18 @@
cmake_minimum_required(VERSION 3.26.0)

# this is hardcoded, can I configure cmake to auto locate nvcc for me?
set(CMAKE_CUDA_COMPILER /usr/local/cuda/bin/nvcc)
# set(CMAKE_CUDA_COMPILER /usr/local/cuda/bin/nvcc)


project(Ink VERSION 1.0 LANGUAGES C CXX CUDA)
# project(Ink VERSION 1.0 LANGUAGES C CXX CUDA)
project(Ink VERSION 1.0 LANGUAGES C CXX)


# set everything up for c++XX features
set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CUDA_ARCHITECTURES 75)
set(CMAKE_CXX_STANDARD 17)
# set(CMAKE_CUDA_ARCHITECTURES 75)


# set default compiler to be gcc g++ (DISCOURAGED)
# set(CMAKE_C_COMPILER $ENV{DPCPP_COMPILER})

#------------------------------------------------------------------------------
# default release build
Expand All @@ -39,7 +38,7 @@ if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)

endif()

set(CMAKE_CUDA_FLAGS_DEBUG "-g -G -Xcompiler -g -lineinfo --expt-extended-lambda")
# set(CMAKE_CUDA_FLAGS_DEBUG "-g -G -Xcompiler -g -lineinfo --expt-extended-lambda")

# Turn on the verbose
set(CMAKE_VERBOSE_MAKEFILE ON)
Expand All @@ -52,6 +51,7 @@ set(INK_EXAMPLE_DIR ${PROJECT_SOURCE_DIR}/examples)
# Benchmark directory variable
set(INK_BENCHMARK_DIR ${PROJECT_SOURCE_DIR}/benchmarks)

set(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake/modules)


# Binary folder
Expand All @@ -62,9 +62,22 @@ message("CMAKE_BUILD_TYPE: " ${CMAKE_BUILD_TYPE})
message(STATUS "INK_BENCHMARK_DIR: " ${INK_BENCHMARK_DIR})
message(STATUS "BIN_DIR: " ${CMAKE_RUNTIME_OUTPUT_DIRECTORY})

# test that filesystem header actually is there and works
try_compile(HAS_FS "${CMAKE_BINARY_DIR}/temp"
"${CMAKE_SOURCE_DIR}/tests/has_filesystem.cc"
CMAKE_FLAGS -DCMAKE_CXX_STANDARD=17 -DCMAKE_CXX_STANDARD_REQUIRED=ON
LINK_LIBRARIES stdc++fs)
if(HAS_FS)
message(STATUS "Compiler has filesystem support")
else()
# .... You could also try searching for boost::filesystem here.
message(STATUS "Compiler is missing filesystem capabilities")
endif(HAS_FS)


option(INK_BUILD_CUDA "Enables builds of cuda code" ON)


option(INK_BUILD_CUDA "Enables builds of cuda code" OFF)



Expand Down
106 changes: 106 additions & 0 deletions DartConfiguration.tcl
Original file line number Diff line number Diff line change
@@ -0,0 +1,106 @@
# This file is configured by CMake automatically as DartConfiguration.tcl
# If you choose not to use CMake, this file may be hand configured, by
# filling in the required variables.


# Configuration directories and files
SourceDirectory: /Users/zhangzhe/Randy/source/Ink
BuildDirectory: /Users/zhangzhe/Randy/source/Ink

# Where to place the cost data store
CostDataFile:

# Site is something like machine.domain, i.e. pragmatic.crd
Site: MacBook-Pro.lan

# Build name is osname-revision-compiler, i.e. Linux-2.4.2-2smp-c++
BuildName: Darwin-g++

# Subprojects
LabelsForSubprojects:

# Submission information
SubmitURL: http://
SubmitInactivityTimeout:

# Dashboard start time
NightlyStartTime: 00:00:00 EDT

# Commands for the build/test/submit cycle
ConfigureCommand: "/Applications/CMake.app/Contents/bin/cmake" "/Users/zhangzhe/Randy/source/Ink"
MakeCommand: /Applications/CMake.app/Contents/bin/cmake --build . --config "${CTEST_CONFIGURATION_TYPE}"
DefaultCTestConfigurationType: Release

# version control
UpdateVersionOnly:

# CVS options
# Default is "-d -P -A"
CVSCommand:
CVSUpdateOptions:

# Subversion options
SVNCommand:
SVNOptions:
SVNUpdateOptions:

# Git options
GITCommand: /usr/bin/git
GITInitSubmodules:
GITUpdateOptions:
GITUpdateCustom:

# Perforce options
P4Command:
P4Client:
P4Options:
P4UpdateOptions:
P4UpdateCustom:

# Generic update command
UpdateCommand: /usr/bin/git
UpdateOptions:
UpdateType: git

# Compiler info
Compiler: /usr/bin/g++
CompilerVersion: 14.0.3.14030022

# Dynamic analysis (MemCheck)
PurifyCommand:
ValgrindCommand:
ValgrindCommandOptions:
DrMemoryCommand:
DrMemoryCommandOptions:
CudaSanitizerCommand:
CudaSanitizerCommandOptions:
MemoryCheckType:
MemoryCheckSanitizerOptions:
MemoryCheckCommand: MEMORYCHECK_COMMAND-NOTFOUND
MemoryCheckCommandOptions:
MemoryCheckSuppressionFile:

# Coverage
CoverageCommand: /usr/bin/gcov
CoverageExtraFlags: -l

# Testing options
# TimeOut is the amount of time in seconds to wait for processes
# to complete during testing. After TimeOut seconds, the
# process will be summarily terminated.
# Currently set to 25 minutes
TimeOut: 1500

# During parallel testing CTest will not start a new test if doing
# so would cause the system load to exceed this value.
TestLoad:

UseLaunchers:
CurlOptions:
# warning, if you add new options here that have to do with submit,
# you have to update cmCTestSubmitCommand.cxx

# For CTest submissions that timeout, these options
# specify behavior for retrying the submission
CTestSubmitRetryDelay: 5
CTestSubmitRetryCount: 3
Loading

0 comments on commit 5d7e33c

Please sign in to comment.