Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

exclude marlin & exllama on windows #898

Merged
merged 5 commits into from
Dec 18, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
71 changes: 39 additions & 32 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -174,40 +174,47 @@ def get_version_tag(is_cuda_release: bool = True) -> str:
extra_link_args=extra_link_args,
extra_compile_args=extra_compile_args,
),
cpp_ext.CUDAExtension(
"gptqmodel_marlin_kernels",
[
"gptqmodel_ext/marlin/marlin_cuda.cpp",
"gptqmodel_ext/marlin/marlin_cuda_kernel.cu",
"gptqmodel_ext/marlin/marlin_repack.cu",
],
extra_link_args=extra_link_args,
extra_compile_args=extra_compile_args,
),
cpp_ext.CUDAExtension(
"gptqmodel_exllama_kernels",
[
"gptqmodel_ext/exllama/exllama_ext.cpp",
"gptqmodel_ext/exllama/cuda_buffers.cu",
"gptqmodel_ext/exllama/cuda_func/column_remap.cu",
"gptqmodel_ext/exllama/cuda_func/q4_matmul.cu",
"gptqmodel_ext/exllama/cuda_func/q4_matrix.cu",
],
extra_link_args=extra_link_args,
extra_compile_args=extra_compile_args,
),
cpp_ext.CUDAExtension(
"gptqmodel_exllamav2_kernels",
[
"gptqmodel_ext/exllamav2/ext.cpp",
"gptqmodel_ext/exllamav2/cuda/q_matrix.cu",
"gptqmodel_ext/exllamav2/cuda/q_gemm.cu",
],
extra_link_args=extra_link_args,
extra_compile_args=extra_compile_args,
)
]

if sys.platform != "win32":
extensions.append([
# TODO: VC++: fatal error C1061: compiler limit : blocks nested too deeply
cpp_ext.CUDAExtension(
"gptqmodel_marlin_kernels",
[
"gptqmodel_ext/marlin/marlin_cuda.cpp",
"gptqmodel_ext/marlin/marlin_cuda_kernel.cu",
"gptqmodel_ext/marlin/marlin_repack.cu",
],
extra_link_args=extra_link_args,
extra_compile_args=extra_compile_args,
),
# TODO: VC++: error lnk2001 unresolved external symbol cublasHgemm
cpp_ext.CUDAExtension(
"gptqmodel_exllama_kernels",
[
"gptqmodel_ext/exllama/exllama_ext.cpp",
"gptqmodel_ext/exllama/cuda_buffers.cu",
"gptqmodel_ext/exllama/cuda_func/column_remap.cu",
"gptqmodel_ext/exllama/cuda_func/q4_matmul.cu",
"gptqmodel_ext/exllama/cuda_func/q4_matrix.cu",
],
extra_link_args=extra_link_args,
extra_compile_args=extra_compile_args,
),
# TODO: VC++: error lnk2001 unresolved external symbol cublasHgemm
cpp_ext.CUDAExtension(
"gptqmodel_exllamav2_kernels",
[
"gptqmodel_ext/exllamav2/ext.cpp",
"gptqmodel_ext/exllamav2/cuda/q_matrix.cu",
"gptqmodel_ext/exllamav2/cuda/q_gemm.cu",
],
extra_link_args=extra_link_args,
extra_compile_args=extra_compile_args,
)
])

additional_setup_kwargs = {"ext_modules": extensions, "cmdclass": {"build_ext": cpp_ext.BuildExtension}}


Expand Down
Loading