Optimize inputs -> counter -> trigger always
Open
iotile-sensorgraph
type:enhancement
- Dominant language
- Python
- Stars
- 14
- Forks
- 7
- PR merge metrics
- No merged PRs in 30d
Description
There is an autogenerated node pattern that can be easily optimized. When a counter is attached to an input to produce timers but the timers are always triggered, there is no need for the intermediate counter:
See:
```
(system input 3 always) => counter 1025 using copy_latest_a
(counter 1025 always && constant 1034 when value == 1) => counter 1031 using copy_latest_a
```
This should be just:
```
(system input 3 always && constant 1034 when value == 1) => counter 1031 using copy_latest_a
```
Contributor guide
Assessment
This issue has not been assessed yet.