Semantic code browsing

被引:5
|
作者
Garcia-Contreras, Isabel [1 ]
Morales, Jose F. [1 ]
Hermenegildo, Manuel V. [1 ,2 ]
机构
[1] IMDEA Software Inst, Madrid, Spain
[2] Tech Univ Madrid UPM, Sch Comp Sci, Madrid, Spain
关键词
Semantic Code Search; Abstract Interpretation; Assertions; CONSTRAINT LOGIC PROGRAMS; ABSTRACT INTERPRETATION; SYSTEM; CIAO;
D O I
10.1017/S1471068416000417
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
Programmers currently enjoy access to a very high number of code repositories and libraries of ever increasing size. The ensuing potential for reuse is however hampered by the fact that searching within all this code becomes an increasingly difficult task. Most code search engines are based on syntactic techniques such as signature matching or keyword extraction. However, these techniques are inaccurate (because they basically rely on documentation) and at the same time do not offer very expressive code query languages. We propose a novel approach that focuses on querying for semantic characteristics of code obtained automatically from the code itself. Program units are pre-processed using static analysis techniques, based on abstract interpretation, obtaining safe semantic approximations. A novel, assertion-based code query language is used to express desired semantic characteristics of the code as partial specifications. Relevant code is found by comparing such partial specifications with the inferred semantics for program elements. Our approach is fully automatic and does not rely on user annotations or documentation. It is more powerful and flexible than signature matching because it is parametric on the abstract domain and properties, and does not require type definitions. Also, it reasons with relations between properties, such as implication and abstraction, rather than just equality. It is also more resilient to syntactic code differences. We describe the approach and report on a prototype implementation within the Ciao system.
引用
收藏
页码:721 / 737
页数:17
相关论文
共 50 条
  • [1] Semantic browsing
    Faaborg, A
    Lagoze, C
    RESEARCH AND ADVANCED TECHNOLOGY FOR DIGITAL LIBRARIES, 2003, 2769 : 70 - 81
  • [2] Semantic web browsing
    Papadakis, Ioannis
    Stefanidakis, Michalis
    WEBIST 2007: PROCEEDINGS OF THE THIRD INTERNATIONAL CONFERENCE ON WEB INFORMATION SYSTEMS AND TECHNOLOGIES, VOL WIA: WEB INTERFACES AND APPLICATIONS, 2007, : 400 - +
  • [3] Semantic browsing with PowerMagpie
    Gridinoc, Laurian
    Sabou, Marta
    d'Aquin, Mathieu
    Dzbor, Martin
    Motta, Enrico
    SEMANTIC WEB: RESEARCH AND APPLICATIONS, PROCEEDINGS, 2008, 5021 : 802 - 806
  • [4] Browsing the Semantic Web
    Lassila, Ora
    SEVENTEENTH INTERNATIONAL CONFERENCE ON DATABASE AND EXPERT SYSTEMS APPLICATIONS, PROCEEDINGS, 2006, : 365 - +
  • [5] Semantic browsing of digital collections
    Collins, T
    Mulholland, P
    Zdrahal, Z
    SEMANTIC WEB - ISWC 2005, PROCEEDINGS, 2005, 3729 : 127 - 141
  • [6] Browsing Semantic Data in Slovakia
    Mojzis, Jan
    Laclavik, Michal
    BRAIN-BROAD RESEARCH IN ARTIFICIAL INTELLIGENCE AND NEUROSCIENCE, 2015, 6 (3-4): : 47 - 59
  • [7] Mapping Evaluation for Semantic Browsing
    Osinska, Veslava
    Jozwik, Adam
    Osinski, Grzegorz
    PROCEEDINGS OF THE 2015 FEDERATED CONFERENCE ON COMPUTER SCIENCE AND INFORMATION SYSTEMS, 2015, 5 : 329 - 335
  • [8] SWebB: Semantic Web Browsing
    Giunchiglia, F
    SEMANTIC WEB: RESEARCH AND APPLICATIONS, PROCEEDINGS, 2005, 3532 : 725 - 725
  • [9] An interface for semantic browsing of an images database
    Amato, A
    Di Lecce, V
    Piuri, V
    2004 IEEE SYMPOSIUM ON VIRTUAL ENVIRONMENTS, HUMAN-COMPUTRE INTERFACES AND MEASUREMENT SYSTEMS, 2004, : 67 - 71
  • [10] Semantic browsing and retrieval in image libraries
    Kutics, A
    Nakagawa, A
    IMAGE ANALYSIS AND RECOGNITION, PT 1, PROCEEDINGS, 2004, 3211 : 737 - 744