SpecTacles: Supporting Control Flow Comprehension of Software Developers in TLA+
Formal specifications like TLA+ support software developers in formulating and verifying properties of their systems as state machines. Writing specifications helps software developers incrementally develop an understanding of their systems’ domains. However, according to our formative study, while reading such specifications authored by others, software developers tend to struggle to build comprehension. To overcome the limitations of text, participants visualized specifications and manually constructed concrete example sequences of actions. We propose an approach that visualizes state-machine-based specifications to better support software developers in reading, exploring, and understanding them. Our tool, SpecTacles, generates and presents interactive visualizations derived from a specification’s state space next to its original source text. Users can formulate example sequences of actions, which are synchronized between all visualizations. To explore how and why such interactive visualizations help, we conducted a user study ($\mathrm{n}=12$) with software developers who had no prior training in formal specifications, and explored how they use our tool in a set of comprehension tasks. Participants used the source text to obtain local and definitive information, for example, to validate an assumption, but they referred to the visualizations to gain an overview and to compensate for the lack of control flow information in the source text. Given the strengths of both visualizations and source text, participants found SpecTacles useful for their comprehension and indicated that they would like to use it in other software engineering contexts.
Authors
- Patrick Rein (ORCID: https://orcid.org/0000-0001-9454-8381)
- Tom Beckmann (ORCID: https://orcid.org/0000-0003-0015-1717)
- Robert Hirschfeld (ORCID: https://orcid.org/0000-0002-4249-6003)
- Daniel Stachnik
Institutions
- Hasso Plattner Institute (DE)
- University of Potsdam (DE)
Publication Details
- Published
- 2024-09-02
- DOI
- https://doi.org/10.1109/vl/hcc60511.2024.00028
- Primary Topic
- Embedded Systems Design Techniques
- Type
- article
- Field-Weighted Citation Impact
- 0.00
Funders
- Deutsche Forschungsgemeinschaft