commit | 3b58a60086cb755fe40cb90a73d27a83d44ce766 | [log] [tgz] |
---|---|---|
author | Timm Baeder <tbaeder@redhat.com> | Fri Apr 25 07:43:33 2025 +0200 |
committer | GitHub <noreply@github.com> | Fri Apr 25 07:43:33 2025 +0200 |
tree | 269a7f260938e40b371dee4d86a92c44f2c1050c | |
parent | 6d99d1a4a93564ab7a128c269b2c55dcbd4f9570 [diff] |
[clang][bytecode] Allow forming pointers to fields of extern globals (#137211) This should be fine as long as we're not reading from it. Note that this regresses CXX/special/class.init/class.inhctor.init/p1.cpp, which used to work fine with the bytecode interpreter. That's because this code now fails: ```c++ struct Param; struct A { constexpr A(Param); int a; }; struct B : A { B(); using A::A; int b = 2; }; struct Wrap1 : B { constexpr Wrap1(); }; struct Wrap2 : Wrap1 {}; extern const Wrap2 b; struct Param { constexpr Param(int c) : n(4 * b.a + b.b + c) {} int n; }; ``` and reports that the Param() constructor is never a valid constant expression. But that's true and the current interpeter should report that as well. It also fails when calling at compile time.
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.