Skip to content

Commit

Permalink
fix ci
Browse files Browse the repository at this point in the history
Signed-off-by: jiang1.li <jiang1.li@intel.com>
  • Loading branch information
bigPYJ1151 committed Jan 17, 2025
1 parent 8027a72 commit 7ad3d4b
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 4 deletions.
4 changes: 2 additions & 2 deletions .buildkite/run-cpu-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,6 @@ function cpu_tests() {
tests/lora/test_qwen2vl.py"
}

# All of CPU tests are expected to be finished less than 25 mins.
# All of CPU tests are expected to be finished less than 40 mins.
export -f cpu_tests
timeout 30m bash -c "cpu_tests $CORE_RANGE $NUMA_NODE"
timeout 40m bash -c "cpu_tests $CORE_RANGE $NUMA_NODE"
4 changes: 2 additions & 2 deletions vllm/model_executor/layers/activation.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ class FatreluAndMul(CustomOp):
def __init__(self, threshold: float = 0.):
super().__init__()
self.threshold = threshold
if current_platform.is_cuda_alike() or current_platform.is_cpu():
if current_platform.is_cuda_alike():
self.op = torch.ops._C.fatrelu_and_mul

def forward_native(self, x: torch.Tensor) -> torch.Tensor:
Expand Down Expand Up @@ -100,7 +100,7 @@ class MulAndSilu(CustomOp):

def __init__(self):
super().__init__()
if current_platform.is_cuda_alike() or current_platform.is_cpu():
if current_platform.is_cuda_alike():
self.op = torch.ops._C.mul_and_silu
elif current_platform.is_xpu():
from vllm._ipex_ops import ipex_ops
Expand Down
6 changes: 6 additions & 0 deletions vllm/platforms/cpu.py
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,12 @@ def check_and_update_config(cls, vllm_config: VllmConfig) -> None:

assert vllm_config.device_config.device_type == "cpu"

compilation_config = vllm_config.compilation_config
compilation_config.custom_ops = [
"-fatrelu_and_mul",
"-mul_and_silu",
]

#
# Environment variables for CPU executor
#
Expand Down

0 comments on commit 7ad3d4b

Please sign in to comment.