Questions tagged [safety-critical]

Software is [safety-critical] when an incorrect response or an incorrectly timed response can result in significant loss to its users; in the most extreme case, loss of life may result from such failures.

A software is when an incorrect response or an incorrectly timed response can result in significant loss to its users; in the most extreme case, loss of life may result from such failures.

Safety-critical applications require an exceedingly rigorous validation and certification process.

46 questions
148
votes
13 answers

What is the benefit of terminating if … else if constructs with an else clause?

Our organization has a required coding rule (without any explanation) that: if … else if constructs should be terminated with an else clause Example 1: if ( x < 0 ) { x = 0; } /* else not needed */ Example 2: if ( x < 0 ) { x = 0; } else…
Van Tr
  • 5,889
  • 2
  • 20
  • 44
35
votes
3 answers

Rulesets for cppcheck

Cppcheck allows you to create your own rules files, but I don't know how much of cppcheck's functionality is exposed. Is anyone working on a set that would enforce JSF or MISRA rules?
Martin Beckett
  • 94,801
  • 28
  • 188
  • 263
31
votes
1 answer

Formal methods in C++ for safety critical software

Looking at C, C has good support for formal methods that can be used in-code(frama-c, VCC, verifast). C++ doesn't seem to have any comparable as far as I can tell. What formal methods are available for reasoning about safety-critical software…
willfredthebuel
  • 339
  • 2
  • 6
14
votes
2 answers

Testing C++17 in safety critical systems

I'm currently thinking about C++ in safety-critical software (DO-178C DAL-D) and definitions of a coding standard. I was looking at MISRA C++ which is again 10 years old and misses all the C++11…17 features. While being conservative regarding…
Hhut
  • 1,128
  • 1
  • 12
  • 24
12
votes
3 answers

How to certify a compiler for functional safety?

We are ISO-13485 and do development for medical devices. We currently use the IAR certified compiler, but we are thinking to switch to gcc because it is cross platform and the build can be automated with plain Makefile which is not possible with…
nowox
  • 25,978
  • 39
  • 143
  • 293
11
votes
1 answer

Alternatives to dynamic allocations in safety critical projects (C)

Safety critical projects do not recommend any dynamic allocations or freeing allocated memory. Only during elaboration/initialization phase of the program execution, it is allowed. I know most of you will argue to implement SW in terms where it…
Akay
  • 1,092
  • 12
  • 32
5
votes
1 answer

What is the best resource for learning about Safety Critical Systems Development (C/C++)

I'm looking to locate a good resource (book or otherwise) on safety critical systems development techniques/methodologies, especially something that will cover both hardware and software . I have a sound working knowledge of C/C++, so even if it is…
mdec
  • 5,122
  • 4
  • 25
  • 26
5
votes
1 answer

Is it possible to certify an AI-based solution for safety-critical systems?

First, I read this. But I would like to expand. To summarize: When designing safety-critical systems a designer has to evaluate some metrics to get the confidence that the system will work as expected. It is, kind of, a mathematical proof with low…
5
votes
1 answer

Algorithmic trading software safety guards

I'm working on an automatic trading system. What sorts of safe-guards should I have in place? The main idea I have is to have multiple pieces checking each other. I will have a second independent little process which will also connect to the same…
Meh
  • 7,016
  • 10
  • 53
  • 76
5
votes
5 answers

Misra violation 12.6

How to get rid of MISRA violation on following statement typedef unsigned char boolean; boolean A, B; A = !B; Operand of logical ! operator is not an 'effectively Boolean' expression. MISRA-C:2004 Rule 12.6; REFERENCE - ISO:C90-6.3.3.3 Unary …
user3285192
  • 93
  • 2
  • 12
4
votes
1 answer

Qt Research/Academic/Journal Papers/Articles

I'm trying to find any research/academic/journal papers/articles that analyze recent versions of Qt and Qt Creator. Specifically, I'm trying to evaluate Qt from a real-time safety critical perspective, so any information is helpful. P.S. I've…
JustADude
  • 2,619
  • 7
  • 31
  • 45
4
votes
3 answers

Why not put task context in interrupt

Here is the story. Its a safety critical project and needs to run a time critical functional routine in 20KHz. Now the design is to put functional routine in a 20KHz FIQ interrupt, meanwhile safety interrupt also in FIQ. Thats the only two FIQ in…
Tian
  • 61
  • 9
4
votes
1 answer

State Machine with no function pointer

I have implemented a complex state machine with numerous state transitions for a safety SIL 4 system. The back bone for this implementation was done using function pointers. When all was sailing smoothly, the V&V opposed the use of function pointers…
AlphaGoku
  • 968
  • 1
  • 9
  • 24
4
votes
2 answers

C++ Operator overloading error check without exceptions

I have a class similar to vector that is primarily a dynamically sized array. I am writing it for a resource-limited platform so I am required to not use exceptions. It has become clear that to use operator overloading to simplify the interface for…
jayjay
  • 1,017
  • 1
  • 11
  • 23
3
votes
1 answer

C boolean invalid values handling

I'm in a safety critical embedded C project and there's a discussion about detecting memory corruptions (e.g. buffer overflows) in boolean variables. As everyone knows, in C, the "boolean" type is actually an N-bit integer and that means it has…
Mikk L.
  • 161
  • 2
  • 9
1
2 3 4