Inferring Program Transformations From Singular Examples via Big Code

Published in The 34th IEEE/ACM International Conference on Automated Software Engineering, November 11-15, 2019, San Diego, California, USA. pages 255-266., 2019

Jiajun Jiang, Luyao Ren, Yingfei Xiong, Lingming Zhang,

Brief Intro.

In this paper, we address the challenge of inferring a program transformation from a single example. Our core insight is that “big code” can provide effective guide for the generalization of a concrete change into a program transformation, i.e., code elements appear in many files are general and should not be abstracted away. We first propose a framework for transformation inference, where programs are represented as hypergraphs to enable fine-grained generalization of transformations. We then design a transformation inference approach, GENPAT, that infers a transformation based on code context and statistics from a big code corpus.

[Paper] [Tool] [Media]