Skip to content

Conversation

HuanyuCai
Copy link
Contributor

reported by Valgrind:

==25812== Invalid read of size 8
==25812== at 0x80A052E: std::__shared_ptr<tim::vx::Tensor, (__gnu_cxx::_Lock_policy)2>::__shared_ptr(std::__shared_ptr<tim::vx::Tensor, (__gnu_cxx::_Lock_policy)2> const&) (shared_ptr_base.h:1121)
==25812== by 0x80A0578: std::shared_ptrtim::vx::Tensor::shared_ptr(std::shared_ptrtim::vx::Tensor const&) (shared_ptr.h:119)
==25812== by 0x891FD52: tim::transform::LayoutInference(std::shared_ptrtim::vx::Graph const&, std::shared_ptrtim::vx::Context&, std::map<std::shared_ptrtim::vx::Tensor, std::shared_ptrtim::transform::IPermuteVector, std::less<std::shared_ptrtim::vx::Tensor >, std::allocator<std::pair<std::shared_ptrtim::vx::Tensor const, std::shared_ptrtim::transform::IPermuteVector > > >) (layout_inference.cc:331)
==25812== by 0x809DA98: vx::delegate::Delegate::Invoke(vx::delegate::OpData const&, TfLiteContext*, TfLiteNode*) (delegate_main.cc:646)
==25812== by 0x809A882: (anonymous namespace)::DelegateNodeRegistration()::{lambda(TfLiteContext*, TfLiteNode*)#4}::operator()(TfLiteContext*, TfLiteNode*) const (delegate_main.cc:77)
==25812== by 0x809A8A9: (anonymous namespace)::DelegateNodeRegistration()::{lambda(TfLiteContext*, TfLiteNode*)#4}::_FUN(TfLiteContext*, TfLiteNode*) (delegate_main.cc:78)
==25812== by 0x2B3377: tflite::Subgraph::OpInvoke(TfLiteRegistration const&, TfLiteNode*) (subgraph.cc:1013)
==25812== by 0x2B42F9: tflite::Subgraph::Invoke() (subgraph.cc:1280)
==25812== by 0x2656EA: tflite::Interpreter::Invoke() (interpreter.cc:230)
==25812== by 0x136A03: tflite::benchmark::BenchmarkTfLiteModel::RunImpl() (benchmark_tflite_model.cc:848)
==25812== by 0x12451F: tflite::benchmark::BenchmarkModel::Run(int, float, float, tflite::benchmark::RunType, TfLiteStatus*) (benchmark_model.cc:227)
==25812== by 0x1251CB: tflite::benchmark::BenchmarkModel::Run() (benchmark_model.cc:315)

this invalid read was fixed in layout_inference.cc by this commit

@sunshinemyson sunshinemyson merged commit 9ab00a5 into VeriSilicon:main Jan 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants