- Jul 07, 2023
-
-
Alexander Yermolovich authored
Summary: * Some cleanup and minor fixes for the new debug information re-writer before moving on to productatization. * The new rewriter wasn't handling binary with DWARF5 and DWARF4 with -fdebug-types-sections. * Removed dead cross cu reference code. * Added support for DW_AT_sibling. * With the new re-writer abbrev number can change which can lead to offset of Type Units changing. Before we would just copy raw data. Changed to write out Type Unit List. This is generated by gdb-add-index. * Fixed how bolt handles gdb-index generated by gdb-11 with types sections. Simplified logic that handles variations of gdb-index. * Clang can generate two type units with the same hash, but different content. LLD does not de-duplicate when ThinLTO is involved. Changed so that TU hash and offset are used to make TU's unique. * It is possible to have references within location expression to another DIE. Fixed it so that relative offset is updated correctly. * Removed all the code related to patching. * Removed dead code. Changed how we handling writting out TUs and TU Index. It now should fully work for DWARF4 and DWARF5. * Removed unused arguments from some APIs, changed return type to void, and other small cleanups. Test Plan: Reviewers: Subscribers: Tasks: Tags: Differential Revision: https://phabricator.intern.facebook.com/D46168257
-
Alexander Yermolovich authored
Summary: This revision implement new mechanism for DWARFRewriter. In the new mechanism, we adopt the same way with DWARFLinker did. By parsing Debug information into IR, we are allowed to handle debug information more flexible. Now the debug information updating process relies on IR and IR will be written out to binary once the updating finished. A new class was added: DIEBuilder. This class is responsible for parsing debug information and raising it to the IR level. This class is also used to write out the .debug_info and .debug_abbrev sections. Since we output brand new Abbrev section we won't need to always convert low_pc/high_pc into ranges. When conversion does happen we can also remove low_pc entry. Differential Revision: https://phabricator.intern.facebook.com/D39484421 Tasks: T117448832
-
Scott Linder authored
* Relax the AsmParser to accept `.amdhsa_wavefront_size32 0` when the `.amdhsa_shared_vgpr_count` directive is present. * Teach the KD disassembler to respect the setting of KERNEL_CODE_PROPERTY_ENABLE_WAVEFRONT_SIZE32 when calculating the value of `.amdhsa_next_free_vgpr`. * Teach the KD disassembler to disassemble COMPUTE_PGM_RSRC3 for gfx90a and gfx10+. * Include "pseudo directive" comments for gfx10 fields which are not controlled by any assembler directive. * Fix disassembleObject failure diagnostic in llvm-objdump to not hard-code a comment string, and to follow the convention of not capitalizing the first sentence. Reviewed By: rochauha Differential Revision: https://reviews.llvm.org/D128014
-
Felipe de Azevedo Piovezan authored
When LLDB queries the debug names index with a regex, we should use the `Mangled` class wrapper, which attempts to match regex first against the mangled name and then against the demangled name. It is important to do so, otherwise queries like `frame var --regex A::` would never work. This is what is done for the Apple index as well. This fixes test/API/lang/cpp/class_static/main.cpp when compiled with DWARF 5. Differential Revision: https://reviews.llvm.org/D154617
-
Felipe de Azevedo Piovezan authored
Differential Revision: https://reviews.llvm.org/D154610
-
Arthur Eubanks authored
Compile time improvements: https://llvm-compile-time-tracker.com/compare.php?from=a4a2b62495a63516a4f782acff1b19361906546b&to=a408521f71702a5c5fb65077adc23413d8631cfc&stat=instructions:u Reviewed By: nikic Differential Revision: https://reviews.llvm.org/D152744
-
Arthur Eubanks authored
Fixes invariant memory regressions in future DSE patches. Also add a flag to print<memoryssa> to not ensure optimized uses to test this. Noticeable compile time regression [1], but a future DSE change that depends on this more than makes up for it. [1] https://llvm-compile-time-tracker.com/compare.php?from=9d5466849a770eeab222d5a5890376d3596e8ad6&to=95682dbe11d76a3342870437377216e96b167504&stat=instructions:u Reviewed By: asbirlea Differential Revision: https://reviews.llvm.org/D152859
-
Valentin Clement authored
The return type of the recipe must match the array slice provided by the user. This patch enhance the recipe creation to take into account the constant slices. Depends on D154259 Reviewed By: razvanlupusoru Differential Revision: https://reviews.llvm.org/D154648
-
Valentin Clement authored
Generate code to allocate privates for trivial scalars and arrays. Reviewed By: razvanlupusoru Differential Revision: https://reviews.llvm.org/D154259
-
Louis Dionne authored
This is NFC because the function object is stateless anyway. This is done solely for consistency with surrounding code and this was probably an oversight in https://reviews.llvm.org/D132505. Differential Revision: https://reviews.llvm.org/D154612
-
Maksim Panchenko authored
GCC requires "class" keyword when variable name matches class name. Reviewed By: ayermolo Differential Revision: https://reviews.llvm.org/D154654
-
Gedare Bloom authored
C89 and C99 list initializers are treated differently than Cpp11 braced initializers. This patch identifies the C array/struct initializer lists by finding the preceding equal sign before a left brace, and applies formatting rules for BracketAlignmentStyle.BlockIndent to those list initializers. Fixes #57878. Differential Revision: https://reviews.llvm.org/D153205
-
Derek Schuff authored
The llvm.frexp.* family of intrinsics and their corresponding libcalls were recently added, which means we need to know their signatures. Differential Revision: https://reviews.llvm.org/D154639 Fixed: https://github.com/llvm/llvm-project/issues/63657
-
John Harrison authored
Reviewed By: wallace Differential Revision: https://reviews.llvm.org/D154029
-
Slava Zakharin authored
ApplyOp provides the type parameters in its argument, so we can take it from there. For hlfir.expr block arguments (such as with user-defined assignments) we use hlfir.get_length in lowering. Depends on D154561 Reviewed By: jeanPerier Differential Revision: https://reviews.llvm.org/D154562
-
Slava Zakharin authored
Lower hlfir.get_length into the char length inquiry of the bufferized entity. In some cases the codegen will fail with `hlfir.associate of hlfir.expr with more than one use` - this will be fixed separately (after D154521). Depends on D154560 Reviewed By: tblah, jeanPerier Differential Revision: https://reviews.llvm.org/D154561
-
Slava Zakharin authored
We will use hlfir.get_length to lower inquiries of char length applied to hlfir.expr character values. Reviewed By: tblah, jeanPerier Differential Revision: https://reviews.llvm.org/D154560
-
Yuze Chi authored
Debug info emission for extern variables in C++ was previously disabled when the functionality was added in https://reviews.llvm.org/D71818 and originally in https://reviews.llvm.org/D70696, because there was no use case. We are enabling it now, as we start to deploy BPF programs compiled from C++, leveraging C++ features like templates to reduce code complexity. This patch is required so that we can still use kconfig in such BPF programs compiled from C++. Reviewed By: rnk, dblaikie, MaskRay, yonghong-song Differential Revision: https://reviews.llvm.org/D153898
-
Noah Goldstein authored
This is just filling in a missing case from D144225. We treat `(shl Y, X)` and `(shl Z, X)` as `(mul Z, 1 << X)` and `(mul Y, 1 << X)` then reuse the same transformations that already exist. Reviewed By: sdesmalen Differential Revision: https://reviews.llvm.org/D147108
-
Noah Goldstein authored
Differential Revision: https://reviews.llvm.org/D147107
-
Noah Goldstein authored
Forked from D142901 to deduce more `nsw`/`nuw` flag for the output `shl`. We can handle the following cases + some `nsw`/`nuw` flags: The rationale for doing this all in `InstCombine` rather than handling the constant `shl` cases in `InstSimplify` is we often create a new instruction because we are able to deduce more `nsw`/`nuw` flags than the original instruction had. Differential Revision: https://reviews.llvm.org/D144225
-
Noah Goldstein authored
Seems natural to highlight 'nocapture' along with other attributes like 'nonnull', 'noundef', etc.. Differential Revision: https://reviews.llvm.org/D154571
-
Jennifer Yu authored
clause. This is just syntax to make it easier for the user. It doesn't add any new functionality. for doacross(sink: omp_cur_iteration - 1) Equivalent to doacross(sink: ConterVar - 1, ...) doacross(source: omp_cur_iteration) Equivalent to doacross(source) And restriction is: OMP5.2 p.327 If vector is specified with the omp_cur_iteration keyword and with sink as the dependence-type then it must be omp_cur_iteration - 1. If vector is specified with source as the dependence-type then it must be omp_cur_iteration. Differential Revision: https://reviews.llvm.org/D154556
-
Alexander Yermolovich authored
There was a bug in a code that pre-populated line string for a case where parts of .debug_line are not processed by BOLT, but copied as raw data. We were not switching sections. This resulted in parts of the binary being over-written with debug data. Reviewed By: maksfb Differential Revision: https://reviews.llvm.org/D154544
-
LLVM GN Syncbot authored
-
LLVM GN Syncbot authored
-
LLVM GN Syncbot authored
-
LLVM GN Syncbot authored
-
Maksim Panchenko authored
Create LinuxKernelRewriter and move kernel-specific code to this class. Depends on D154023 Reviewed By: Amir Differential Revision: https://reviews.llvm.org/D154024
-
Maksim Panchenko authored
Use new MetdataRewriter interface to update pseudo probes and move ProbeDecoder out of BinaryContext into new PseudoProbeRewriter class. Depends on D154021 Reviewed By: Amir Differential Revision: https://reviews.llvm.org/D154022 Differential Revision: https://reviews.llvm.org/D154023
-
Maksim Panchenko authored
Migrate SDT markers processing to the new MetadataRewriter interface. Depends on D154020 Reviewed By: Amir Differential Revision: https://reviews.llvm.org/D154021
-
Maksim Panchenko authored
Introduce the MetadataRewriter interface to handle updates for various types of auxiliary data stored in a binary file. To implement metadata processing using this new interface, all metadata rewriters should derive from the RewriterBase class and implement one or more of the following methods, depending on the timing of metadata read and write operations: * preCFGInitializer() * postCFGInitializer() // TBD * preEmitFinalizer() // TBD * postEmitFinalizer() By adopting this approach, we aim to simplify the RewriteInstance class and improve its scalability to accommodate new extensions of file formats, including various metadata types of the Linux Kernel. Differential Revision: https://reviews.llvm.org/D154020
-
Arthur Eubanks authored
-
Liam Fitzpatrick authored
1) Turns the canonicalization into a fold, so it can cleanup IR within other passes. 2) When the output of the reshape is a dynamic shaped tensor, we cannot apply the fold to the constant, because constants are required to have static shape. Differential Revision: https://reviews.llvm.org/D154615
-
Thurston Dang authored
Attempt 2 at fixing a buildbot error https://lab.llvm.org/buildbot#builders/57/builds/28143 that I had introduced in D154272
-
Paul Robinson authored
Differential Revision: https://reviews.llvm.org/D154383
-
Chia-hung Duan authored
This increases the parallelism and the usage of TSDs Reviewed By: cferris Differential Revision: https://reviews.llvm.org/D152988
-
Chia-hung Duan authored
When all the blocks (local caches are included) are freed, the size of free blocks should be equal to `AllocatedUser`. Reviewed By: cferris Differential Revision: https://reviews.llvm.org/D152769
-
Jonathan Peyton authored
* Return 0 length topology if socket layer is detected first * Fix DEBUG ASSERT
-
Fangrui Song authored
The error message now matches llvm-objcopy --compress-debug-sections=[zlib|zstd].
-