[llubi] Add support for undef values (#205602) Although we are planning to deprecate the undef value, it is still widely used in the intermediate results of the pipeline, which blocks the pass bisection. This patch uses `freeze poison` as a refinement of undef. Note that the undef value evaluates to different values each time the user is executed. So it cannot be cached like other constants. A temporary buffer is introduced to take ownership of these values and avoid breaking the interface (although this is a bit ugly...). This will also be used by a follow-up patch for ptrtoint/inttoptr. From my experience, it is enough for test case reduction of middle-end miscompilation bugs (there are still counterexamples like https://github.com/dtcxzyw/llvm-autoreduce/issues/61). However, when processing backend miscompilation bugs, lli typically uses a garbage value, so that llvm-reduce may produce an invalid result. I think we may need to introduce two flags to migrate this issue: one for poisoning uninitialized memory, and another for diagnosing immediately when non-deterministic behaviour occurs. This would prevent llvm-reduce from converting a deterministic repro into a non-deterministic one. `llvm/test/tools/llubi/unsupported_constant.ll` is also dropped because it is annoying to pick another unimplemented constant value...
Welcome to the LLVM project!
This repository contains the source code for LLVM, a toolkit for the construction of highly optimized compilers, optimizers, and run-time environments.
The LLVM project has multiple components. The core of the project is itself called “LLVM”. This contains all of the tools, libraries, and header files needed to process intermediate representations and convert them into object files. Tools include an assembler, disassembler, bitcode analyzer, and bitcode optimizer.
C-like languages use the Clang frontend. This component compiles C, C++, Objective-C, and Objective-C++ code into LLVM bitcode -- and from there into object files, using LLVM.
Other components include: the libc++ C++ standard library, the LLD linker, and more.
Consult the Getting Started with LLVM page for information on building and running LLVM.
For information on how to contribute to the LLVM project, please take a look at the Contributing to LLVM guide.
Join the LLVM Discourse forums, Discord chat, LLVM Office Hours or Regular sync-ups.
The LLVM project has adopted a code of conduct for participants to all modes of communication within the project.