blob: 1c74388d914fee6629c690fe10f5845538d44e7c (
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
|
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#pragma once
#include <vespa/eval/eval/tensor_function.h>
namespace vespalib::eval {
/**
* Tensor function that will count the number of cells in the result
* of a join between two tensors with full mapped overlap consisting
* of a single dimension.
**/
class SimpleJoinCount : public tensor_function::Op2
{
private:
uint64_t _dense_factor;
public:
SimpleJoinCount(const TensorFunction &lhs_in, const TensorFunction &rhs_in, uint64_t dense_factor_in);
InterpretedFunction::Instruction compile_self(const ValueBuilderFactory &factory, Stash &stash) const override;
bool result_is_mutable() const override { return true; }
uint64_t dense_factor() const { return _dense_factor; }
static const TensorFunction &optimize(const TensorFunction &expr, Stash &stash);
};
} // namespace
|