- Mar 02, 2021
-
-
Sam Clegg authored
Part of ongoing conversion work started in https://reviews.llvm.org/D80361. Differential Revision: https://reviews.llvm.org/D97651
-
Yuanfang Chen authored
Remove source_mgr remark diagnose kind.
-
Yuanfang Chen authored
The situation with inline asm/MC error reporting is kind of messy at the moment. The errors from MC layout are not reliably propagated and users have to specify an inlineasm handler separately to get inlineasm diagnose. The latter issue is not a correctness issue but could be improved. * Kill LLVMContext inlineasm diagnose handler and migrate it to use DiagnoseInfo/DiagnoseHandler. * Introduce `DiagnoseInfoSrcMgr` to diagnose SourceMgr backed errors. This covers use cases like inlineasm, MC, and any clients using SourceMgr. * Move AsmPrinter::SrcMgrDiagInfo and its instance to MCContext. The next step is to combine MCContext::SrcMgr and MCContext::InlineSrcMgr because in all use cases, only one of them is used. * If LLVMContext is available, let MCContext uses LLVMContext's diagnose handler; if LLVMContext is not available, MCContext uses its own default diagnose handler which just prints SMDiagnostic. * Change a few clients(Clang, llc, lldb) to use the new way of reporting. Reviewed By: MaskRay Differential Revision: https://reviews.llvm.org/D97449
-
Luís Marques authored
-
Med Ismail Bennani authored
This patch reverts the following commits: - 5a9c3491 - 46796762 - 2cff3dec - 182f0d1a - d62a53aa Signed-off-by:
Med Ismail Bennani <medismail.bennani@gmail.com>
-
MaheshRavishankar authored
Add canonicalizers to subtensor_insert operations need canonicalizers that propagate the constant arguments within offsets, sizes and strides. Also add pattern to propogate tensor_cast operations. Differential Revision: https://reviews.llvm.org/D97704
-
Jonas Devlieghere authored
-
Nikita Popov authored
The current narrowing code for G_PHI can only handle the case where the size is a multiple of the narrow size. If this is not the case, fall back to SDAG instead of asserting. Original patch by shepmaster. Differential Revision: https://reviews.llvm.org/D92446
-
Yaxun (Sam) Liu authored
Only test it with x86 since other target may have an ABI making it difficult to test. Change-Id: I85423c8bbbbbb8f24cb3ea4cb64a408069b4d61c
-
Nathan James authored
Added an option to control whether to apply the fixes found in notes attached to clang tidy errors or not. Diagnostics may contain multiple notes each offering different ways to fix the issue, for that reason the default behaviour should be to not look at fixes found in notes. Instead offer up all the available fix-its in the output but don't try to apply the first one unless `-fix-notes` is supplied. Reviewed By: aaron.ballman Differential Revision: https://reviews.llvm.org/D84924
-
Matt Arsenault authored
Generic code should probably not introduce G_INSERT/G_EXTRACT. The mirror unpackRegs should also be removed, but AMDGPU still has a use remaining which needs to be fixed.
-
Jessica Paquette authored
Remove a rule which allows larger scalar types than the destination vector element type. This appears to be irrelevant now that we have G_BUILD_VECTOR_TRUNC. Plus, making a G_BUILD_VECTOR which satisfies this introduces a verifier failure anyway. Differential Revision: https://reviews.llvm.org/D97727
-
Artem Belevich authored
`noreturn` complicates control flow and tends to trigger a known bug in ptxas if the assert is used within loops in sufficiently complicated code. https://bugs.llvm.org/show_bug.cgi?id=27738 Differential Revision: https://reviews.llvm.org/D97708
-
David Green authored
This pass has for a while performed Tail predication as well as VPT block optimizations. Rename the pass to make that clear.
-
Amara Emerson authored
def of the adrp before the ldr. Apparently this pass used to have liveness analysis but it was removed for scompile time reasons. This workaround prevents the LOH from being emitted unless the ADD and LDR are adjacent. Fixes https://github.com/JuliaLang/julia/issues/39820 Differential Revision: https://reviews.llvm.org/D97571
-
Nathan James authored
Adds an option, `PreferResetCall`, currently defaulted to `false`, to the check. When `true` the check will refactor by calling the `reset` member function. Reviewed By: aaron.ballman Differential Revision: https://reviews.llvm.org/D97630
-
Stella Stamenova authored
These warnings are raised when compiling with gcc due to either having too few or too many commas, or in the case of lldb, the possibility of a nullptr. Reviewed By: mehdi_amini Differential Revision: https://reviews.llvm.org/D97586
-
David Green authored
-
Yaxun (Sam) Liu authored
Change-Id: I86b534223d63bf8bb8f49af5a64b300efbeba77b
-
Fangrui Song authored
`__llvm_prf_vnodes` and `__llvm_prf_names` are used by runtime but not referenced via relocation in the translation unit. With `-z start-stop-gc` (D96914 https://sourceware.org/bugzilla/show_bug.cgi?id=27451), the linker no longer lets `__start_/__stop_` references retain them. Place `__llvm_prf_vnodes` and `__llvm_prf_names` in `llvm.used` to make them retained by the linker. This patch changes most existing `UsedVars` cases to `CompilerUsedVars` to reflect the ideal state - if the binary format properly supports section based GC (dead stripping), `llvm.compiler.used` should be sufficient. `__llvm_prf_vnodes` and `__llvm_prf_names` are switched to `UsedVars` since we want them to be unconditionally retained by both compiler and linker. Behaviors on other COFF/Mach-O are not affected. Differential Revision: https://reviews.llvm.org/D97649
-
Med Ismail Bennani authored
This patch should fi the build issue on the windows bots: https://lab.llvm.org/buildbot/#/builders/83/builds/4214/steps/5/logs/stdio Signed-off-by:
Med Ismail Bennani <medismail.bennani@gmail.com>
-
Anirudh Prasad authored
- This patch adds in the distinction between jg[*] and jl[*] pc-relative mnemonics based on the variant/dialect. - Under the hlasm variant, we use the jl[*] family of mnemonics and under the att (GNU as) variant, we use the jg[*] family of mnemonics. - jgnop which was added in https://reviews.llvm.org/D92185, is now restricted to att variant. jlnop is introduced and restricted to hlasm variant. - The br[*]l additional mnemonics are mapped to either jl[*]/jg[*] based on the variant. Reviewed By: uweigand Differential Revision: https://reviews.llvm.org/D97581
-
Yaxun (Sam) Liu authored
Currently clang uses stub function to launch kernel. This is inconvenient to interop with C++ programs since the stub function has different name as kernel, which is required by ROCm debugger. This patch emits a variable symbol which has the same name as the kernel and uses it to register and launch the kernel. This allows C++ program to launch a kernel by using the original kernel name. Reviewed by: Artem Belevich Differential Revision: https://reviews.llvm.org/D86376
-
Sanjay Patel authored
This set of transforms should be extended to handle vector types.
-
Richard Smith authored
Some of the parts of this work were reverted; stop defining the feature test macro for now. This reverts commit b4c63ef6.
-
Nico Weber authored
This adds support for `-undefined dynamic_lookup`, and for `-undefined warning` and `-undefined suppress` with `-flat_namespace`. We just replace undefined symbols with a DynamicLookup when we hit them. With this, `check-llvm` passes when using ld64.lld.darwinnew as host linker. Differential Revision: https://reviews.llvm.org/D97642
-
Krystian Kuzniarek authored
clang-format documentation states that having enabled FixNamespaceComments one may expect below code: c++ namespace a { foo(); } to be turned into: c++ namespace a { foo(); } // namespace a In reality, no "// namespace a" was added. The problem was too high value of kShortNamespaceMaxLines, which is used while deciding whether a namespace is long enough to be formatted. As with 9163fe2a, clang-format idempotence is preserved. Differential Revision: https://reviews.llvm.org/D87587 -
Björn Schäpers authored
... without an active column limit. Before line comments were not touched at all with ColumnLimit == 0. Differential Revision: https://reviews.llvm.org/D96896
-
Nico Weber authored
-flat_namespace makes lld emit binaries that use name lookup that's more in line with other POSIX systems: Instead of looking up symbols as (dylib,name) pairs by dyld, they're instead looked up just by name. -flat_namespace has three effects: 1. MH_TWOLEVEL and MH_NNOUNDEFS are no longer set in the Mach-O header 2. All symbols use BIND_SPECIAL_DYLIB_FLAT_LOOKUP as ordinal 3. When a dylib is added to the link, its dependent dylibs are also added, so that lld can verify that no undefined symbols remain at the end of a link with -flat_namespace. These transitive dylibs are added for symbol resolution, but they are not emitted in LC_LOAD_COMMANDs. -undefined with -flat_namespace still isn't implemented. Before this change, it was impossible to hit that combination because -flat_namespace caused a diagnostic. Now that it no longer does, emit a dedicated temporary diagnostic when both flags are used. Differential Revision: https://reviews.llvm.org/D97641
-
Nico Weber authored
For -flat_namespace, lld needs to load dylibs in LC_LOAD_DYLIB. The current setup meant that libSystem.dylib would cause a LC_LOAD_DYLIB with libSystem.B.dylib, but that didn't exist in our libsysroot for tests. So just drop the .B. See https://reviews.llvm.org/D97641#2595237 and https://reviews.llvm.org/D97641#2595270
-
Nico Weber authored
-
peter klausler authored
Implement the related character intrinsic functions SCAN and VERIFY. Differential Revision: https://reviews.llvm.org/D97580
-
Med Ismail Bennani authored
This patch introduces Scripted Processes to lldb. The goal, here, is to be able to attach in the debugger to fake processes that are backed by script files (in Python, Lua, Swift, etc ...) and inspect them statically. Scripted Processes can be used in cooperative multithreading environments like the XNU Kernel or other real-time operating systems, but it can also help us improve the debugger testing infrastructure by writting synthetic tests that simulates hard-to-reproduce process/thread states. Although ScriptedProcess is not feature-complete at the moment, it has basic execution capabilities and will improve in the following patches. rdar://65508855 Differential Revision: https://reviews.llvm.org/D95713 Signed-off-by:
Med Ismail Bennani <medismail.bennani@gmail.com>
-
Med Ismail Bennani authored
In order to facilitate the writting of Scripted Processes, this patch introduces a `ScriptedProcess` python base class in the lldb module. The base class holds the python interface with all the - abstract - methods that need to be implemented by the inherited class but also some methods that can be overwritten. This patch also provides an example of a Scripted Process with the `MyScriptedProcess` class. rdar://65508855 Differential Revision: https://reviews.llvm.org/D95712 Signed-off-by:
Med Ismail Bennani <medismail.bennani@gmail.com>
-
Med Ismail Bennani authored
This patch adds a ScriptedProcess interface to the ScriptInterpreter and more specifically, to the ScriptInterpreterPython. This interface will be used in the C++ `ScriptProcess` Process Plugin to call the script methods. At the moment, not all methods are implemented, they will upstreamed in upcoming patches. This patch also adds helper methods to the ScriptInterpreter to convert `SBAPI` Types (SBData & SBError) to `lldb_private` types (DataExtractor & Status). rdar://65508855 Differential Revision: https://reviews.llvm.org/D95711 Signed-off-by:
Med Ismail Bennani <medismail.bennani@gmail.com>
-
Med Ismail Bennani authored
This patch adds a new command options to the CommandObjectProcessLaunch for scripted processes. Among the options, the user need to specify the class name managing the scripted process. The user can also use a key-value dictionary holding arbitrary data that will be passed to the managing class. This patch also adds getters and setters to `SBLaunchInfo` for the class name managing the scripted process and the dictionary. rdar://65508855 Differential Review: https://reviews.llvm.org/D95710 Signed-off-by:
Med Ismail Bennani <medismail.bennani@gmail.com>
-
Med Ismail Bennani authored
This patch changes the short option used in `CommandOptionsProcessLaunch` for the `-v|--environment` command option to `-E|--environment`. The reason for that is, that it collides with the `-v|--structured-data-value` command option generated by `OptionGroupPythonClassWithDict` that I'm using in an upcoming patch for the `process launch` command. The long option `--environment` remains the same. Differential Review: https://reviews.llvm.org/D95100 Signed-off-by:
Med Ismail Bennani <medismail.bennani@gmail.com>
-
Nico Weber authored
This matches ld64's behavior. Differential Revision: https://reviews.llvm.org/D97718
-
Nico Weber authored
Matches the ELF and COFF ports, which use ld.lld and lld-link, respectively. While here, also move up `cleanupCallback` to match ELF / COFF. Differential Revision: https://reviews.llvm.org/D97715
-
Sanjay Patel authored
-