arrow
Return

Type Deduction Analysis: Reconstructing Transparent Pointer Types in LLVM-IR

delete2026-01-01
delete0
PRE
AI
N
Niccolò Nicolosi *
G
Gabriele Magnani
E
Emilio Corigliano
D
Davide Baroffio
F
Federico Reghenzani
G
Giovanni Agosta
DOI:10.1145/3771775.3786268delete
deleteOriginal
deleteOriginal request for help
deleteShare
deleteSave
Abstract

Abstract

En 中文
With version 17, LLVM finalized the transition to opaque pointer types, eliminating explicit pointee-type information from the Intermediate Representation (IR). Thus, starting from LLVM 17, each pointer type is represented in IR by the unique type ptr. Despite eliminating redundant pointer bitcasts and consequently reducing IR size and compile time, this change disrupts analyses that have reason to rely on pointee-type information, forcing existing compiler projects to depend on outdated LLVM versions. This information can in fact be insightful in fields like approximate computing, where the compiler can apply non-conservative optimizations, or in passes that require it to make analyses and transformations that do not impact the correctness of the program. To address this problem, we present a new Type Deduction Analysis pass that reconstructs transparent pointer types directly from opaque-pointer IR. Moreover, we illustrate two different case-studies on existing LLVM projects, namely TAFFO and ASPIS, that demonstrate the need for pointee-type information in LLVM compilers.
Keywords:
Compilers
LLVM
Data-flow Analysis
Types

Journal

P
PROCEEDINGS OF THE 35TH ACM SIGPLAN INTERNATIONAL CONFERENCE ON COMPILER CONSTRUCTION, CC 2026
IF:
0
Papers:
18
Citations:
0

Organization

P
Polytechnic University of Milan
Scholars:
2.0W
Papers: 1.8W
Citations: 24
Cited Papers

Cited Papers

err
IF0
err
err0
PREAI
err
errShare
errSave
TAFFO: The compiler-based precision tuner
err2022-12-01
err0
errOAAI
errDaniele Cattaneo; Michele Chiari; Giovanni Agosta; Stefano Cherubin
errShare
errSave
AxBench: A Multiplatform Benchmark Suite for Approximate Computing
err2017-04-01
err0
errOAAI
errAmir Yazdanbakhsh; Divya Mahajan; Hadi Esmaeilzadeh; Pejman Lotfi-Kamran
errShare
errSave
Principles of Program Analysis
err
IF0
err1999-01-01
err0
PREAI
errFlemming Nielson; Hanne Riis Nielson; Chris Hankin
errShare
errSave
FixM: Code generation of fixed point mathematical functions
err2021-03-01
err4
PREAI
errCattaneo, Daniele; Chiari, Michele; Magnani, Gabriele; Fossati, Nicola; Cherubin, Stefano; Agosta, Giovanni
errShare
errSave
Architecture-aware Precision Tuning with Multiple Number Representation Systems
err2021-12-05
err0
errOAAI
errDaniele Cattaneo; Michele Chiari; Nicola Fossati; Stefano Cherubin; Giovanni Agosta
errShare
errSave
err
IF0
err
err0
PREAI
err
errShare
errSave
Type-based alias analysis
err1998-05-01
err0
errOAAI
errAmer Diwan; Kathryn S. McKinley; J. Eliot B. Moss
errShare
errSave
Synergistic Memory Optimisations: Precision Tuning in Heterogeneous Memory Hierarchies
err2025-09-01
err0
PREAI
errGabriele Magnani; Daniele Cattaneo; Lev Denisov; Giuseppe Tagliavini; Giovanni Agosta; Stefano Cherubin
errShare
errSave
researcher View more