Reactis for C brings many of features of Reactis to projects that do not use Simulink. Instead, this version of Reactis may be applied directly to the C code that implements an application. You can generate tests from C code, detect run-time errors, track coverage: (Statement, Decision, Condition, MC/DC). When an error is detected, you can replay a concrete execution sequence leading to the problem in order to understand, diagnose, and fix the bug.
Reactis for C can be used along with Reactis for Simulink to offer
a robust solution for back-to-back testing of C code against a Simulink
model.
Reactis for C supports a very large subset of the ANSI C99 standard.
A list of unsupported features can be found
here.
You first create a Reactis Build File to enumerate the C files that make up your project. You then create a harness to specify:
Reactis for C automatically detects many kinds of memory errors, including
buffer overruns, out-of-bound array indices, and accessing heap or stack
memory after the memory has been recycled. Reactis for C also automatically
detects common numeric errors such as integer overflows,
integer divide by zero, and invalid shifts.
In addition, Reactis for C detects violations of user-defined assertions.
Reactis for C performs some limited static analysis, but its primary
engine for runtime error detection works by dynamic simulation of C
programs. Reactis for C performs static analysis to identify unreachable
coverage targets, such as statement targets within a function that is never
called.
Yes. Reactis for C can be configured to flag an error if a program
generates and Inf or NaN value. Reactis for C follows the IEEE 754
standard, which specifies that positive overflows produce a result of
positive infinity, negative overflows produce a result of negative
infinity, and dividing x by zero (in floating-point) produces a result of
positive infinity if x is positive, negative infinity if x is negative, and
NaN (not-a-number) if x equals zero.
Probably not. Many programs with memory errors will run correctly most of the time. For example, a program with a buffer overrun may happen to overwrite a variable which is not used after the overwrite occurs. Reactis for C will detect such overwrites and halt program execution as soon as they occur. Many buffer overruns do not cause problems until they are exploited by a malicious agent to hijack control of your system.
Of course, there is always a chance (as there
is with any error detection tool) that Reactis for C has
incorrectly reported an "error" where none exists.
If you believe this is the case, please contact
Reactive Systems.
Reactis for C works with standalone C code not incorporated in any
model, whereas Reactis for C Plugin only works with Simulink S-functions
and Stateflow custom code which are written in C.
No, because S-functions and custom code use MATLAB libraries which
are not included with Reactis for C. It is of course possible to use
S-function and custom code fragments which do not depend on
MATLAB library code with Reactis for C.
Currently, Reactis for C execute programs in
a virtual x86 (32-bit) machine architecture.
Both the 32-bit and 64-bit versions of Reactis for C
provide the same virtual 32-bit architecture.
In terms of the virtual machine used to execute compiled C programs,
there is no difference. On host machines with at least 4GB of memory,
the 64-bit version may be able to take advantage of the extra memory to
improve performance and handle larger programs and test suites.
However, the 64-bit version will typically use more memory than the 32-bit
version, so there is a trade-off involved.
Other than this, there is no observable difference between the two
versions.
Reactis for C does not use an external C compiler. It uses its
own built-in compiler instead.
No. Reactis for C does not work binary code. Reactis for C only works
with C source code.
Unlikely. The system header files (stdio.h, stdlib.h, etc.) are
usually not portable.