OpenVINO™ is an open source toolkit for optimizing and deploying AI inference
C++ aicomputer-visiondeep-learningdeploy-aidiffusion-modelsgenerative-aigood-first-issueinferencellm-inferencenatural-language-processingnlpopenvinooptimize-aiperformance-boostrecommendation-systemspeech-recognitionstable-diffusiontransformersyolo
[GPU] Remove vestigial k_head_size==0 sentinel in get_sg_number_scale… (#38853)
Nikolay Shchegolev988c5db9a4a9
diff --git a/src/plugins/intel_gpu/src/graph/impls/ocl_v2/sdpa/sdpa_gen_opt.hpp b/src/plugins/intel_gpu/src/graph/impls/ocl_v2/sdpa/sdpa_gen_opt.hppindex 60fd7f7af6b..414fa152392 100644--- a/src/plugins/intel_gpu/src/graph/impls/ocl_v2/sdpa/sdpa_gen_opt.hpp+++ b/src/plugins/intel_gpu/src/graph/impls/ocl_v2/sdpa/sdpa_gen_opt.hpp@@ -32,7 +32,7 @@ inline size_t get_sg_number_scale_factor(const device_info& info, size_t head_si// kernel assumes the work-group is sized off a single head size. When K/V head sizes// differ, the per-subgroup head-index/seq-half assignment logic is not guaranteed to// produce correct coverage, so keep the safe (non-scaled) path in that case.- bool head_sizes_match = (k_head_size == 0) || (k_head_size == head_size);+ bool head_sizes_match = (k_head_size == head_size);if (head_sizes_match && head_size % subgroup_size == 0 && head_size * optimal_scale_factor <= info.max_work_group_size) {return optimal_scale_factor;}