diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000000..832986dea3 --- /dev/null +++ b/.gitignore @@ -0,0 +1,24 @@ +__pycache__/ +.vscode +*.engine +*.engine.config +*.cache +*.nsys-rep +.VSCodeCounter +build*/ +*.so +*.egg-info/ +.coverage +*.csv +*.onnx +tmp/ +venv/ +.venv/ +.local/ +.hypothesis/ +.idea/ +cpp/cmake-build-* + +# Testing +.coverage.* +results_trt/ diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000000..8180e14d6c --- /dev/null +++ b/.gitmodules @@ -0,0 +1,11 @@ +[submodule "3rdparty/cutlass"] + path = 3rdparty/cutlass + url = https://github.com/NVIDIA/cutlass.git + branch = v2.10.0 +[submodule "3rdparty/json"] + path = 3rdparty/json + url = https://github.com/nlohmann/json.git +[submodule "3rdparty/cxxopts"] + path = 3rdparty/cxxopts + url = https://github.com/jarro2783/cxxopts + branch = v3.1.1 diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 0000000000..2708e2db5d --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,42 @@ +repos: +- repo: https://github.com/pycqa/isort + rev: 5.12.0 + hooks: + - id: isort +- repo: https://github.com/Lucas-C/pre-commit-hooks.git + rev: v1.1.13 + hooks: + - id: remove-crlf +- repo: https://github.com/pre-commit/mirrors-yapf + rev: v0.32.0 + hooks: + - id: yapf +- repo: https://github.com/pre-commit/pre-commit-hooks + rev: v4.1.0 + hooks: + - id: check-added-large-files + exclude: 'cpp/tensorrt_llm/kernels/contextFusedMultiHeadAttention/cubin' + - id: check-merge-conflict + - id: check-symlinks + - id: detect-private-key + - id: end-of-file-fixer + - id: check-yaml + - id: trailing-whitespace +- repo: https://github.com/PyCQA/autoflake + rev: v1.6.1 + hooks: + - id: autoflake + args: ['--in-place', '--remove-all-unused-imports', '--remove-unused-variables'] +- repo: https://github.com/pre-commit/mirrors-clang-format + rev: v16.0.0 + hooks: + - id: clang-format + types_or: [c++, c, cuda] + exclude: | + (?x)^( + cpp/tensorrt_llm/kernels/contextFusedMultiHeadAttention/cubin/.* + )$ +- repo: https://github.com/cheshirekow/cmake-format-precommit + rev: v0.6.10 + hooks: + - id: cmake-format diff --git a/3rdparty/cutlass b/3rdparty/cutlass new file mode 160000 index 0000000000..fc9ebc645b --- /dev/null +++ b/3rdparty/cutlass @@ -0,0 +1 @@ +Subproject commit fc9ebc645b63f3a6bc80aaefde5c063fb72110d6 diff --git a/3rdparty/cxxopts b/3rdparty/cxxopts new file mode 160000 index 0000000000..eb787304d6 --- /dev/null +++ b/3rdparty/cxxopts @@ -0,0 +1 @@ +Subproject commit eb787304d67ec22f7c3a184ee8b4c481d04357fd diff --git a/3rdparty/json b/3rdparty/json new file mode 160000 index 0000000000..5fec803493 --- /dev/null +++ b/3rdparty/json @@ -0,0 +1 @@ +Subproject commit 5fec8034933ef434a98dfbd2551b052c56345869