Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Language: Frama-c The -wp-rte option of the plugin Wp generates ACSL annotations asserting that the program does not contain runtime errors. In the case of

Language: Frama-c

The -wp-rte option of the plugin Wp generates ACSL annotations asserting that the program does not contain runtime errors. In the case of filter it generates 3 such assertions. Two are related to accesses in the arrays t and mask, one is related to arithmetic overflow. Complete the file filter.c so that when issuing the command: frama-c-gui -wp -wp-rte filter.c all the RTE assertions are proved correct. Using the command-line version of Frama-C with the following command:frama-c-gui -wp -wp-rte filter.c

#include "limits.h" /*@ assigns othing; */ int condition(int v); /* @ requires TO COMPLETE ; @ requires TO COMPLETE ; @ requires TO COMPLETE ;*/ void filter(int * t, char * mask, int size) { /*@ loop invariant 0 <= i <= size; @ loop assigns i, *(mask+(0..i)); */ for(int i=0; i                        

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions