diff --git a/.buildkite/test-amd.yaml b/.buildkite/test-amd.yaml index 5550c0a0c1..03b94f6e40 100644 --- a/.buildkite/test-amd.yaml +++ b/.buildkite/test-amd.yaml @@ -1627,10 +1627,11 @@ steps: - pytest -v -s kernels/core --ignore=kernels/core/test_minimax_reduce_rms.py kernels/test_concat_mla_q.py kernels/test_top_k_per_row.py - label: Kernels MoE Test %N # TBD - timeout_in_minutes: 180 + timeout_in_minutes: 50 mirror_hardwares: [amdexperimental, amdproduction, amdgfx942nightly, amdmi300] agent_pool: mi300_1 - parallelism: 4 + optional: true + parallelism: 5 working_dir: "/vllm-workspace/tests" source_file_dependencies: - csrc/quantization/cutlass_w8a8/moe/ @@ -3082,10 +3083,10 @@ steps: - pytest -v -s kernels/attention --shard-id=$$BUILDKITE_PARALLEL_JOB --num-shards=$$BUILDKITE_PARALLEL_JOB_COUNT - label: Kernels MoE Test %N # TBD - timeout_in_minutes: 180 + timeout_in_minutes: 50 mirror_hardwares: [amdexperimental, amdproduction, amdgfx950nightly, amdmi355] agent_pool: mi355_1 - parallelism: 4 + parallelism: 5 working_dir: "/vllm-workspace/tests" source_file_dependencies: - csrc/quantization/cutlass_w8a8/moe/ diff --git a/.buildkite/test_areas/kernels.yaml b/.buildkite/test_areas/kernels.yaml index ebcb95a9d8..4c1117440a 100644 --- a/.buildkite/test_areas/kernels.yaml +++ b/.buildkite/test_areas/kernels.yaml @@ -128,6 +128,22 @@ steps: - pytest -v -s kernels/moe --ignore=kernels/moe/test_modular_oai_triton_moe.py --shard-id=$$BUILDKITE_PARALLEL_JOB --num-shards=$$BUILDKITE_PARALLEL_JOB_COUNT - pytest -v -s kernels/moe/test_modular_oai_triton_moe.py --shard-id=$$BUILDKITE_PARALLEL_JOB --num-shards=$$BUILDKITE_PARALLEL_JOB_COUNT parallelism: 5 + mirror: + amd: + device: mi325_1 + timeout_in_minutes: 50 + source_file_dependencies: + - csrc/quantization/cutlass_w8a8/moe/ + - csrc/moe/ + - tests/kernels/moe + - vllm/model_executor/layers/fused_moe/ + - vllm/distributed/device_communicators/ + - vllm/envs.py + - vllm/config + - vllm/_aiter_ops.py + - vllm/platforms/rocm.py + depends_on: + - image-build-amd - label: Kernels Mamba Test key: kernels-mamba-test diff --git a/tests/kernels/moe/test_ocp_mx_moe.py b/tests/kernels/moe/test_ocp_mx_moe.py index 5c52c8af6a..fb5ae527b2 100644 --- a/tests/kernels/moe/test_ocp_mx_moe.py +++ b/tests/kernels/moe/test_ocp_mx_moe.py @@ -9,6 +9,7 @@ import pytest import torch from packaging import version +from vllm._aiter_ops import is_aiter_found from vllm.platforms import current_platform from vllm.utils.flashinfer import has_flashinfer @@ -31,17 +32,15 @@ HOPPER_MXFP4_BF16_AVAILABLE = ( # ROCm platform and dependencies ROCM_AVAILABLE = current_platform.is_rocm() ROCM_TRITON_KERNELS_AVAILABLE = False -ROCM_AITER_AVAILABLE = False +ROCM_AITER_AVAILABLE = is_aiter_found() ROCM_GFX950 = False if ROCM_AVAILABLE: - from vllm._aiter_ops import rocm_aiter_ops from vllm.platforms.rocm import on_gfx950 from vllm.utils.import_utils import has_triton_kernels ROCM_TRITON_KERNELS_AVAILABLE = has_triton_kernels() ROCM_GFX950 = on_gfx950() - ROCM_AITER_AVAILABLE = rocm_aiter_ops.is_enabled() if ROCM_AITER_AVAILABLE: from aiter.ops.triton.moe.quant_moe import upcast_from_mxfp @@ -83,7 +82,7 @@ def enable_pickle(monkeypatch): [ ModelCase("fxmarty/qwen_1.5-moe-a2.7b-mxfp4", tp=2), ModelCase("fxmarty/deepseek_r1_3_layers_mxfp4", tp=8), - ModelCase("fxmarty/Llama-4-Scout-17B-16E-Instruct-2-layers-mxfp4", tp=1), + ModelCase("mawong-amd/Llama-4-Scout-17B-16E-Instruct-2-layers-mxfp4", tp=1), ModelCase("fxmarty/Llama-3.1-70B-Instruct-2-layers-mxfp6", tp=1), ModelCase("fxmarty/Llama-3.1-70B-Instruct-2-layers-mxfp6", tp=4), ], @@ -102,6 +101,7 @@ def test_mxfp4_loading_and_execution_moe(vllm_runner, model_case: ModelCase): tensor_parallel_size=model_case.tp, load_format="dummy", compilation_config={"cudagraph_capture_sizes": [16]}, + gpu_memory_utilization=0.8, # mxfp6 models use more scratch space ) as llm: # Disabled as check_model is broken: https://github.com/vllm-project/vllm/pull/18465#issuecomment-3329880562 # def check_model(model): @@ -1267,7 +1267,7 @@ def test_rocm_mxfp4_moe_oracle( This test validates that the oracle functions work end-to-end: - select_mxfp4_moe_backend() selects a valid backend - - convert_to_mxfp4_moe_kernel_format() converts weights without error + - convert_gpt_oss_weight_to_mxfp4_moe_kernel_format() converts weights without error - make_mxfp4_moe_quant_config() builds a valid quant config - make_mxfp4_moe_kernel() creates a kernel that runs without error - The kernel output is within accuracy tolerance of reference @@ -1287,7 +1287,7 @@ def test_rocm_mxfp4_moe_oracle( from vllm.model_executor.layers.fused_moe.oracle.mxfp4 import ( Mxfp4MoeBackend, backend_to_kernel_cls, - convert_to_mxfp4_moe_kernel_format, + convert_gpt_oss_weight_to_mxfp4_moe_kernel_format, make_mxfp4_moe_kernel, make_mxfp4_moe_quant_config, ) @@ -1387,7 +1387,7 @@ def test_rocm_mxfp4_moe_oracle( # Convert weights using oracle w13_conv, w2_conv, w13_scale_conv, w2_scale_conv, w13_bias_conv, w2_bias_conv = ( - convert_to_mxfp4_moe_kernel_format( + convert_gpt_oss_weight_to_mxfp4_moe_kernel_format( mxfp4_backend=backend, layer=layer, # type: ignore[arg-type] w13_weight=w13_quant, @@ -1423,7 +1423,7 @@ def test_rocm_mxfp4_moe_oracle( mxfp4_backend=backend, experts_cls=experts_cls, routing_tables=None, - shared_experts=None, + layer=None, ) # Create inputs