• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

daisytuner / docc / 26831349290

02 Jun 2026 03:50PM UTC coverage: 61.29% (-0.01%) from 61.302%
26831349290

Pull #725

github

web-flow
Merge a7e2175c0 into 887730e20
Pull Request #725: Tensor node backport

932 of 1642 new or added lines in 52 files covered. (56.76%)

92 existing lines in 33 files now uncovered.

35584 of 58058 relevant lines covered (61.29%)

11020.18 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

78.26
/sdfg/src/data_flow/library_nodes/math/tensor/elementwise_ops/add_node.cpp
1
#include "sdfg/data_flow/library_nodes/math/tensor/elementwise_ops/add_node.h"
2

3
#include "sdfg/analysis/analysis.h"
4
#include "sdfg/builder/structured_sdfg_builder.h"
5
#include "sdfg/types/type.h"
6

7
namespace sdfg {
8
namespace math {
9
namespace tensor {
10

11
AddNode::AddNode(
12
    size_t element_id,
13
    const DebugInfo& debug_info,
14
    const graph::Vertex vertex,
15
    data_flow::DataFlowGraph& parent,
16
    const std::vector<symbolic::Expression>& shape,
17
    QuantizationType quantization,
18
    const data_flow::ImplementationType& impl_type
19
)
20
    : ElementWiseDataflowTensorNode(
8✔
21
          element_id, debug_info, vertex, parent, LibraryNodeType_Add, shape, "C", {"A", "B"}, quantization, impl_type
8✔
22
      ) {}
8✔
23

24
ElementWiseDataflowTensorNode::ElementOutput AddNode::expand_operation_dataflow(
25
    builder::StructuredSDFGBuilder& builder,
26
    analysis::AnalysisManager& analysis_manager,
27
    Block& block,
28
    std::vector<ElementInput>& needed_inputs,
29
    types::PrimitiveType expected_type
30
) {
6✔
31
    auto& input0 = needed_inputs.at(0);
6✔
32

33
    data_flow::TaskletCode opcode;
6✔
34
    if (types::is_integer(input0.required_type)) {
6✔
35
        opcode = data_flow::TaskletCode::int_add;
1✔
36
    } else {
5✔
37
        opcode = data_flow::TaskletCode::fp_add;
5✔
38
    }
5✔
39
    auto& tasklet = builder.add_tasklet(block, opcode, "_out", {"_in1", "_in2"});
6✔
40
    input0.consumer = &tasklet;
6✔
41
    input0.input_conn_index = 0;
6✔
42
    needed_inputs.at(1).consumer = &tasklet;
6✔
43
    needed_inputs.at(1).input_conn_index = 1;
6✔
44
    return {.producer = &tasklet, .output_conn_index = 0, .type = input0.required_type};
6✔
45
}
6✔
46

47
std::unique_ptr<data_flow::DataFlowNode> AddNode::
48
    clone(size_t element_id, const graph::Vertex vertex, data_flow::DataFlowGraph& parent) const {
×
NEW
49
    return std::unique_ptr<data_flow::DataFlowNode>(new AddNode(
×
NEW
50
        element_id, this->debug_info(), vertex, parent, this->shape_, fixed_quantization_, implementation_type_
×
NEW
51
    ));
×
UNCOV
52
}
×
53

54
} // namespace tensor
55
} // namespace math
56
} // namespace sdfg
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc