Open theo-lw opened 2 years ago
For what it's worth, I tried reproducing this on previous versions of clang. I could reproduce it on clang-13 but not on clang-12. Still seems reproducible on clang-trunk.
$ clang-13 -v
clang version 13.0.0 (https://github.com/llvm/llvm-project.git ec1a49170129ddb62f268ff0b3f12b3d09987a7e)
Target: x86_64-unknown-linux-gnu
Thread model: posix
InstalledDir: /scratch/software/clang-trunk/bin
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/10
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/8
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/9
Selected GCC installation: /usr/lib/gcc/x86_64-linux-gnu/10
Candidate multilib: .;@m64
Candidate multilib: 32;@m32
Candidate multilib: x32;@mx32
Selected multilib: .;@m64
$ clang-12 -v
clang version 12.0.0 (https://github.com/llvm/llvm-project.git ad7aaa475e5e632242b07380ec47d2f35d077209)
Target: x86_64-unknown-linux-gnu
Thread model: posix
InstalledDir: /scratch/software/clang-trunk/bin
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/10
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/8
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/9
Selected GCC installation: /usr/lib/gcc/x86_64-linux-gnu/10
Candidate multilib: .;@m64
Candidate multilib: 32;@m32
Candidate multilib: x32;@mx32
Selected multilib: .;@m64
Extended Description
The .text section for the following program (program0_preprocessed.c ) changes after toggling the -g flag.