Skip to content
Open
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
14 changes: 14 additions & 0 deletions tests/test_qkv_format_to_string.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
/*************************************************************************
* Copyright (c) 2022-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved.
*
* See LICENSE for license information.
************************************************************************/

#include <gtest/gtest.h>
#include <string>

#include "transformer_engine/fused_attn.h"

TEST(QKVFormatToString, BHSD) {
EXPECT_EQ(transformer_engine::to_string(NVTE_QKV_Format::NVTE_BHSD), "NVTE_BHSD");
}
Comment thread
greptile-apps[bot] marked this conversation as resolved.
2 changes: 2 additions & 0 deletions transformer_engine/common/fused_attn/fused_attn.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,8 @@ std::string to_string(NVTE_QKV_Format format) {
return "NVTE_SBHD";
case NVTE_BSHD:
return "NVTE_BSHD";
case NVTE_BHSD:
return "NVTE_BHSD";
case NVTE_THD:
return "NVTE_THD";
case NVTE_BSHD_2SBHD:
Expand Down