[Kernel] Support DCP for Triton backend (#25132)

Signed-off-by: Wei Wei <wwei6@meta.com>
This commit is contained in:
Wei Wei
2025-09-24 18:09:34 -07:00
committed by GitHub
parent 52d0cb8458
commit 05c19485a5
4 changed files with 30 additions and 8 deletions

View File

@@ -685,7 +685,7 @@ class DeepseekV2DecoderLayer(nn.Module):
) -> torch.Tensor:
# Self Attention
if residual is None:
residual = hidden_states
residual = hidden_states.clone()
hidden_states = self.input_layernorm(hidden_states)
else:
hidden_states, residual = self.input_layernorm(