Skip to content

Commit 163850f

Browse files
committed
some bugfix
- uuid crash issue - update lora implement - set page size by param - delete deprecated files
1 parent 0174d94 commit 163850f

File tree

121 files changed

+3886
-4653
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

121 files changed

+3886
-4653
lines changed

.gitmodules

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
[submodule "third_party/from_source/cutlass"]
2-
path = third_party/from_source/cutlass
3-
url = https://github.com/NVIDIA/cutlass.git
2+
path = third_party/from_source/cutlass
3+
url = https://github.com/NVIDIA/cutlass.git

CMakeLists.txt

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ set(CONFIG_HOST_CPU_TYPE "X86" CACHE STRING "host cpu type, like X86, ARMV9, etc
4545
##
4646
option(ENABLE_NV_STATIC_LIB "build with static lib of nvidia" OFF)
4747
option(USE_SYSTEM_NV_LIB "use system nccl lib instead download binary." OFF)
48+
option(BUILD_HIEDNN "build HIE-DNN from source" OFF)
4849
option(ENABLE_CUDA_PINNED_WEIGHT_LOAD "enable cuda pinned memory for load weight" OFF)
4950
option(ENABLE_SPAN_ATTENTION "enable build with span attention" ON)
5051
option(ENABLE_MULTINUMA "enable multinuma, if on cpu multinuma service will be compiled" OFF)
@@ -174,18 +175,14 @@ if(LOCK_CHECK)
174175
endif()
175176

176177
if (ENABLE_CUDA)
177-
include(cuda)
178178
list(APPEND ALLSPARK_DEFINITION "-DENABLE_CUDA")
179-
180-
if (ENABLE_CUSPARSELT)
181-
set(ENABLE_CUSPARSELT ON)
182-
list(APPEND ALLSPARK_DEFINITION "-DENABLE_CUSPARSELT")
183-
endif()
184-
179+
if (ENABLE_CUSPARSELT)
180+
list(APPEND ALLSPARK_DEFINITION "-DENABLE_CUSPARSELT")
181+
endif()
182+
include(cuda)
185183
if (ENABLE_SPARSE)
186-
list(APPEND ALLSPARK_DEFINITION "-DENABLE_SPARSE")
184+
list(APPEND ALLSPARK_DEFINITION "-DENABLE_SPARSE")
187185
endif()
188-
189186
if (ENABLE_FP8)
190187
list(APPEND ALLSPARK_DEFINITION "-DENABLE_FP8")
191188
endif()

build.sh

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ with_platform="${AS_PLATFORM:-cuda}"
88
cuda_version="${AS_CUDA_VERSION:-12.4}"
99
cuda_sm="${AS_CUDA_SM:-80;86;90a}"
1010
NCCL_VERSION="${AS_NCCL_VERSION:-2.23.4}"
11+
build_folder="${AS_BUILD_FOLDER:-build}"
1112

1213
## NCCL Version Map:
1314
## the corresponding pre-build nccl will download on oss.
@@ -22,9 +23,9 @@ build_type="${AS_BUILD_TYPE:-Release}"
2223
cuda_static="${AS_CUDA_STATIC:-OFF}"
2324
build_package="${AS_BUILD_PACKAGE:-ON}"
2425
enable_glibcxx11_abi="${AS_CXX11_ABI:-OFF}"
26+
build_hiednn="${AS_BUILD_HIEDNN:-ON}"
2527
enable_span_attn="${ENABLE_SPAN_ATTENTION:-ON}"
2628
enable_multinuma="${ENABLE_MULTINUMA:-OFF}"
27-
2829
function clone_pull {
2930
GIT_URL=$1
3031
DIRECTORY=$2
@@ -42,11 +43,11 @@ function clone_pull {
4243
}
4344

4445
if [ "$clean" == "ON" ]; then
45-
rm -rf build
46+
rm -rf ${build_folder}
4647
fi
4748

48-
if [ ! -d "./build" ]; then
49-
mkdir build && cd build
49+
if [ ! -d "./${build_folder}" ]; then
50+
mkdir ${build_folder} && cd ${build_folder}
5051

5152
conan profile new dashinfer_compiler_profile --detect --force
5253
conanfile=../conan/conanfile.txt
@@ -74,7 +75,7 @@ if [ ! -d "./build" ]; then
7475
cd ../
7576
fi
7677

77-
cd build
78+
cd ${build_folder}
7879
source ./activate.sh
7980
export PATH=`pwd`/bin:$PATH
8081

@@ -94,6 +95,7 @@ if [ "${with_platform,,}" == "cuda" ]; then
9495
-DBUILD_PYTHON=OFF \
9596
-DALWAYS_READ_LOAD_MODEL=OFF \
9697
-DENABLE_SPAN_ATTENTION=${enable_span_attn} \
98+
-DBUILD_HIEDNN=${build_hiednn} \
9799
-DENABLE_MULTINUMA=OFF
98100
elif [ "${with_platform,,}" == "x86" ]; then
99101
cmake .. \

cmake/FindHIEDNN.cmake

Lines changed: 0 additions & 46 deletions
This file was deleted.

cmake/cutlass.cmake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ set(CUTLASS_NVCC_ARCHS ${CMAKE_CUDA_ARCHITECTURES} CACHE STRING "The SM architec
77
set(CUTLASS_INSTALL ${INSTALL_LOCATION}/cutlass/install)
88
message(STATUS "CUTLASS_INSTALL: ${CUTLASS_INSTALL}")
99

10-
message(STATUS "Use cutlass from submodule")
11-
set(CUTLASS_SOURCE_DIR ${PROJECT_SOURCE_DIR}/third_party/from_source/cutlass)
10+
message(STATUS "Use cutlass from submodule")
11+
set(CUTLASS_SOURCE_DIR ${PROJECT_SOURCE_DIR}/third_party/from_source/cutlass)
1212

1313
include(ExternalProject)
1414

cmake/flash-attention.cmake

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -35,12 +35,9 @@ else()
3535
set(FLASHATTN_LIBRARY_NAME libflash-attn.so)
3636
endif()
3737

38-
option(FLASHATTN_BUILD_FROM_SOURCE "build flash-attn from source or use prebuilt lib" ON)
39-
# make sure you copy prebuild and source code under csrc together, to avoid header aligment issue.
4038

4139
include(ExternalProject)
4240

43-
if (FLASHATTN_BUILD_FROM_SOURCE)
4441
message(STATUS "build flash-attention from source")
4542

4643
message(STATUS "Use flash-attention from external project")
@@ -78,9 +75,6 @@ if (FLASHATTN_BUILD_FROM_SOURCE)
7875
ExternalProject_Get_Property(project_flashattn SOURCE_SUBDIR)
7976
set(FLASHATTN_INCLUDE_DIR ${SOURCE_DIR}/${SOURCE_SUBDIR})
8077

81-
else() # FLASHATTN_BUILD_FROM_SOURCE
82-
message(FATAL_ERROR "flash attention build only support source code build.")
83-
endif() # FLASHATTN_BUILD_FROM_SOURCE
8478

8579
message(STATUS "FLASHATTN_LIBRARY_PATH: ${FLASHATTN_LIBRARY_PATH}")
8680
message(STATUS "FLASHATTN_INCLUDE_DIR: ${FLASHATTN_INCLUDE_DIR}")

cmake/hie-dnn.cmake

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,8 @@ set(HIEDNN_LIBRARY_PATH ${HIEDNN_INSTALL}/lib64/libhiednn_static.a)
2929
message(STATUS "HIEDNN_INSTALL: ${HIEDNN_INSTALL}")
3030
message(STATUS "HIEDNN_LIBRARY_PATH: ${HIEDNN_LIBRARY_PATH}")
3131

32-
set(HIEDNN_SOURCE_DIR ${PROJECT_SOURCE_DIR}/HIE-DNN)
32+
set(HIEDNN_SOURCE_DIR ${PROJECT_SOURCE_DIR}/HIE-DNN)
33+
message(STATUS "Build HIE-DNN in: ${HIEDNN_SOURCE_DIR}")
3334

3435
include(ExternalProject)
3536

csrc/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ set(ALLSPARK_INC_DIR
4141
${CMAKE_BINARY_DIR}/csrc
4242
)
4343

44-
list(APPEND ALLSPARK_INC_DIR ${PROJECT_SOURCE_DIR}/third_party/from_source/cutlass/include)
44+
list(APPEND ALLSPARK_INC_DIR ${PROJECT_SOURCE_DIR}/third_party/from_source/cutlass/include)
4545

4646
set(ALLSPARK_3RD_LIBS
4747
${THREAD_LIB}

0 commit comments

Comments
 (0)