Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 0 additions & 11 deletions tests/pytorch/attention/test_attention_with_cp.py
Original file line number Diff line number Diff line change
Expand Up @@ -336,11 +336,6 @@ def test_cp_with_flash_attention(cp_pool, dtype, model, qkv_format, cp_comm_type
if config.attn_bias_type != "no_bias" and cp_comm_type in ["all_gather", "a2a", "a2a+p2p"]:
pytest.skip("No support for bias with cp_comm_type={all_gather, a2a, a2a+p2p}!")

if qkv_format == "thd" and cp_comm_type == "a2a+p2p":
pytest.skip(
"CP implementation with QKVO A2A+P2P (Hierarchical A2A) does not support THD format"
" yet!"
)
if (
qkv_format == "thd"
and cp_comm_type == "all_gather"
Expand Down Expand Up @@ -558,12 +553,6 @@ def test_cp_with_fused_attention(
if config.attn_bias_type != "no_bias" and cp_comm_type in ["all_gather", "a2a", "a2a+p2p"]:
pytest.skip("No support for bias with cp_comm_type={all_gather, a2a, a2a+p2p}!")

if qkv_format == "thd" and cp_comm_type == "a2a+p2p":
pytest.skip(
"CP implementation with QKVO A2A+P2P (Hierarchical A2A) does not support THD format"
" yet!"
)

if (config.window_size[0] != -1 or config.window_size[1] not in [-1, 0]) and cp_comm_type in [
"p2p",
"a2a+p2p",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5018,9 +5018,6 @@ def attn_forward_func_with_cp(
assert (
isinstance(cp_group, list) and len(cp_group) == 2
), "CP implementation a2a+p2p requires cp_group = [a2a_cp_group, p2p_cp_group]!"
assert (
qkv_format != "thd"
), f"{qkv_format} format is not supported with hierarchical CP implementation yet!"
assert (
attn_bias_type == "no_bias"
), f"{attn_bias_type} bias type is not supported with hierarchical CP implementation yet!"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1231,13 +1231,6 @@ def _is_fa3_supported(num_heads, num_gqa_groups, head_dim_qk, head_dim_v, qkv_dt
cp_comm_type,
)
use_fused_attention = False
elif qkv_format == "thd" and cp_comm_type in ["a2a+p2p"]:
logger.debug(
"Disabling FusedAttention as it does not support context parallelism with THD"
" format and cp_comm_type = %s",
cp_comm_type,
)
use_fused_attention = False
elif (
window_size is not None
and (window_size[0] != -1 or window_size[1] not in [-1, 0])
Expand Down
Loading