Browse Source

Fix ut.

tags/v1.5.1
zhaozhixuan 3 years ago
parent
commit
8e6c104db9
2 changed files with 1 additions and 2 deletions
  1. +1
    -1
      ge/single_op/single_op_model.cc
  2. +0
    -1
      tests/ut/ge/single_op/single_op_model_unittest.cc

+ 1
- 1
ge/single_op/single_op_model.cc View File

@@ -596,7 +596,7 @@ Status SingleOpModel::BuildTaskListForDynamicOp(StreamResource *stream_resource,
const auto &atomic_task_def = task_defs.front();
AtomicOpTask *atomic_task = nullptr;
GE_CHK_STATUS_RET_NOLOG(BuildAtomicTask(atomic_task_def, &atomic_task));
atomic_task->InitAtomicAddrCleanIndices();
GE_CHK_STATUS_RET_NOLOG(atomic_task->InitAtomicAddrCleanIndices());
tbe_task->SetAtomicTask(atomic_task);
}
single_op.op_task_.reset(tbe_task);


+ 0
- 1
tests/ut/ge/single_op/single_op_model_unittest.cc View File

@@ -346,7 +346,6 @@ TEST_F(UtestSingleOpModel, build_dynamic_task) {
model.model_helper_.model_ = ge_model;
auto op_desc = std::make_shared<ge::OpDesc>("add", "Add");
AttrUtils::SetStr(op_desc, TVM_ATTR_NAME_MAGIC, "RT_DEV_BINARY_MAGIC_ELF");
AttrUtils::SetBool(op_desc, kAttrSupportDynamicShape, true);
std::vector<char> kernelBin;
TBEKernelPtr tbe_kernel = std::make_shared<ge::OpKernelBin>("name/Add", std::move(kernelBin));
op_desc->SetExtAttr(ge::OP_EXTATTR_NAME_TBE_KERNEL, tbe_kernel);


Loading…
Cancel
Save