Skip to content

Commit a4401bc

Browse files
committed
Update
[ghstack-poisoned]
2 parents fda8deb + e42e0ae commit a4401bc

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

backends/webgpu/test/native/test_dynamic_shape.cpp

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,10 @@ void check_sdpa(int s) {
140140
auto kc = read_bin(b + "kc.bin");
141141
auto vc = read_bin(b + "vc.bin");
142142
auto golden = read_bin(b + "golden.bin");
143-
ASSERT_FALSE(q.empty() || golden.empty()) << "missing sdpa_dyn.S" << s;
143+
ASSERT_FALSE(
144+
q.empty() || k.empty() || v.empty() || kc.empty() || vc.empty() ||
145+
golden.empty())
146+
<< "missing sdpa_dyn.S" << s;
144147
auto tq = make_tensor_ptr({1, s, kSdHq, kSdD}, std::move(q));
145148
auto tk = make_tensor_ptr({1, s, kSdHkv, kSdD}, std::move(k));
146149
auto tv = make_tensor_ptr({1, s, kSdHkv, kSdD}, std::move(v));
@@ -216,7 +219,10 @@ void check_rope(int s) {
216219
auto fs = read_bin(b + "fs.bin");
217220
auto gq = read_bin(b + "gq.bin");
218221
auto gk = read_bin(b + "gk.bin");
219-
ASSERT_FALSE(xq.empty() || gq.empty()) << "missing rope_dyn.S" << s;
222+
ASSERT_FALSE(
223+
xq.empty() || xk.empty() || fc.empty() || fs.empty() || gq.empty() ||
224+
gk.empty())
225+
<< "missing rope_dyn.S" << s;
220226
auto txq = make_tensor_ptr({1, s, kRopeNH, kRopeHD}, std::move(xq));
221227
auto txk = make_tensor_ptr({1, s, kRopeNKV, kRopeHD}, std::move(xk));
222228
auto tfc = make_tensor_ptr({s, kRopeHD / 2}, std::move(fc));

0 commit comments

Comments
 (0)