Hoang-Hai Dang

Hoang-Hai Dang

Auto-generated profile, based on publicly available information

Hoang-Hai Dang

MPI-SWS, Germany

Research Focus & Metrics

Academic Career Length

8Years (2019-Present)

(Calculated once Scilit publication data is synced: current year − year of first publication + 1)

Representative Publications

View All Publications
14 July 2020
Verified
Book Chapter
Open access
PDF file
ARAzalea Raad
Azalea Raad
JBJosh Berdine
Josh Berdine
HDHoang-Hai Dang
Hoang-Hai Dang
DDDerek Dreyer
Derek Dreyer
POPeter O’hearn
Peter O’hearn
JVJules Villard
Jules Villard
There has been a large body of work on local reasoning for proving the absence of bugs, but none for proving their presence. We present a new formal framework for local reasoning about the presence of bugs, building on two complementary foundations: 1) separation logic and 2) incorrectness logic. We explore the theory of this new incorrectness separation logic (ISL), and use it to derive a begin-anywhere, intra-procedural symbolic execution analysis that has no false positives by construction. In so doing, we take a step towards transferring modular, scalable techniques from the world of program verification to bug catching.

20 December 2019 in Proceedings of the ACM on Programming Languages
Verified
Journal Article
Open access
PDF file
RJRalf Jung
Ralf Jung
HDHoang-Hai Dang
Hoang-Hai Dang
JKJeehoon Kang
Jeehoon Kang
DDDerek Dreyer
Derek Dreyer
Type systems are useful not just for the safety guarantees they provide, but also for helping compilers generate more efficient code by simplifying important program analyses. In Rust, the type system imposes a strict discipline on pointer aliasing, and it is an express goal of the Rust compiler developers to make use of that alias information for the purpose of program optimizations that reorder memory accesses. The problem is that Rust also supports unsafe code, and programmers can write unsafe code that bypasses the usual compiler checks to violate the aliasing discipline. To strike a balance between optimizations and unsafe code, the language needs to provide a set of rules such that unsafe code authors can be sure, if they are following these rules, that the compiler will preserve the semantics of their code despite all the optimizations it is doing. In this work, we propose Stacked Borrows , an operational semantics for memory accesses in Rust. Stacked Borrows defines an aliasing discipline and declares programs violating it to have undefined behavior , meaning the compiler does not have to consider such programs when performing optimizations. We give formal proofs (mechanized in Coq) showing that this rules out enough programs to enable optimizations that reorder memory accesses around unknown code and function calls, based solely on intraprocedural reasoning. We also implemented this operational model in an interpreter for Rust and ran large parts of the Rust standard library test suite in the interpreter to validate that the model permits enough real-world unsafe Rust code.

20 December 2019 in Proceedings of the ACM on Programming Languages
Verified
Journal Article
Open access
PDF file
HDHoang-Hai Dang
Hoang-Hai Dang
JJJacques-Henri Jourdan
Jacques-Henri Jourdan
JKJan-Oliver Kaiser
Jan-Oliver Kaiser
DDDerek Dreyer
Derek Dreyer
The Rust programming language supports safe systems programming by means of a strong ownership-tracking type system. In their prior work on RustBelt, Jung et al. began the task of setting Rust’s safety claims on a more rigorous formal foundation. Specifically, they used Iris, a Coq-based separation logic framework, to build a machine-checked proof of semantic soundness for a λ-calculus model of Rust, as well as for a number of widely-used Rust libraries that internally employ unsafe language features. However, they also made the significant simplifying assumption that the language is sequentially consistent. In this paper, we adapt RustBelt to account for the relaxed-memory operations that concurrent Rust libraries actually use, in the process uncovering a data race in the Arc library. We focus on the most interesting technical problem: how to reason about resource reclamation under relaxed memory , using a logical construction we call synchronized ghost state .

12 January 2022 in Proceedings of the ACM on Programming Languages
Verified
Journal Article
Open access
LGLennard Gäher
Lennard Gäher
MSMichael Sammler
Michael Sammler
SSSimon Spies
Simon Spies
RJRalf Jung
Ralf Jung
HDHoang-Hai Dang
Hoang-Hai Dang
DDDerek Dreyer
Derek Dreyer
Today’s compilers employ a variety of non-trivial optimizations to achieve good performance. One key trick compilers use to justify transformations of concurrent programs is to assume that the source program has no data races : if it does, they cause the program to have undefined behavior (UB) and give the compiler free rein. However, verifying correctness of optimizations that exploit this assumption is a non-trivial problem. In particular, prior work either has not proven that such optimizations preserve program termination (particularly non-obvious when considering optimizations that move instructions out of loop bodies), or has treated all synchronization operations as external functions (losing the ability to reorder instructions around them). In this work we present Simuliris , the first simulation technique to establish termination preservation (under a fair scheduler) for a range of concurrent program transformations that exploit UB in the source language. Simuliris is based on the idea of using ownership to reason modularly about the assumptions the compiler makes about programs with well-defined behavior. This brings the benefits of concurrent separation logics to the space of verifying program transformations: we can combine powerful reasoning techniques such as framing and coinduction to perform thread-local proofs of non-trivial concurrent program optimizations. Simuliris is built on a (non-step-indexed) variant of the Coq-based Iris framework, and is thus not tied to a particular language. In addition to demonstrating the effectiveness of Simuliris on standard compiler optimizations involving data race UB, we also instantiate it with Jung et al.’s Stacked Borrows semantics for Rust and generalize their proofs of interesting type-based aliasing optimizations to account for concurrency.

14 May 2025
Verified
Conference Paper
Open access
GMGregory Malecha
Gregory Malecha
HDHoang-Hai Dang
Hoang-Hai Dang
PGPaolo G. Giarrusso
Paolo G. Giarrusso
SHSimon Hudon
Simon Hudon
JKJan-Oliver Kaiser
Jan-Oliver Kaiser
DSDavid Swasey
David Swasey