Context Parsing (Not Only) of the Object-File-Format Description Language

Jakub Kroustek1 and Dusan Kolar1

  1. Faculty of Information Technology, IT4Innovations Centre of Excellence
    Brno University of Technology, Bozetechova 1/2, 612 66 Brno, Czech Republic
    {ikroustek,kolar}@fit.vutbr.cz

Abstract

The very first step of each tool such as linker, disassembler, or debugger is parsing of an input executable or object file. These files are stored in one of the existing object file formats (OFF). Retargetable tools are not limited to any particular target platform and they have to deal with handling of several OFFs. Handling of these formats is similar to parsing of computer languages — both of them have a predefined structure and a list of allowed constructions. However, OFF constructions are heavily mutually interconnected and they create context-sensitive units. In present, there is no generic system, which can be used for OFF description and its effective parsing. In this paper, we propose a formal language that can be used for OFF description. Furthermore, we present a design of a context parser of this language that is based on the formal models. The major advance of this solution is an ability to describe context-sensitive properties on the level of the language itself. This concept is planned to be used in the existing retargetable decompiler developed within the Lissom project. In this project, the language and its parser will be used for an object file parsing and its automatic conversion into the internal uniform file format. It is important to say that the concept of this parser can be utilized within other programming languages.

Key words

object file format, context parsing, scattered context grammar, priority function, attributed grammar, decompilation, Lissom, ELF

Digital Object Identifier (DOI)

https://doi.org/10.2298/CSIS130120071K

Publication information

Volume 10, Issue 4 (October 2013)
Special Issue on Advances in Model Driven Engineering, Languages and Agents
Year of Publication: 2013
ISSN: 1820-0214 (Print) 2406-1018 (Online)
Publisher: ComSIS Consortium

Full text

DownloadAvailable in PDF
Portable Document Format

How to cite

Kroustek, J., Kolar, D.: Context Parsing (Not Only) of the Object-File-Format Description Language. Computer Science and Information Systems, Vol. 10, No. 4, 1673-1701. (2013)