Skip to content

Commit

Permalink
binary buffer by vector<uint8_t>
Browse files Browse the repository at this point in the history
  • Loading branch information
e-ddykim committed Nov 15, 2022
1 parent 424871b commit 0b6465f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/plugins/intel_gpu/src/graph/primitive_inst.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1101,10 +1101,10 @@ void primitive_inst::load(cldnn::BinaryInputBuffer& ib) {
if (_allocation_type == allocation_type::usm_host || _allocation_type == allocation_type::usm_shared) {
ib >> cldnn::make_data(_outputs[0]->buffer_ptr(), data_size);
} else {
char *_buf = new char[data_size];
ib >> cldnn::make_data(_buf, data_size);
_outputs[0]->copy_from(get_network().get_stream(), _buf);
delete[] _buf;
std::vector<uint8_t> _buf;
_buf.resize(data_size);
ib >> cldnn::make_data(_buf.data(), data_size);
_outputs[0]->copy_from(get_network().get_stream(), _buf.data());
}
} else if (_object_type == object_type::EXECUTABLE_INST) {
_impl_params.release();
Expand Down

0 comments on commit 0b6465f

Please sign in to comment.