CBMC
|
#include <cover_basic_blocks.h>
Classes | |
struct | block_infot |
Public Member Functions | |
cover_basic_blockst (const goto_programt &goto_program) | |
std::size_t | block_of (goto_programt::const_targett t) const override |
std::optional< goto_programt::const_targett > | instruction_of (std::size_t block_nr) const override |
const source_locationt & | source_location_of (std::size_t block_nr) const override |
const source_linest & | source_lines_of (std::size_t block_nr) const override |
void | report_block_anomalies (const irep_idt &function_id, const goto_programt &goto_program, message_handlert &message_handler) override |
Output warnings about ignored blocks. More... | |
void | output (std::ostream &out) const override |
Outputs the list of blocks. More... | |
Public Member Functions inherited from cover_blocks_baset | |
virtual | ~cover_blocks_baset ()=default |
Private Types | |
typedef std::map< goto_programt::const_targett, std::size_t, goto_programt::target_less_than > | block_mapt |
Static Private Member Functions | |
static void | add_block_lines (cover_basic_blockst::block_infot &block, const goto_programt::instructiont &instruction) |
Adds the lines which instruction spans to block . More... | |
static std::optional< std::size_t > | continuation_of_block (const goto_programt::const_targett &instruction, block_mapt &block_map) |
If this block is a continuation of a previous block through unconditional forward gotos, return this blocks number. More... | |
Private Attributes | |
block_mapt | block_map |
map program locations to block numbers More... | |
std::vector< block_infot > | block_infos |
map block numbers to block information More... | |
Definition at line 65 of file cover_basic_blocks.h.
|
private |
Definition at line 108 of file cover_basic_blocks.h.
|
explicit |
Definition at line 38 of file cover_basic_blocks.cpp.
|
staticprivate |
Adds the lines which instruction
spans to block
.
Definition at line 168 of file cover_basic_blocks.cpp.
|
overridevirtual |
t | a goto instruction |
Implements cover_blocks_baset.
Definition at line 99 of file cover_basic_blocks.cpp.
|
staticprivate |
If this block is a continuation of a previous block through unconditional forward gotos, return this blocks number.
Definition at line 16 of file cover_basic_blocks.cpp.
|
overridevirtual |
block_nr | a block number |
Implements cover_blocks_baset.
Definition at line 107 of file cover_basic_blocks.cpp.
|
overridevirtual |
Outputs the list of blocks.
Implements cover_blocks_baset.
Definition at line 161 of file cover_basic_blocks.cpp.
|
overridevirtual |
Output warnings about ignored blocks.
function_id | name of goto_program |
goto_program | The goto program |
message_handler | The message handler |
Reimplemented from cover_blocks_baset.
Definition at line 127 of file cover_basic_blocks.cpp.
|
overridevirtual |
block_nr | a block number |
Implements cover_blocks_baset.
Definition at line 121 of file cover_basic_blocks.cpp.
|
overridevirtual |
block_nr | a block number |
Implements cover_blocks_baset.
Definition at line 114 of file cover_basic_blocks.cpp.
|
private |
map block numbers to block information
Definition at line 127 of file cover_basic_blocks.h.
|
private |
map program locations to block numbers
Definition at line 125 of file cover_basic_blocks.h.