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

daisytuner / sdfglib / 20147202960

11 Dec 2025 08:57PM UTC coverage: 40.181% (-0.09%) from 40.268%
20147202960

push

github

lukastruemper
removes timing outputs of passes

13596 of 43795 branches covered (31.04%)

Branch coverage included in aggregate %.

11609 of 18933 relevant lines covered (61.32%)

93.45 hits per line

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

31.38
/src/passes/debug_info_propagation.cpp
1
#include "sdfg/passes/debug_info_propagation.h"
2

3
namespace sdfg {
4
namespace passes {
5

6
DebugInfoPropagation::DebugInfoPropagation() : Pass() {}
2✔
7

8
void DebugInfoPropagation::propagate(structured_control_flow::ControlFlowNode* current) {
4✔
9
    auto current_debug_info = current->debug_info();
4✔
10

11
    if (auto block = dynamic_cast<structured_control_flow::Block*>(current)) {
4!
12
        auto& graph = block->dataflow();
2!
13
        for (auto& node : graph.nodes()) {
8!
14
            current_debug_info = DebugInfo::merge(current_debug_info, node.debug_info());
6!
15
        }
16
        for (auto& edge : graph.edges()) {
6!
17
            current_debug_info = DebugInfo::merge(current_debug_info, edge.debug_info());
4!
18
        }
19
    } else if (auto sequence_stmt = dynamic_cast<structured_control_flow::Sequence*>(current)) {
4!
20
        for (size_t i = 0; i < sequence_stmt->size(); i++) {
4!
21
            this->propagate(&sequence_stmt->at(i).first);
2!
22
            current_debug_info = DebugInfo::merge(current_debug_info, sequence_stmt->at(i).first.debug_info());
2!
23
            current_debug_info = DebugInfo::merge(current_debug_info, sequence_stmt->at(i).second.debug_info());
2!
24
        }
2✔
25
    } else if (auto if_else_stmt = dynamic_cast<structured_control_flow::IfElse*>(current)) {
2!
26
        for (size_t i = 0; i < if_else_stmt->size(); i++) {
×
27
            this->propagate(&if_else_stmt->at(i).first);
×
28
            current_debug_info = DebugInfo::merge(current_debug_info, if_else_stmt->at(i).first.debug_info());
×
29
        }
×
30
    } else if (auto while_stmt = dynamic_cast<structured_control_flow::While*>(current)) {
×
31
        this->propagate(&while_stmt->root());
×
32
        current_debug_info = DebugInfo::merge(current_debug_info, while_stmt->root().debug_info());
×
33
    } else if (auto loop_stmt = dynamic_cast<structured_control_flow::StructuredLoop*>(current)) {
×
34
        this->propagate(&loop_stmt->root());
×
35
        current_debug_info = DebugInfo::merge(current_debug_info, loop_stmt->root().debug_info());
×
36
    } else if (auto break_stmt = dynamic_cast<structured_control_flow::Break*>(current)) {
×
37
        current_debug_info = DebugInfo::merge(current_debug_info, break_stmt->debug_info());
×
38
    } else if (auto continue_stmt = dynamic_cast<structured_control_flow::Continue*>(current)) {
×
39
        current_debug_info = DebugInfo::merge(current_debug_info, continue_stmt->debug_info());
×
40
    } else if (auto return_stmt = dynamic_cast<structured_control_flow::Return*>(current)) {
×
41
        current_debug_info = DebugInfo::merge(current_debug_info, return_stmt->debug_info());
×
42
    } else {
×
43
        throw InvalidSDFGException("Unsupported control flow node type");
×
44
    }
45

46
    current->set_debug_info(current_debug_info);
4!
47
}
4✔
48

49
bool DebugInfoPropagation::run_pass(builder::StructuredSDFGBuilder& builder, analysis::AnalysisManager& analysis_manager) {
2✔
50
    this->propagate(&builder.subject().root());
2✔
51
    return true;
2✔
52
}
53

54
std::string DebugInfoPropagation::name() { return "DebugInfoPropagation"; }
×
55

56
} // namespace passes
57
} // 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