Thread-Safe Dynamic Binary Translation using Transactional Memory

被引:0
|
作者
Chung, JaeWoong [1 ]
Dalton, Michael [1 ]
Kannan, Hari [1 ]
Kozyrakis, Christos [1 ]
机构
[1] Stanford Univ, Comp Syst Lab, Stanford, CA 94305 USA
关键词
D O I
暂无
中图分类号
TP3 [计算技术、计算机技术];
学科分类号
0812 ;
摘要
Dynamic binary translation (DBT) is a runtime instrumentation technique commonly used to support profiling, optimization, secure execution, and bug detection tools for application binaries. However DBT frameworks may incorrectly handle multithreaded programs due to races involving updates to the application data and the corresponding metadata maintained by the DBT Existing DBT frameworks handle this issue by serializing threads, disallowing multithreaded programs, or requiring explicit use of locks. This paper presents a practical solution for correct execution of multithreaded programs within DBT frameworks. To eliminate races involving metadata, we propose the use of transactional memory (TM). The DBT uses memory transactions to encapsulate the data and metadata accesses in a trace, within one atomic block This approach guarantees correct execution of concurrent threads of the translated program, as TM mechanisms detect and correct races. To demonstrate this approach, we implemented a DBT-based tool for secure execution of x86 binaries using dynamic information-flow tracking. This is the first such framework that correctly handles multithreaded binaries without serialization. We show that the use of software transactions in the DBT leads to a runtime overhead of 40%. We also show that software optimizations in the DBT and hardware support for transactions can reduce the runtime overhead to 6%.
引用
收藏
页码:256 / 266
页数:11
相关论文
共 50 条
  • [1] Cuckoo: a language for implementing memory-safe and thread-safe system
    West, R
    Wong, GT
    PLC '05: PROCEEDINGS OF THE 2005 INTERNATIONAL CONFERENCE ON PROGRAMMING LANGUAGES AND COMPILERS, 2005, : 94 - 100
  • [2] Fyr: a memory-safe and thread-safe systems programming language
    Weis, Torben
    Waltereit, Marian
    Uphoff, Maximilian
    SAC '19: PROCEEDINGS OF THE 34TH ACM/SIGAPP SYMPOSIUM ON APPLIED COMPUTING, 2019, : 1574 - 1577
  • [3] Thread-safe access to collections
    Kleber, Jeff
    C/C++ Users Journal, 2000, 18 (05): : 38 - 39
  • [4] Thread-Safe Reactive Programming
    Drechsler, Joscha
    Mogk, Ragnar
    Salvaneschi, Guido
    Mezini, Mira
    PROCEEDINGS OF THE ACM ON PROGRAMMING LANGUAGES-PACMPL, 2018, 2
  • [5] Thread-Safe Reactive Programming
    Drechsler, Joscha
    Mogk, Ragnar
    Salvaneschi, Guido
    Mezini, Mira
    PROCEEDINGS OF THE ACM ON PROGRAMMING LANGUAGES-PACMPL, 2018, 2
  • [6] Enhancing Transactional Memory Execution via Dynamic Binary Translation
    Hong, Ding-Yong
    Lin, Shih-Kai
    Fu, Sheng-Yu
    Wu, Jan-Jan
    Hsu, Wei-Chung
    APPLIED COMPUTING REVIEW, 2019, 19 (01): : 48 - 58
  • [7] (Quasi-) thread-safe PVM and (quasi-) thread-safe MPI without active polling
    Plachetka, T
    RECENT ADVANCES IN PARALLEL VITUAL MACHINE AND MESSAGE PASSING INTERFACE, PROCEEDINGS, 2002, 2474 : 296 - 305
  • [8] Enhancing Call-Level Interfaces with Thread-Safe Local Memory Structures
    Pereira, Oscar Mortagua
    Aguiar, Rui L.
    INTERNATIONAL JOURNAL OF SOFTWARE ENGINEERING AND KNOWLEDGE ENGINEERING, 2017, 27 (9-10) : 1549 - 1565
  • [9] Memory-efficient and thread-safe quasi-destructive graph unification
    van Lohuizen, MP
    38TH ANNUAL MEETING OF THE ASSOCIATION FOR COMPUTATIONAL LINGUISTICS, PROCEEDINGS OF THE CONFERENCE, 2000, : 352 - 359
  • [10] Issues in developing a thread-safe MPI implementation
    Gropp, William
    Thakur, Rajeev
    RECENT ADVANCES IN PARALLEL VIRTUAL MACHINE AND MESSAGE PASSING INTERFACE, 2006, 4192 : 12 - 21