CAT: Context Aware Tracing for Rust Asynchronous Programs

Tsung Yen Wang, Shao Hua Wang, Chia Heng Tu, Wen Yew Liang

Research output: Chapter in Book/Report/Conference proceedingConference contribution

Abstract

Modern programming languages, such as Rust, have adopted the coroutine concept to better utilize computation resources and to improve program execution efficiency by allowing the overlap of the execution for asynchronous tasks. These programming languages often use the concept of userland thread library to dispatch the asynchronous tasks defined by the programmers. Nevertheless, it is often the case that the task scheduling on a user-space library is non-preemptive and would lead to unbounded execution time of a task.In this work, we aim to develop a tracing methodology to capture unbounded execution time of asynchronous tasks in Rust programs. Based on the analyses of the Rust standard library, we identify several execution contexts of asynchronous computation in Rust, and develop a portable context aware tracing methodology that is able to trace the execution time of nested asynchronous computation work across different Rust runtimes. We develop a framework, called CAT, to collect and visualize the asynchronous runtime activities. The results show that CAT can help pinpoint the asynchronous computation exhibiting prolonged execution time. We believe that CAT is a complement of existing tools to improve the execution efficiency of asynchronous operations in Rust.

Original languageEnglish
Title of host publicationProceedings of the 38th ACM/SIGAPP Symposium on Applied Computing, SAC 2023
PublisherAssociation for Computing Machinery
Pages483-492
Number of pages10
ISBN (Electronic)9781450395175
DOIs
Publication statusPublished - 2023 Mar 27
Event38th Annual ACM Symposium on Applied Computing, SAC 2023 - Tallinn, Estonia
Duration: 2023 Mar 272023 Mar 31

Publication series

NameProceedings of the ACM Symposium on Applied Computing

Conference

Conference38th Annual ACM Symposium on Applied Computing, SAC 2023
Country/TerritoryEstonia
CityTallinn
Period23-03-2723-03-31

All Science Journal Classification (ASJC) codes

  • Software

Fingerprint

Dive into the research topics of 'CAT: Context Aware Tracing for Rust Asynchronous Programs'. Together they form a unique fingerprint.

Cite this