- Jun 23, 2022
-
-
Walter Erquinigo authored
In order to provide simple scripting support on top of instruction traces, a simple solution is to enhance the `dump instructions` command and allow printing in json and directly to a file. The format is verbose and not space efficient, but it's not supposed to be used for really large traces, in which case the TraceCursor API is the way to go. - add a -j option for printing the dump in json - add a -J option for pretty printing the json output - add a -F option for specifying an output file - add a -a option for dumping all the instructions available starting at the initial point configured with the other flags - add tests for all cases - refactored the instruction dumper and abstracted the actual "printing" logic. There are two writer implementations: CLI and JSON. This made the dumper itself much more readable and maintanable sample output: ``` (lldb) thread trace dump instructions -t -a --id 100 -J [ { "id": 100, "tsc": "43591204528448966" "loadAddress": "0x407a91", "module": "a.out", "symbol": "void std::deque<Foo, std::allocator<Foo>>::_M_push_back_aux<Foo>(Foo&&)", "mnemonic": "movq", "source": "/usr/include/c++/8/bits/deque.tcc", "line": 492, "column": 30 }, ... ``` Differential Revision: https://reviews.llvm.org/D128316 -
Richard authored
Eliminate clutter by reorganizing the Lit test files for clang-tidy: - Move checkers/<module>-* to checkers/<module>/*. - Move module specific inputs from Inputs to <module>/Inputs. Remove any module prefix from the file or subdirectory name as they are no longer needed. - Introduce a Lit substitution %clang_tidy_headers for the system headers in checkers/Inputs/Headers and use this throughout. This avoids referencing system headers through a relative path to the parent directory and makes it clear that these fake system headers are shared among all modules. - Update add_new_check.py to follow the above conventions when creating the boiler plate test files for a new check. - Update Contributing.rst to describe per-module Inputs directory and fix link to test source code. Differential Revision: https://reviews.llvm.org/D128072
-
Alexander Yermolovich authored
The case comes out of how BOLT handles transformation of DW_AT_low_pc/DW_AT_high_pc into DW_AT_low_pc/DW_AT_high_pc with latter being 0. Reviewed By: clayborg Differential Revision: https://reviews.llvm.org/D127889
-
Florian Mayer authored
This was necessary for code reuse between the old and new passmanager. With the old pass-manager gone, this is no longer necessary. Reviewed By: eugenis, myhsu Differential Revision: https://reviews.llvm.org/D127913
-
Argyrios Kyrtzidis authored
[Support/BLAKE3] Fix error in prior commit, apply `-mavx512vl` for `blake3_avx512_x86-64_unix.S` when including it
-
Alvin Wong authored
-
Mark de Wever authored
This is a follow up based on a request of @jloser in D127594. As drive-by qualified the function calls in the <bit> header. Reviewed By: #libc, EricWF Differential Revision: https://reviews.llvm.org/D127760
-
Joseph Huber authored
Summary: Currently we use temporary files to write the intermediate results to. However, these are stored as regular strings and we do a few unnecessary copies and conversions of them. This patch simply replaces these strings with a reference to the filename stored in the list of temporary files. The temporary files will stay alive during the whole linking phase and have stable pointers, so we should be able to cheaply pass references to them rather than copying them every time.
-
Mingming Liu authored
Binary size of `clang` is trivial; namely, numerical value doesn't change when measured in MiB, and `.data` section increases from 139Ki to 173 Ki. Differential Revision: https://reviews.llvm.org/D128070
-
lorenzo chelini authored
-
Daniel Thornburgh authored
This allows registering certain tags as possibly beginning multi-line elements in the symbolizer markup parser. The parser is kept agnostic to how lines are delimited; it reports the entire contents, including line endings, once the end of element marker is reached. Reviewed By: peter.smith Differential Revision: https://reviews.llvm.org/D124798
-
Jim Ingham authored
temporarily ignoring the others. Differential Revision: https://reviews.llvm.org/D126513
-
serge-sans-paille authored
Running iwyu-diff on LLVM codebase since fb67d683 detected a few regressions, fixing them. The impact on preprocessed output is negligible: -4k lines.
-
Richard authored
The documentation files were reorganized into subdirectories, but a new check was added concurrently and wasn't rebased correctly before submitting. Sort the new clang-tidy checks by check name and fix the indentation of bugprone-unchecked-optional-access.
-
Mark de Wever authored
Instead of instantiating all functions called by std::to_chars for the integral types only instantiate them for 32 and 64 bit integral types. This results in a smaller binary when using different types. In an example using the types: signed char, short, int, long, long long, unsigned char, unsigned short, unsigned int, unsigned long, and unsigned long long this saved 2792 bytes of code size. For libc++.so.1 is saves 688 bytes of code size (64-bit Linux). This was discovered while investigating a solution for #52709. Reviewed By: #libc, ldionne Differential Revision: https://reviews.llvm.org/D128215
-
Aart Bik authored
Thanks Peiming for reporting! Reviewed By: Peiming Differential Revision: https://reviews.llvm.org/D128308
-
Aart Bik authored
This revision makes sure we accept sparse tensors as arguments of the expand/collapse reshaping operations in the tensor dialect. Note that the actual lowering to runnable IR is still TBD. Reviewed By: springerm Differential Revision: https://reviews.llvm.org/D128311
-
Arjun P authored
[MLIR][Presburger] introduce SlowMPInt, an auto-resizing APInt for fully correct signed integer computations The Presburger library currently uses int64_t throughout for its integers. This runs the risk of silently producing incorrect results when overflows occur. Fixing this issue requires some sort of multiprecision integer that transparently supports aribtrary arithmetic computations. The class SlowMPInt provides this functionality, and is intended to be used as the slow path fallback for a more optimized upcoming class, MPInt, that optimizes for the Presburger library's workloads. Reviewed By: ftynse Differential Revision: https://reviews.llvm.org/D123758
-
Max Kazantsev authored
Scale reg should never be zero, so when the quotient is zero, we cannot assign it there. Limit this transform to avoid this situation. Differential Revision: https://reviews.llvm.org/D128339 Reviewed By: eopXD
-
Craig Topper authored
This adds RISCVISD opccodes for LA, LA_TLS_IE, and LA_TLS_GD to remove creation of MachineSDNodes form get*Addr. This makes the code consistent with the previous patches that added RISCVISD::HI, ADD_LO, LLA, and TPREL_ADD. Reviewed By: asb Differential Revision: https://reviews.llvm.org/D128325
-
Mark de Wever authored
-
Xiang Li authored
When writeValueAsMetadata for GlobalVariable and Function, write TypedPointerType for ValueType and FunctionType. Reviewed By: bogner Differential Revision: https://reviews.llvm.org/D127705
-
Peixin Qiao authored
As Fortran 2018 C1520, if proc-language-binding-spec with NAME= is specified, then proc-decl-list shall contain exactly one proc-decl, which shall neither have the POINTER attribute nor be a dummy procedure. Add this check. Reviewed By: klausler Differential Revision: https://reviews.llvm.org/D127725
-
- Jun 22, 2022
-
-
Peixin Qiao authored
This patch refines //when// driver diagnostics are formatted so that `flang-new` and `flang-new -fc1` behave consistently with `clang` and `clang -cc1`, respectively. This change only applies to driver diagnostics. Scanning, parsing and semantic diagnostics are separate and not covered here. **NEW BEHAVIOUR** To illustrate the new behaviour, consider the following input file: ```! file.f90 program m integer :: i = k end ``` In the following invocations, "error: Semantic errors in file.f90" _will be_ formatted: ``` $ flang-new file.f90 error: Semantic errors in file.f90 ./file.f90:2:18: error: Must be a constant value integer :: i = k $ flang-new -fc1 -fcolor-diagnostics file.f90 error: Semantic errors in file.f90 ./file.f90:2:18: error: Must be a constant value integer :: i = k ``` However, in the following invocations, "error: Semantic errors in file.f90" _will not be_ formatted: ``` $ flang-new -fno-color-diagnostics file.f90 err... -
Peixin Qiao authored
This adds the test case with portability warning preparing for D125804, which supports checking for portability warnings in test_errors.py. Reviewed By: ekieri Differential Revision: https://reviews.llvm.org/D127821
-
Martin Storsjö authored
This test does succeed in my local test environment though, but fails on the buildbot.
-
Jonathan Peyton authored
When many nested teams are formed, __kmp_threads may be reallocated to accommodate new threads. This reallocation causes a data race when another existing team's thread simultaneously references __kmp_threads. This patch keeps the old thread arrays around until library shutdown so these lingering references can complete without issue and access to __kmp_threads remains a simple array reference. Fixes: https://github.com/llvm/llvm-project/issues/54708 Differential Revision: https://reviews.llvm.org/D125013
-
Nikita Popov authored
Use an IRBuilder to insert instructions in preWriteTileCfg(). While here, also remove some unnecessary bool return values. There are some test changes because the IRBuilder folds "trunc i16 8 to i8" to "i8 8", and that has knock-on effects on instruction naming. I ran into this when converting tests to opaque pointers and noticed that this pass introduces unnecessary "bitcast ptr to ptr" instructions.
-
Mark de Wever authored
-
Nikita Popov authored
This runs the test through -instnamer and generates test checks using update_test_checks.py. (The previous comment indicated that update_llc_test_checks.py was used, but I rather doubt that.) This relies on the non-determinism fix from fbb72530, the previous check lines have apparently been written to accomodate that non-determinism.
-
Nikita Popov authored
We generate code by iterating over this map, so make sure that the order is deterministic.
-
Guillaume Chatelet authored
This reverts commit 8ba2cbff.
-
Nikita Popov authored
Run the test through -instnamer, to make it easier to modify.
-
Nico Weber authored
The name of the host binary changed from make_confusable_table to make-confusable-table, so match that.
-
serge-sans-paille authored
Detect identifiers that are confusable using a variant of Unicode definition http://www.unicode.org/reports/tr39/#Confusable_Detection and have conflicting scopes. This a recommit (with portability and feature fixes) of b94db7ed Differential Revision: https://reviews.llvm.org/D112916 -
Alvin Wong authored
The setting `plugin.object-file.pe-coff.module-abi` is a string-to-enum map that allows specifying an ABI to a module name. For example: ucrtbase.dll=msvc libstdc++-6.dll=gnu This allows for debugging a process which mixes both modules built using the MSVC ABI and modules built using the MinGW ABI. Depends on D127048 Reviewed By: DavidSpickett Differential Revision: https://reviews.llvm.org/D127234 -
Alvin Wong authored
LLDB tries to follow `EXCEPTION_RECORD::ExceptionRecord` to follow the nested exception chain. In practice this code just causes Access Violation whenever there is a nested exception. Since there does not appear to be any code in LLDB that is actually using the nested exceptions, this change just removes the crashing code and adds a comment for future reference. Fixes https://github.com/mstorsjo/llvm-mingw/issues/292 Reviewed By: DavidSpickett Differential Revision: https://reviews.llvm.org/D128201
-
Alvin Wong authored
This fixes an issue that, when you start lldb or use `target create` with a program name which is on $PATH, or not specify the .exe suffix of a program in the working directory on Windows, you get a confusing error, for example: (lldb) target create notepad error: 'C:\WINDOWS\SYSTEM32\notepad.exe' doesn't contain any 'host' platform architectures: i686, x86_64, i386, i386 Fixes https://github.com/mstorsjo/llvm-mingw/issues/265 Reviewed By: DavidSpickett Differential Revision: https://reviews.llvm.org/D127436 -
Martin Storsjö authored
25c8a061 / D127048 added an option for setting the ABI to GNU. When an object file is loaded, there's only minimal verification done for the architecture spec set for it, if the object file only provides one. However, for i386 object files, the PECOFF object file plugin provides two architectures, i386-pc-windows and i686-pc-windows. This picks a totally different codepath in TargetList::CreateTargetInternal, where it's treated as a fat binary. This goes through more verifications to see if the architectures provided by the object file matches what the platform plugin supports. The PlatformWindows() constructor explicitly adds the "i386-pc-windows" and "i686-pc-windows" architectures (even when running on other architectures), which allows this "fat binary verification" to succeed for the i386 object files that provide two architectures. However, after that commit, if the object file is advertised with the different environment (either when lldb is built in a mingw environment, or if that setting is set), the fat binary validation won't accept the file any longer. Update ArchSpec::IsEqualTo with more logic for the Windows use cases; mismatching vendors is not an issue (they don't have any practical effect on Windows), and GNU and MSVC environments are compatible to the point that PlatformWindows can handle object files for both environments/ABIs. As a separate path forward, one could also consider to stop returning two architecture specs from ObjectFilePECOFF::GetModuleSpecifications for i386 files. Differential Revision: https://reviews.llvm.org/D128268
-