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

daisytuner / docc / 23133769037

16 Mar 2026 08:06AM UTC coverage: 63.973% (+0.4%) from 63.617%
23133769037

Pull #585

github

web-flow
Merge 2c349afc3 into 6cf8b66cf
Pull Request #585: Undefined Subsets access after KLS Transformation

10 of 10 new or added lines in 1 file covered. (100.0%)

895 existing lines in 22 files now uncovered.

26035 of 40697 relevant lines covered (63.97%)

403.91 hits per line

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

81.82
/sdfg/src/data_flow/library_nodes/math/tensor/elementwise_ops/div_node.cpp
1
#include "sdfg/data_flow/library_nodes/math/tensor/elementwise_ops/div_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
DivNode::DivNode(
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
)
18
    : ElementWiseBinaryNode(element_id, debug_info, vertex, parent, LibraryNodeType_Div, shape) {}
9✔
19

20
bool DivNode::expand_operation(
21
    builder::StructuredSDFGBuilder& builder,
22
    analysis::AnalysisManager& analysis_manager,
23
    structured_control_flow::Sequence& body,
24
    const std::string& input_name_a,
25
    const std::string& input_name_b,
26
    const std::string& output_name,
27
    const types::Tensor& input_type_a,
28
    const types::Tensor& input_type_b,
29
    const types::Tensor& output_type,
30
    const data_flow::Subset& subset
31
) {
6✔
32
    auto& code_block = builder.add_block(body);
6✔
33

34
    bool is_int = types::is_integer(output_type.primitive_type());
6✔
35
    data_flow::TaskletCode opcode;
6✔
36
    if (is_int) {
6✔
37
        // Distinguish between signed and unsigned division
38
        bool is_signed = types::is_signed(output_type.primitive_type());
2✔
39
        opcode = is_signed ? data_flow::TaskletCode::int_sdiv : data_flow::TaskletCode::int_udiv;
2✔
40
    } else {
4✔
41
        opcode = data_flow::TaskletCode::fp_div;
4✔
42
    }
4✔
43
    auto& tasklet = builder.add_tasklet(code_block, opcode, "_out", {"_in1", "_in2"});
6✔
44

45
    auto& output_node = builder.add_access(code_block, output_name);
6✔
46
    builder.add_computational_memlet(code_block, tasklet, "_out", output_node, subset, output_type);
6✔
47

48
    create_input_memlet(builder, "_in1", input_name_a, input_type_a, subset, code_block, tasklet);
6✔
49
    create_input_memlet(builder, "_in2", input_name_b, input_type_b, subset, code_block, tasklet);
6✔
50

51
    return true;
6✔
52
}
6✔
53

54
std::unique_ptr<data_flow::DataFlowNode> DivNode::
UNCOV
55
    clone(size_t element_id, const graph::Vertex vertex, data_flow::DataFlowGraph& parent) const {
×
UNCOV
56
    return std::unique_ptr<
×
UNCOV
57
        data_flow::DataFlowNode>(new DivNode(element_id, this->debug_info(), vertex, parent, this->shape_));
×
58
}
×
59

60
} // namespace tensor
61
} // namespace math
62
} // 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