Skip to content

Commit

Permalink
fix marlin flag set on hpu
Browse files Browse the repository at this point in the history
  • Loading branch information
nirda7 committed Nov 25, 2024
1 parent dbde4b8 commit c94d24c
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions vllm/model_executor/layers/quantization/fp8.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,16 +117,17 @@ class Fp8LinearMethod(LinearMethodBase):

def __init__(self, quant_config: Fp8Config):
self.quant_config = quant_config
self.use_marlin = False
if current_platform.is_cuda_alike():
self.cutlass_fp8_supported = cutlass_fp8_supported()

# For GPUs that lack FP8 hardware support, we can leverage the Marlin
# kernel for fast weight-only FP8 quantization
self.use_marlin = (not current_platform.has_device_capability(89)
or envs.VLLM_TEST_FORCE_FP8_MARLIN)
# Disable marlin for rocm
if current_platform.is_rocm():
self.use_marlin = False
# For GPUs that lack FP8 hardware support, we can leverage the
# Marlin kernel for fast weight-only FP8 quantization
self.use_marlin = (not current_platform.has_device_capability(89)
or envs.VLLM_TEST_FORCE_FP8_MARLIN)
# Disable marlin for rocm
if current_platform.is_rocm():
self.use_marlin = False

def create_weights(
self,
Expand Down

0 comments on commit c94d24c

Please sign in to comment.