Skip to content

Commit ee59b3f

Browse files
committed
issue/214 - update attn and caching logics
1 parent 67e8d6e commit ee59b3f

File tree

2 files changed

+0
-3
lines changed

2 files changed

+0
-3
lines changed

csrc/cache/kv_cache.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,6 @@ StaticKVCache::update(size_t layer_idx,
9696
if (device.getType() == infinicore::Device::Type::NVIDIA
9797
|| device.getType() == infinicore::Device::Type::ILUVATAR
9898
|| device.getType() == infinicore::Device::Type::METAX
99-
|| device.getType() == infinicore::Device::Type::MOORE
10099
|| device.getType() == infinicore::Device::Type::CAMBRICON) {
101100
infinicore::op::kv_caching_(
102101
k_cache_layer,

csrc/models/llama/llama_attention.cpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,8 +127,6 @@ infinicore::Tensor LlamaAttention::forward_(const infinicore::Tensor &hidden_sta
127127

128128
infinicore::Tensor attn_output;
129129
if (q_reshaped->device().getType() == infinicore::Device::Type::NVIDIA
130-
|| q_reshaped->device().getType() == infinicore::Device::Type::METAX
131-
|| q_reshaped->device().getType() == infinicore::Device::Type::MOORE
132130
|| q_reshaped->device().getType() == infinicore::Device::Type::ILUVATAR
133131
|| q_reshaped->device().getType() == infinicore::Device::Type::CAMBRICON) {
134132
attn_output = infinicore::op::flash_attention(q_reshaped, k_total, v_total, total_sequence_lengths.value(), scaling_, true);

0 commit comments

Comments
 (0)