- Jul 07, 2023
-
-
Joseph Huber authored
This reverts commit a4a26374. This was causing some problems with the CPU build and CUDA buildbot. Revert until I can figure out what those issues are and fix them. I believe it is just some CMake.
-
Rob Suderman authored
Converting between a complex<f32> to i64 could be useful for handling interop between the `arith` and `complex` dialects. Reviewed By: jpienaar Differential Revision: https://reviews.llvm.org/D154663
-
Jim Ingham authored
Also, make it possible for new Targets which haven't been added to the TargetList yet to check for interruption, and add a few more places in building modules where we can check for interruption. Differential Revision: https://reviews.llvm.org/D154542
-
Joseph Huber authored
This is an alternate approach to the patches proposed in D153897 and D153794. Rather than exporting a single header that can be included on the GPU in all circumstances, this patch chooses to instead generate a separate set of headers that only provides the declarations. This can then be used by external tooling to set up what's on the GPU. This leaves room for header hacks for offloading languages without needing to worry about the `libc` implementation. Currently this generates a set of headers that only contain the declarations. These will then be installed to a new clang resource directory called `llvm_libc_wrappers/` which will house the shim code. We can then automaticlaly include this from `clang` when offloading to wrap around the headers while specifying what's on the GPU. Reviewed By: jdoerfert, JonChesterfield Differential Revision: https://reviews.llvm.org/D154036
-
Michael Maitland authored
Since the LMUL data that is needed to create an instrument is avaliable statically from vsetivli and vsetvli instructions, LMUL instruments can be automatically generated so that clients of the tool do no need to manually insert instrument comments. Instrument comments may be placed after a vset{i}vli instruction, which will override instrument that was automatically inserted. As a result, clients of llvm-mca instruments do not need to update their existing instrument comments. However, if the instrument has the same LMUL as the vset{i}vli, then it is reccomended to remove the instrument comment as it becomes redundant. Differential Revision: https://reviews.llvm.org/D154526 -
Michael Maitland authored
This precommit patch shows MaxSafeDepBytesDist is 24 when it should be 8. Differential Revision: https://reviews.llvm.org/D154173
-
Med Ismail Bennani authored
This patch attempts to fix a dead lock when loading modules in a Scripted Process. This issue was triggered by loading the modules after the process did resume, but before the process actually stop, causing the language runtime mutex to be locked by a separate thread, responsible to unwind the stack (using the runtime unwind plan), while the module loading thread was trying to notify the runtimes of the newly loaded module. To address that, this patch moves the module loading logic to be done before sending the stop event, to prevent the dead lock situation described above. Differential Revision: https://reviews.llvm.org/D154649 Signed-off-by:
Med Ismail Bennani <ismail@bennani.ma>
-
Alexander Yermolovich authored
Summary: To reduce memory footprint changed so that we process and write out TUs first, reset DIEBuilder and process CUs. CUs are processed in buckets. First bucket contains all the CUs with cross CU references. Rest processd one at a time. clang-17 build in debug mode, by clang-17. before 8:25.81 real, 834.37 user, 86.03 sys, 0 amem, 79525064 mmem 8:02.20 real, 820.46 user, 81.81 sys, 0 amem, 79501616 mmem 7:52.69 real, 802.01 user, 83.99 sys, 0 amem, 79534392 mmem after 7:49.35 real, 822.04 user, 66.19 sys, 0 amem, 34934260 mmem 7:42.16 real, 825.46 user, 63.52 sys, 0 amem, 34951660 mmem 7:46.71 real, 821.11 user, 63.14 sys, 0 amem, 34981164 mmem Differential Revision: https://phabricator.intern.facebook.com/D45883198
-
Alexander Yermolovich authored
Summary: Changed how we handle writing out .dwo and .dwp files. We now write out DWO sections sooner and destroy DIEBuilder. This should decrease memory footprint. Ran on clang-17 build in debug mode with split-dwarf. before 8:07.49 real, 664.62 user, 69.00 sys, 0 amem, 41601612 mmem 8:07.06 real, 669.60 user, 68.75 sys, 0 amem, 41822588 mmem 8:00.36 real, 664.14 user, 66.36 sys, 0 amem, 41561548 mmem after 8:21.85 real, 682.23 user, 69.64 sys, 0 amem, 39379880 mmem 8:04.58 real, 671.62 user, 66.50 sys, 0 amem, 39735800 mmem 8:10.02 real, 680.67 user, 67.24 sys, 0 amem, 39662888 mmem Differential Revision: https://phabricator.intern.facebook.com/D45458889
-
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
-