Portfolio: Searching for relevant functions and their usages in millions of lines of code

  • Authors:
  • Collin Mcmillan;Denys Poshyvanyk;Mark Grechanik;Qing Xie;Chen Fu

  • Affiliations:
  • University of Notre Dame, South Bend, IN;The College of William and Mary, Williamsburg, VA;University of Illinois at Chicago, Chicago IL;Accenture Technology Labs;Accenture Technology Labs

  • Venue:
  • ACM Transactions on Software Engineering and Methodology (TOSEM) - Testing, debugging, and error handling, formal methods, lifecycle concerns, evolution and maintenance
  • Year:
  • 2013

Quantified Score

Hi-index 0.00

Visualization

Abstract

Different studies show that programmers are more interested in finding definitions of functions and their uses than variables, statements, or ordinary code fragments. Therefore, developers require support in finding relevant functions and determining how these functions are used. Unfortunately, existing code search engines do not provide enough of this support to developers, thus reducing the effectiveness of code reuse. We provide this support to programmers in a code search system called Portfolio that retrieves and visualizes relevant functions and their usages. We have built Portfolio using a combination of models that address surfing behavior of programmers and sharing related concepts among functions. We conducted two experiments: first, an experiment with 49 C/C++ programmers to compare Portfolio to Google Code Search and Koders using a standard methodology for evaluating information-retrieval-based engines; and second, an experiment with 19 Java programmers to compare Portfolio to Koders. The results show with strong statistical significance that users find more relevant functions with higher precision with Portfolio than with Google Code Search and Koders. We also show that by using PageRank, Portfolio is able to rank returned relevant functions more efficiently.