- Enable checkers for MISRA C:2012 Rule 17.2, MISRA C:2004 Rule 16.2 or JSF Rule 119.
- Compute the metric 'Number of recursions'.
Can Polyspace prove recursion to be impossible?
조회 수: 3 (최근 30일)
이전 댓글 표시
We have a statemachine implementation in C for an embedded automotive product, using a table-approach. The table contains pointers to functions handling the transition and during actions for states. As these functions can call the table again, there is a chance on recursion (reported by another 3rd party static code analysis tool).
From the code design we 'know' it is not possible to have recursion, but we need proof for that as we're following ISO26262-6 (ASIL-C) and MISRA-2012 rules. From these norms, recursion in the implementation is not allowed.
Can polyspace bugfinder/codeprover report on the recursion of this tabular approached state machine implementation? If yes, how?
댓글 수: 0
답변 (1개)
Anirban
2018년 12월 13일
Polyspace can detect use of recursion. There are many ways you can turn on recursion detection:
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Run Settings에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!