{"status":"ok","message-type":"work","message-version":"1.0.0","message":{"indexed":{"date-parts":[[2026,10,8]],"date-time":"2026-10-08T11:49:41Z","timestamp":1791460181125,"version":"4.3.4"},"reference-count":38,"publisher":"Association for Computing Machinery (ACM)","issue":"OOPSLA1","license":[{"start":{"date-parts":[[2023,4,6]],"date-time":"2023-04-06T00:00:00Z","timestamp":1680739200000},"content-version":"vor","delay-in-days":0,"URL":"https:\/\/creativecommons.org\/licenses\/by\/4.0\/"}],"content-domain":{"domain":["dl.acm.org"],"crossmark-restriction":true},"short-container-title":["Proc. ACM Program. Lang."],"published-print":{"date-parts":[[2023,4,6]]},"abstract":"<jats:p>The Rust language was created to provide safe low-level systems programming. There is both industrial and academic interest in the problem of (semi-)automatically translating C code to Rust in order to exploit Rust's safety guarantees. We study the effectiveness and limitations of existing techniques for automatically translating unsafe raw pointers (in Rust programs translated from C) into safe Rust references via ownership and lifetime inference. Our novel evaluation methodology enables our study to extend beyond prior studies, and to discover new information contradicting the conclusions of prior studies. We find that existing translation methods are severely limited by a lack of precision in the Rust compiler's safety checker, causing many safe pointer manipulations to be labeled as potentially unsafe. Leveraging this information, we propose methods for improving translation, based on encoding the results of a more precise analysis in a manner that is understandable to an unmodified Rust compiler. We implement one of our proposed methods, increasing the number of pointers that can be translated to safe Rust references by 75% over the baseline (from 12% to 21% of all pointers).<\/jats:p>","DOI":"10.1145\/3586046","type":"journal-article","created":{"date-parts":[[2023,4,6]],"date-time":"2023-04-06T21:06:02Z","timestamp":1680815162000},"page":"551-579","update-policy":"https:\/\/doi.org\/10.1145\/crossmark-policy","source":"Crossref","is-referenced-by-count":36,"title":["Aliasing Limits on Translating C to Safe Rust"],"prefix":"10.1145","volume":"7","author":[{"ORCID":"https:\/\/orcid.org\/0000-0001-8744-6459","authenticated-orcid":false,"given":"Mehmet","family":"Emre","sequence":"first","affiliation":[{"name":"University of San Francisco, USA"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"ORCID":"https:\/\/orcid.org\/0000-0002-2530-3329","authenticated-orcid":false,"given":"Peter","family":"Boyland","sequence":"additional","affiliation":[{"name":"University of California at Santa Barbara, USA"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"ORCID":"https:\/\/orcid.org\/0009-0007-3751-336X","authenticated-orcid":false,"given":"Aesha","family":"Parekh","sequence":"additional","affiliation":[{"name":"University of California at Santa Barbara, USA"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"ORCID":"https:\/\/orcid.org\/0009-0004-8940-5772","authenticated-orcid":false,"given":"Ryan","family":"Schroeder","sequence":"additional","affiliation":[{"name":"University of California at Santa Barbara, USA"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"ORCID":"https:\/\/orcid.org\/0000-0002-7998-3104","authenticated-orcid":false,"given":"Kyle","family":"Dewey","sequence":"additional","affiliation":[{"name":"California State University, Northridge, USA"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"ORCID":"https:\/\/orcid.org\/0009-0008-1199-6129","authenticated-orcid":false,"given":"Ben","family":"Hardekopf","sequence":"additional","affiliation":[{"name":"University of California at Santa Barbara, USA"}],"role":[{"vocabulary":"crossref","role":"author"}]}],"member":"320","published-online":{"date-parts":[[2023,4,6]]},"reference":[{"key":"e_1_2_1_1_1","doi-asserted-by":"publisher","DOI":"10.1016\/S0167-6423(99)00007-6"},{"key":"e_1_2_1_2_1","unstructured":"Lars Ole Andersen. 1994. Program Analysis and Specialization for the C Programming Language. no URL \t\t\t\t  Lars Ole Andersen. 1994. Program Analysis and Specialization for the C Programming Language. no URL"},{"key":"e_1_2_1_3_1","volume-title":"Experience Report: Developing the Servo Web Browser Engine using Rust. arXiv:1505.07383 [cs], May, arxiv:1505.07383 arXiv: 1505.07383","author":"Anderson Brian","year":"2015","unstructured":"Brian Anderson , Lars Bergstrom , David Herman , Josh Matthews , Keegan McAllister , Manish Goregaokar , Jack Moffitt , and Simon Sapin . 2015 . Experience Report: Developing the Servo Web Browser Engine using Rust. arXiv:1505.07383 [cs], May, arxiv:1505.07383 arXiv: 1505.07383 Brian Anderson, Lars Bergstrom, David Herman, Josh Matthews, Keegan McAllister, Manish Goregaokar, Jack Moffitt, and Simon Sapin. 2015. Experience Report: Developing the Servo Web Browser Engine using Rust. arXiv:1505.07383 [cs], May, arxiv:1505.07383 arXiv: 1505.07383"},{"key":"e_1_2_1_4_1","doi-asserted-by":"publisher","DOI":"10.1080\/00031305.1973.10478966"},{"key":"e_1_2_1_5_1","doi-asserted-by":"publisher","DOI":"10.1145\/582419.582440"},{"key":"e_1_2_1_6_1","doi-asserted-by":"publisher","DOI":"10.1145\/781131.781168"},{"key":"e_1_2_1_7_1","unstructured":"David Bryant. 2016. A Quantum Leap for the Web. https:\/\/medium.com\/mozilla-tech\/a-quantum-leap-for-the-web-a3b7174b3c12 \t\t\t\t  David Bryant. 2016. A Quantum Leap for the Web. https:\/\/medium.com\/mozilla-tech\/a-quantum-leap-for-the-web-a3b7174b3c12"},{"key":"e_1_2_1_8_1","unstructured":"Jonathan Corbet. 2021. Rust support hits linux-next. https:\/\/lwn.net\/Articles\/849849\/ \t\t\t\t  Jonathan Corbet. 2021. Rust support hits linux-next. https:\/\/lwn.net\/Articles\/849849\/"},{"key":"e_1_2_1_9_1","unstructured":"Nelson Elhage. 2020. Supporting Linux kernel development in Rust. https:\/\/lwn.net\/Articles\/829858\/ \t\t\t\t  Nelson Elhage. 2020. Supporting Linux kernel development in Rust. https:\/\/lwn.net\/Articles\/829858\/"},{"key":"e_1_2_1_10_1","doi-asserted-by":"publisher","DOI":"10.1109\/SecDev.2018.00015"},{"key":"e_1_2_1_11_1","doi-asserted-by":"publisher","DOI":"10.5281\/zenodo.7714175"},{"key":"e_1_2_1_12_1","doi-asserted-by":"publisher","DOI":"10.1145\/3485498"},{"key":"e_1_2_1_13_1","doi-asserted-by":"publisher","DOI":"10.1145\/349299.349332"},{"key":"e_1_2_1_14_1","doi-asserted-by":"publisher","DOI":"10.1145\/512529.512531"},{"key":"e_1_2_1_15_1","doi-asserted-by":"publisher","DOI":"10.1007\/3-540-44898-5_12"},{"key":"e_1_2_1_16_1","doi-asserted-by":"publisher","DOI":"10.1145\/378795.378855"},{"key":"e_1_2_1_17_1","unstructured":"Immunant inc.. 2020. immunant\/c2rust. https:\/\/github.com\/immunant\/c2rust original-date: 2018-04-20T00:05:50Z \t\t\t\t  Immunant inc.. 2020. immunant\/c2rust. https:\/\/github.com\/immunant\/c2rust original-date: 2018-04-20T00:05:50Z"},{"key":"e_1_2_1_18_1","volume-title":"USENIX Annual Technical Conference, General Track. 275\u2013288","author":"Jim Trevor","year":"2002","unstructured":"Trevor Jim , J Gregory Morrisett , Dan Grossman , Michael W Hicks , James Cheney , and Yanling Wang . 2002 . Cyclone: a safe dialect of C .. In USENIX Annual Technical Conference, General Track. 275\u2013288 . Trevor Jim, J Gregory Morrisett, Dan Grossman, Michael W Hicks, James Cheney, and Yanling Wang. 2002. Cyclone: a safe dialect of C.. In USENIX Annual Technical Conference, General Track. 275\u2013288."},{"key":"e_1_2_1_19_1","doi-asserted-by":"publisher","DOI":"10.1145\/2491956.2462191"},{"key":"e_1_2_1_20_1","unstructured":"Kornel Lesinski. 2018. Citrus \/ Citrus. https:\/\/gitlab.com\/citrus-rs\/citrus \t\t\t\t  Kornel Lesinski. 2018. Citrus \/ Citrus. https:\/\/gitlab.com\/citrus-rs\/citrus"},{"key":"e_1_2_1_21_1","doi-asserted-by":"publisher","DOI":"10.1145\/2818302.2818306"},{"key":"e_1_2_1_22_1","doi-asserted-by":"publisher","DOI":"10.1007\/11688839_5"},{"key":"e_1_2_1_23_1","doi-asserted-by":"publisher","DOI":"10.1145\/2926697.2926707"},{"key":"e_1_2_1_24_1","doi-asserted-by":"publisher","DOI":"10.1109\/ICSE-Companion55297.2022.9793767"},{"key":"e_1_2_1_25_1","doi-asserted-by":"publisher","DOI":"10.1145\/3527322"},{"key":"e_1_2_1_26_1","doi-asserted-by":"publisher","DOI":"10.1145\/1065887.1065892"},{"key":"e_1_2_1_27_1","doi-asserted-by":"publisher","DOI":"10.1145\/1290520.1290524"},{"key":"e_1_2_1_28_1","doi-asserted-by":"publisher","DOI":"10.1007\/BFb0032731"},{"key":"e_1_2_1_29_1","doi-asserted-by":"publisher","DOI":"10.1145\/263699.263703"},{"key":"e_1_2_1_30_1","unstructured":"Jamey Sharp. 2020. jameysharp\/corrode. https:\/\/github.com\/jameysharp\/corrode original-date: 2016-05-05T21:12:52Z \t\t\t\t  Jamey Sharp. 2020. jameysharp\/corrode. https:\/\/github.com\/jameysharp\/corrode original-date: 2016-05-05T21:12:52Z"},{"key":"e_1_2_1_31_1","doi-asserted-by":"publisher","DOI":"10.1145\/2594291.2594320"},{"key":"e_1_2_1_32_1","doi-asserted-by":"publisher","DOI":"10.1145\/237721.237727"},{"key":"e_1_2_1_33_1","unstructured":"Jeff Vander Stoep and Stephen Hines. 2021. Rust in the Android platform. https:\/\/security.googleblog.com\/2021\/04\/rust-in-android-platform.html \t\t\t\t  Jeff Vander Stoep and Stephen Hines. 2021. Rust in the Android platform. https:\/\/security.googleblog.com\/2021\/04\/rust-in-android-platform.html"},{"key":"e_1_2_1_34_1","doi-asserted-by":"publisher","DOI":"10.1145\/2892208.2892235"},{"key":"e_1_2_1_35_1","unstructured":"The Rust Project. 2021. The Rust Reference. https:\/\/doc.rust-lang.org\/stable\/reference\/ \t\t\t\t  The Rust Project. 2021. The Rust Reference. https:\/\/doc.rust-lang.org\/stable\/reference\/"},{"key":"e_1_2_1_36_1","unstructured":"The Rust Project. 2022. lazy-static.rs. https:\/\/github.com\/rust-lang-nursery\/lazy-static.rs original-date: 2014-06-24T08:25:15Z \t\t\t\t  The Rust Project. 2022. lazy-static.rs. https:\/\/github.com\/rust-lang-nursery\/lazy-static.rs original-date: 2014-06-24T08:25:15Z"},{"key":"e_1_2_1_37_1","unstructured":"The Rust Project. 2022. standard lazy types - Rust RFC #2788. https:\/\/github.com\/rust-lang\/rfcs\/pull\/2788 \t\t\t\t  The Rust Project. 2022. standard lazy types - Rust RFC #2788. https:\/\/github.com\/rust-lang\/rfcs\/pull\/2788"},{"key":"e_1_2_1_38_1","volume-title":"Oxide: The Essence of Rust. 27 pages. https:\/\/doi.org\/10.48550\/arXiv.1903.00982","author":"Weiss Aaron","year":"2020","unstructured":"Aaron Weiss , Daniel Patterson , Nicholas D Matsakis , and Amal Ahmed . 2020 . Oxide: The Essence of Rust. 27 pages. https:\/\/doi.org\/10.48550\/arXiv.1903.00982 10.48550\/arXiv.1903.00982 Aaron Weiss, Daniel Patterson, Nicholas D Matsakis, and Amal Ahmed. 2020. Oxide: The Essence of Rust. 27 pages. https:\/\/doi.org\/10.48550\/arXiv.1903.00982"}],"container-title":["Proceedings of the ACM on Programming Languages"],"original-title":[],"language":"en","link":[{"URL":"https:\/\/dl.acm.org\/doi\/10.1145\/3586046","content-type":"unspecified","content-version":"vor","intended-application":"text-mining"},{"URL":"https:\/\/dl.acm.org\/doi\/pdf\/10.1145\/3586046","content-type":"unspecified","content-version":"vor","intended-application":"similarity-checking"}],"deposited":{"date-parts":[[2025,6,17]],"date-time":"2025-06-17T16:46:11Z","timestamp":1750178771000},"score":1,"resource":{"primary":{"URL":"https:\/\/dl.acm.org\/doi\/10.1145\/3586046"}},"subtitle":[],"short-title":[],"issued":{"date-parts":[[2023,4,6]]},"references-count":38,"journal-issue":{"issue":"OOPSLA1","published-print":{"date-parts":[[2023,4,6]]}},"alternative-id":["10.1145\/3586046"],"URL":"https:\/\/doi.org\/10.1145\/3586046","relation":{},"ISSN":["2475-1421"],"issn-type":[{"value":"2475-1421","type":"electronic"}],"subject":[],"published":{"date-parts":[[2023,4,6]]},"assertion":[{"value":"2023-04-06","order":2,"name":"published","label":"Published","group":{"name":"publication_history","label":"Publication History"}}]}}