Add hstu_attention_api.hpp to explicitly mark the API interfaces and update REAMD.md

This commit is contained in:
Qianfeng Zhang
2025-11-27 08:04:47 +00:00
parent f9e8c5539f
commit 69c97c06d7
3 changed files with 16 additions and 7 deletions

View File

@@ -13,8 +13,8 @@
``` bash
#> mkdir build
#> cd build
#> ../script/cmake-ck-dev.sh .. gfx942 ; use #> rocminfo |grep "gfx" to check your gpu arch
#> make -j tile_example_hstu_attention
#> ../script/cmake-ck-dev.sh .. gfx942 -G Ninja ; use #> rocminfo |grep "gfx" to check your gpu arch
#> ninja tile_example_hstu_attention ; or using make -j tile_example_hstu_attention ;
```
## test/verify

View File

@@ -27,11 +27,7 @@
#include "reference_hstu_attention.hpp"
#include "hstu_attention_util.hpp"
extern void hstu_attention_batched_forward_fp16(HstuAttentionFwdParams& param, hipStream_t stream);
extern void hstu_attention_batched_forward_bf16(HstuAttentionFwdParams& param, hipStream_t stream);
extern void hstu_attention_jagged_forward_fp16(HstuAttentionFwdParams& param, hipStream_t stream);
extern void hstu_attention_jagged_forward_bf16(HstuAttentionFwdParams& param, hipStream_t stream);
#include "hstu_attention_api.hpp"
template <typename T>
void dumpBufferToFile(const char* fileName, T* data, size_t dataNumItems)

View File

@@ -0,0 +1,13 @@
// SPDX-License-Identifier: MIT
// Copyright (c) 2018-2025, Advanced Micro Devices, Inc. All rights reserved.
#pragma once
#include <ck_tile/core.hpp>
#include "hstu_attention_params.hpp"
extern void hstu_attention_batched_forward_fp16(HstuAttentionFwdParams& param, hipStream_t stream);
extern void hstu_attention_batched_forward_bf16(HstuAttentionFwdParams& param, hipStream_t stream);
extern void hstu_attention_jagged_forward_fp16(HstuAttentionFwdParams& param, hipStream_t stream);
extern void hstu_attention_jagged_forward_bf16(HstuAttentionFwdParams& param, hipStream_t stream);