aboutsummaryrefslogtreecommitdiffstats
path: root/eval/src/vespa/eval/streamed/streamed_value.cpp
blob: 80a139d1ff350630e55c3cc799935300233adf04 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
// Copyright Vespa.ai. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.

#include "streamed_value.h"
#include <vespa/log/log.h>

LOG_SETUP(".vespalib.eval.streamed.streamed_value");

namespace vespalib::eval {

template <typename T>
StreamedValue<T>::~StreamedValue() = default;

template <typename T>
MemoryUsage
StreamedValue<T>::get_memory_usage() const
{
    MemoryUsage usage = self_memory_usage<StreamedValue<T>>();
    usage.merge(vector_extra_memory_usage(_my_cells));
    usage.merge(vector_extra_memory_usage(_my_labels.view()));
    return usage;
}

template class StreamedValue<double>;
template class StreamedValue<float>;
template class StreamedValue<BFloat16>;
template class StreamedValue<Int8Float>;

} // namespace