Learning a Static Bug Finder from Data

Yu Wang, Fengjuan Gao, Linzhang Wang, Ke Wang
7/12/2019
cs.SEcs.LG
gnn

No confident code implementation found for this paper.

Abstract

We present an alternative approach to creating static bug finders. Instead of relying on human expertise, we utilize deep neural networks to train static analyzers directly from data.

Show full abstract

In particular, we frame the problem of bug finding as a classification task and train a classifier to differentiate the buggy from non-buggy programs using Graph Neural Network (GNN). Crucially, we propose a novel interval-based propagation mechanism that leads to a significantly more efficient, accurate and scalable generalization of GNN. We have realized our approach into a framework, NeurSA, and extensively evaluated it. In a cross-project prediction task, three neural bug detectors we instantiate from NeurSA are effective in catching null pointer dereference, array index out of bound and class cast bugs in unseen code. We compare NeurSA against several static analyzers (e.g. Facebook Infer and Pinpoint) on a set of null pointer dereference bugs. Results show that NeurSA is more precise in catching the real bugs and suppressing the spurious warnings. We also apply NeurSA to several popular Java projects on GitHub and discover 50 new bugs, among which 9 have been fixed, and 3 have been confirmed.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{wang2019learning,
  title  = {Learning a Static Bug Finder from Data},
  author = {Yu Wang and Fengjuan Gao and Linzhang Wang and Ke Wang},
  year   = {2019},
  eprint = {1907.05579},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/1907.05579}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/1907.05579.svg)](https://codeofpaper.com/paper/1907.05579)

Discussion