[Bugfix][Misc] Fix silu_and_mul_nvfp4_quant issue and extract common utils for nvfp4 kernel source files (#23727)

Signed-off-by: elvischenv <219235043+elvischenv@users.noreply.github.com>
Signed-off-by: Luka Govedič <ProExpertProg@users.noreply.github.com>
Co-authored-by: Luka Govedič <ProExpertProg@users.noreply.github.com>
This commit is contained in:
elvischenv
2025-09-05 05:25:45 +08:00
committed by GitHub
parent 60b755cbcb
commit adc3ddb430
11 changed files with 382 additions and 718 deletions

View File

@@ -8,8 +8,7 @@ from vllm.model_executor.layers.activation import SiluAndMul
from vllm.platforms import current_platform
from vllm.scalar_type import scalar_types
if not (current_platform.has_device_capability(100)
and hasattr(torch.ops._C, "silu_and_mul_nvfp4_quant")):
if not current_platform.has_device_capability(100):
pytest.skip(reason="Nvfp4 Requires compute capability of 10 or above.",
allow_module_level=True)