Modeling imperative programs operations on memory in terms of Petri nets

The article discusses an approach to automatical creation of imperative programs models, designed to find errors in memory operations. The approach is based on the model division into compositional parts, including control flow models, variable, data types and pointers models. Models of data types a...

Full description

Bibliographic Details
Main Author: Kharitonov Dmitry
Format: Article
Language:English
Published: EDP Sciences 2023-01-01
Series:E3S Web of Conferences
Online Access:https://www.e3s-conferences.org/articles/e3sconf/pdf/2023/97/e3sconf_bft2023_04029.pdf
Description
Summary:The article discusses an approach to automatical creation of imperative programs models, designed to find errors in memory operations. The approach is based on the model division into compositional parts, including control flow models, variable, data types and pointers models. Models of data types and pointers are developed from the purposes of modeling to a proper level of detail sufficient to detect errors. To analyze the correctness of a program, a reachability graph of the model Petri net is constructed, on which deadlocks, loops, and explicitly marked erroneous events are searched. The article provides an example of a program with an error in accessing a previously freed memory block in a race condition state of parallel program threads. A model constructed for the example program in terms of Petri nets allows to track the moment an error occurs in the reachability graph.
ISSN:2267-1242