lf-lang / reactor-uc

A lightweight reactor runtime targeted at resource-constrained embedded systems
BSD 2-Clause "Simplified" License
2 stars 2 forks source link

Add level-assignment algorithm, without causality cycle check #6

Closed erlingrj closed 1 month ago

erlingrj commented 1 month ago

@tanneberger Here I port your level assignment implementation and put it in the runtime (instead of requiring it to be code-generated). Still missing causality cycle check though.

github-actions[bot] commented 1 month ago

Coverage after merging level-assignment into main will be

16.80%

Coverage Report
FileStmtsBranchesFuncsLinesUncovered Lines
src
   builtin_triggers.c0%100%0%0%3–6
   connection.c0%0%0%0%10–11, 11, 11–12, 14, 16–17, 21–22, 22, 22, 24–25, 27, 27, 27–29, 29, 29–30, 32, 34–39, 4, 40–41, 43–44, 5, 5, 5, 7, 7, 7, 7–9
   environment.c0%100%0%0%10, 12–14, 16, 18, 20–21, 23, 26, 29–36, 7–9
   logical_action.c0%100%0%0%12–17, 4–7, 9
   port.c0%0%0%0%10, 12, 14–18, 20–23, 25–26, 26, 26–27, 30, 30, 30–31, 33, 33, 33–35, 37, 42, 44–46, 48–49, 6–7, 7, 7–9, 9, 9
   queues.c55.48%44%66.67%60.22%100, 103, 109–112, 112, 112–113, 115–116, 17–18, 22–24, 24, 24–25, 30–31, 31, 31, 33–36, 36, 36, 36, 36–37, 39, 39, 39, 39, 39, 4, 40, 44, 44, 44–46, 48, 5, 50–54, 54, 54–55, 57, 6–7, 71–75, 8, 89, 94
   reaction.c0%0%0%0%11–12, 12, 12–13, 15, 19–20, 23, 23, 23–26, 26, 26–27, 32, 32, 32–34, 34, 34–35, 35, 35–36, 36, 36–38, 38, 38–40, 40, 40–43, 43, 43–44, 53, 56, 58–59, 6, 60–68, 7, 7, 7–9
   reactor.c0%0%0%0%10, 12–13, 13, 13–14, 18, 18, 18–19, 21, 23, 26–36, 7, 9
   scheduler.c0%0%0%0%10, 12, 14, 16, 20–24, 24, 24–26, 28–32, 32, 32–33, 37, 37, 37–38, 40, 40, 40, 42, 42, 42–44, 46, 48–49, 5, 51–58, 6, 6, 6–7, 9, 9, 9
   tag.c11.58%8.70%20%13.64%21, 23, 26–27, 27, 27, 27, 27–28, 30, 30, 30, 30, 30–31, 33, 33, 33–34, 36–37, 37, 37–38, 40, 40, 40, 40, 40–41, 43, 43, 43, 43, 43–44, 46, 50–51, 53–54, 56–57, 59–60, 65–66, 66, 66, 66, 66–67, 70, 70, 70–71, 73–74, 74, 74, 78, 80–81, 83, 86–88, 88, 88, 88, 88, 88, 88, 88, 88, 88, 88–90, 92
   timer.c0%100%0%0%11–12, 14–16, 4–7, 9
   trigger.c0%0%0%0%10–11, 11, 11–13, 15–16, 16, 16–18, 20, 22–30, 32–35, 5–8