[main][bugfix] Fix MatmulNZ format bug on some machines (#2549)

### What this PR does / why we need it?
This PR fixes the bug on some machines where quantmatmul failed to run
with the NZ format. The change ensures proper execution under the
expected data layout.

### How was this patch tested?
CI passed with existing test.

- vLLM version: v0.10.1.1
- vLLM main:
https://github.com/vllm-project/vllm/commit/b5d34af3286ee0334d9f7bd729774ac55c5805e9

Signed-off-by: rjg-lyh <1318825571@qq.com>
This commit is contained in:
rjg-lyh authored and GitHub committed 2025-08-27 09:08:17 +08:00
1 parent 042605f4b2
commit 358ba68994
1 file changed
+3
+3
View File
@@ -112,6 +112,9 @@ import torch_npu
import vllm_ascend.envs as envs_ascend
# if true, allow tensor initialization and casting with internal format (e.g., NZ)
torch.npu.config.allow_internal_format = True
if is_310p():
torch_npu.npu.set_compile_mode(jit_compile=False)
ACL_FORMAT = ACL_FORMAT_FRACTAL_NZ