Learning likely invariants to explain why a program fails

Debugging is difficult. Recent studies show that automatic bug localization techniques have limited usefulness. One of the reasons is that programmers typically have to understand why the program fails before fixing it. In this work, we aim to help programmers understand a bug by automatically gener...

Full description

Saved in:
Bibliographic Details
Main Authors: PHAM, Long H., SUN, Jun, THI, Lyly Tran, WANG, Jingyi, PENG, Xin
Format: text
Language:English
Published: Institutional Knowledge at Singapore Management University 2017
Subjects:
Online Access:https://ink.library.smu.edu.sg/sis_research/4705
https://ink.library.smu.edu.sg/context/sis_research/article/5708/viewcontent/Learning_variants_program_fails_iceccs2017_pv.pdf
Tags: Add Tag
No Tags, Be the first to tag this record!
Institution: Singapore Management University
Language: English
id sg-smu-ink.sis_research-5708
record_format dspace
spelling sg-smu-ink.sis_research-57082020-01-09T07:09:18Z Learning likely invariants to explain why a program fails PHAM, Long H. SUN, Jun THI, Lyly Tran WANG, Jingyi PENG, Xin Debugging is difficult. Recent studies show that automatic bug localization techniques have limited usefulness. One of the reasons is that programmers typically have to understand why the program fails before fixing it. In this work, we aim to help programmers understand a bug by automatically generating likely invariants which are violated in the failed tests. Given a program with an initial assertion and at least one test case failing the assertion, we first generate random test cases, identify potential bug locations through bug localization, and then generate program state mutation based on active learning techniques to identify a predicate 'explaining' the cause of the bug. The predicate is a classifier for the passed test cases and failed test cases. Our main contribution is the application of invariant learning for bug explanation, as well as a novel approach to overcome the problem of lack of test cases in practice. We apply our method to real-world bugs and show the generated invariants are often correlated to the actual bug fixes. 2017-11-08T08:00:00Z text application/pdf https://ink.library.smu.edu.sg/sis_research/4705 info:doi/10.1109/ICECCS.2017.12 https://ink.library.smu.edu.sg/context/sis_research/article/5708/viewcontent/Learning_variants_program_fails_iceccs2017_pv.pdf http://creativecommons.org/licenses/by-nc-nd/4.0/ Research Collection School Of Computing and Information Systems eng Institutional Knowledge at Singapore Management University Active learning Debugging Invariant Software Engineering
institution Singapore Management University
building SMU Libraries
continent Asia
country Singapore
Singapore
content_provider SMU Libraries
collection InK@SMU
language English
topic Active learning
Debugging
Invariant
Software Engineering
spellingShingle Active learning
Debugging
Invariant
Software Engineering
PHAM, Long H.
SUN, Jun
THI, Lyly Tran
WANG, Jingyi
PENG, Xin
Learning likely invariants to explain why a program fails
description Debugging is difficult. Recent studies show that automatic bug localization techniques have limited usefulness. One of the reasons is that programmers typically have to understand why the program fails before fixing it. In this work, we aim to help programmers understand a bug by automatically generating likely invariants which are violated in the failed tests. Given a program with an initial assertion and at least one test case failing the assertion, we first generate random test cases, identify potential bug locations through bug localization, and then generate program state mutation based on active learning techniques to identify a predicate 'explaining' the cause of the bug. The predicate is a classifier for the passed test cases and failed test cases. Our main contribution is the application of invariant learning for bug explanation, as well as a novel approach to overcome the problem of lack of test cases in practice. We apply our method to real-world bugs and show the generated invariants are often correlated to the actual bug fixes.
format text
author PHAM, Long H.
SUN, Jun
THI, Lyly Tran
WANG, Jingyi
PENG, Xin
author_facet PHAM, Long H.
SUN, Jun
THI, Lyly Tran
WANG, Jingyi
PENG, Xin
author_sort PHAM, Long H.
title Learning likely invariants to explain why a program fails
title_short Learning likely invariants to explain why a program fails
title_full Learning likely invariants to explain why a program fails
title_fullStr Learning likely invariants to explain why a program fails
title_full_unstemmed Learning likely invariants to explain why a program fails
title_sort learning likely invariants to explain why a program fails
publisher Institutional Knowledge at Singapore Management University
publishDate 2017
url https://ink.library.smu.edu.sg/sis_research/4705
https://ink.library.smu.edu.sg/context/sis_research/article/5708/viewcontent/Learning_variants_program_fails_iceccs2017_pv.pdf
_version_ 1770574966939451392