- Oct 25, 2023
-
-
Min-Yih Hsu authored
This patch also includes: - Remove legacy non_imm12 PatLeaf from RISCVInstrInfoZb.td - Implement a custom GlobalISel operand renderer for TrailingZeros SDNodeXForm
-
Craig Topper authored
This was previously passed by value. It used to be passed by non-const reference, but it was changed to value in D110610. I'm not sure why.
-
michaelrj-google authored
These bugs were found with the new printf long double fuzzing. The long double inf vs nan bug was introduced when we changed to get_explicit_exponent. The bitcast msan issue hadn't come up previously, but isn't a real bug, just a poisoning confusion.
-
Fazlay Rabbi authored
Reference: (1) OpenMP 5.2 Specification - Seciton 5.4.6 Differential revision: https://reviews.llvm.org/D159546
-
Alexey Bataev authored
-
Chris Carlon authored
The `--stdlib` flag can affect the system headers used by `clang` during compilation. By default, `clang` will use the platform-installed C++ standard headers, but with `--stdlib=libc++`, `clang` can use headers included in the distribution for its `libc++` implementation. Prior to this patch, if `compile_commands.json` specified `-stdlib=libc++` or an equivalent form and `--query-driver` took effect, `clangd` would ignore `stdlib` and index based on the platform's headers. When these mismatch, e.g. due to version differences, `clangd`'s completions and the actual compilation can differ. fixes clangd/clangd#1784 --------- Co-authored-by:Chris Carlon <cjc25@cjc25.com>
-
robozati authored
Raw string literals are a C++ feature first added in C++11. Fixes https://github.com/clangd/clangd/issues/1795.
-
Luke Lau authored
-
Kiran Chandramohan authored
First half of the tests switching to opaque pointers. Rest of the tests are omptarget-*.mlir and a specific test for typed pointers. Patch created as requested in https://github.com/llvm/llvm-project/pull/69772
-
Amara Emerson authored
Gives small code size improvements across the board at -Os CTMark. Much of the work is porting the existing heuristics in the DAGCombiner.
-
Leonard Chan authored
This reverts commit 37432c15. The tunings for the lsan allocator for Fuchsia on RISCV should be adjusted.
-
Guray Ozen authored
#69934 broke integration tests that rely on the kernel-bare-ptr-calling-convention and host-bare-ptr-calling-convention flags. This PR brings these flags. Also the kernel-index-bitwidth flag is removed, as kernel pointer size depends on the host. Separating host (64-bit) and kernel (32-bit) is not viable.
-
Peiming Liu authored
-
Aart Bik authored
also typo fix
-
Valery Dmitriev authored
Test exposes issue with delayed gather emission, which may lead to generating an instruction which does not dominate all users.
-
Craig Topper authored
If VT has less bits than SCC, using a ZeroExtendInReg isn't going to fix it. That's an AND instruction. We need to truncate the value instead. This should be ok because we already checked that the boolean contents is ZeroOrOne so the setcc can only produce 0 or 1. No test because I found this while trying to make i32 legal for RISC-V 64 which I'm not ready to upload yet. You can see in the coverage report that this line isn't tested today. https://lab.llvm.org/coverage/coverage-reports/coverage/Users/buildslave/jenkins/workspace/coverage/llvm-project/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp.html#L27270
-
maksfb authored
Some optimization passes may duplicate basic blocks and assign the same input offset to a number of different blocks in a function. This is done e.g. to correctly map debugging ranges for duplicated code. However, duplicate input offsets present a problem when we use AddressMap to generate new addresses for basic blocks. The output address is calculated based on the input offset and will be the same for blocks with identical offsets. The result is potentially incorrect debug info and BAT records. To address the issue, we have to eliminate the dependency on input offsets while generating output addresses for a basic block. Each block has a unique label, hence we extend AddressMap to include address lookup based on MCSymbol and use the new functionality to update block addresses.
-
Aiden Grossman authored
This patch adds support for building the libc docs in Github actions. This eanbles easily diagnosing doc build failures/warnings in PRs and at the tip of tree.
-
Jakub Mazurkiewicz authored
This patch adds a mention that the following papers are in progress: * P2770R0: #66033 * P2441R2 and P2711R1: #65536
-
Philip Reames authored
A bit debateable since we could extract it from the MachineFunction (and thus the MachineInstr), but we have the same pattern for MachineFunction associated structure already for TII and MRI.
-
Philip Reames authored
This reverts commit 122c89b2. Change does not build, with errors such as: In file included from ../llvm-project/llvm/tools/dsymutil/DebugMap.h:24, from ../llvm-project/llvm/tools/dsymutil/DwarfLinkerForBinary.h:13, from ../llvm-project/llvm/tools/dsymutil/DwarfLinkerForBinary.cpp:9: ../llvm-project/llvm/tools/dsymutil/RelocationMap.h:60:17: error: declaration of ‘llvm::dsymutil::SymbolMapping llvm::dsymutil::ValidReloc::SymbolMapping’ changes meaning of ‘SymbolMapping’ [-fpermissive] 60 | SymbolMapping SymbolMapping; | ^~~~~~~~~~~~~ ../llvm-project/llvm/tools/dsymutil/RelocationMap.h:36:8: note: ‘SymbolMapping’ declared here as ‘struct llvm::dsymutil::SymbolMapping’ 36 | struct SymbolMapping { | ^~~~~~~~~~~~~ In file included from ../llvm-project/llvm/tools/dsymutil/DwarfLinkerForBinary.h:13, from ../llvm-project/llvm/tools/dsymutil/DwarfLinkerForBinary.cpp:9: ../llvm-project/llvm/tools/dsymutil/DebugMap.h:198:32: error: declaration of ‘std::optional<llvm::dsymutil::RelocationMap> llvm::dsymutil::DebugMapObject::RelocationMap’ changes meaning of ‘RelocationMap’ [-fpermissive] 198 | std::optional<RelocationMap> RelocationMap; | ^~~~~~~~~~~~~ In file included from ../llvm-project/llvm/tools/dsymutil/DebugMap.h:24, from ../llvm-project/llvm/tools/dsymutil/DwarfLinkerForBinary.h:13, from ../llvm-project/llvm/tools/dsymutil/DwarfLinkerForBinary.cpp:9: ../llvm-project/llvm/tools/dsymutil/RelocationMap.h:76:7: note: ‘RelocationMap’ declared here as ‘class llvm::dsymutil::RelocationMap’ 76 | class RelocationMap { | ^~~~~~~~~~~~~
-
Amir Ayupov authored
Fix clang build (`return Error => return std::move(Error)`)
-
cor3ntin authored
To avoid crashes later in sema. Fixes #69962 Fixes #69838
-
Valentin Clement (バレンタイン クレメン) authored
`gatherDataOperandAddrAndBounds` was crashing when a single array element was passed in a data clause. This patch fixes the issue.
-
Philip Reames authored
-
Peiming Liu authored
-
antangelo authored
Reland "[clang][Sema] Use original template pattern when declaring implicit deduction guides for nested template classes" (#69676) Reland of dd0fba11 When a nested template is instantiated, the template pattern of the inner class is not copied into the outer class ClassTemplateSpecializationDecl. The specialization contains a ClassTemplateDecl with an empty record that points to the original template pattern instead. As a result, when looking up the constructors of the inner class, no results are returned. This patch finds the original template pattern and uses that for the lookup instead. Based on CWG2471 we must also substitute the known outer template arguments when creating deduction guides for the inner class. Changes from the last iteration: 1. The outer retained levels from the outer template are always added to the `MultiLevelTemplateArgumentList` for rewriting `FunctionTemplateDecl` arguments, even if there is no FTD and the arguments are empty. 2. When building implicit deduction guides, the template pattern underlying decl is pushed as the current context. This resolves the issue where `FindInstantiatedDecl` is unable to find the inner template class. 3. Tests are updated to cover the failing case, and to assert that the type is correct after argument deduction in the implicit case.
-
Adrian Prantl authored
I need this API in the Swift plugin, but it seems generally useful enough to expose it in the main branch.
-
Felix Schneider authored
This patch adds verifiers to `tosa.reduce_*` ops that check, among other things, that the supplied `axis` argument is compatible with the input/output tensors' shapes. We allow for a special case of `axis == 0 && rank == 0` to be valid. This patch also adds a check to `ReduceInferReturnTypes()` to ensure that the shape inference pass doesn't crash on an invalid `axis` argument anymore. Fix https://github.com/llvm/llvm-project/issues/68187
-
Zahira Ammarguellat authored
This reverts commit a3a7d631. When compiling with MSVC2022 in C++32 mode this is giving an error. Compiling this simple test case: t1.cpp: with -std=c++23 will give the following error: In file included from C:\Users\zahiraam\t1.cpp:1: c:\Program files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.35.32215\include\vector:3329:16: error: compile with '-ffixed-point' to enable fixed point types 3329 | _Vbase _Accum = 0; | ^ c:\Program files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.35.32215\include\vector:3329:23: error: expected unqualified-id 3329 | _Vbase _Accum = 0; | ^ c:\Program files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.35.32215\include\vector:3334:13: error: compile with '-ffixed-point' to enable fixed point types 3334 | _Accum |= _Tmp ? _Mask : _Vbase{0}; | ^ c:\Program files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.35.32215\include\vector:3334:20: error: expected unqualified-id 3334 | _Accum |= _Tmp ? _Mask : _Vbase{0}; | ^ c:\Program files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.35.32215\include\vector:3336:53: error: expected '(' for function-style cast or type construction 3336 | this->_Emplace_back_unchecked(_Accum); | ~~~~~~^ c:\Program files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.35.32215\include\vector:3337:17: error: compile with '-ffixed-point' to enable fixed point types 3337 | _Accum = 0; | ^ c:\Program files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.35.32215\include\vector:3337:24: error: expected unqualified-id 3337 | _Accum = 0; | ^ c:\Program files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.35.32215\include\vector:3343:49: error: expected '(' for function-style cast or type construction 3343 | this->_Emplace_back_unchecked(_Accum); | ~~~~~~^ c:\Program files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.35.32215\include\vector:3352:16: error: compile with '-ffixed-point' to enable fixed point types 3352 | _Vbase _Accum = 0; | ^ c:\Program files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.35.32215\include\vector:3352:26: error: expected unqualified-id 3352 | _Vbase _Accum = 0; | ^ c:\Program files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.35.32215\include\vector:3357:13: error: compile with '-ffixed-point' to enable fixed point types 3357 | _Accum |= _Tmp ? _Mask : _Vbase{0}; | ^ c:\Program files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.35.32215\include\vector:3357:20: error: expected unqualified-id 3357 | _Accum |= _Tmp ? _Mask : _Vbase{0}; | ^ c:\Program files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.35.32215\include\vector:3359:46: error: expected '(' for function-style cast or type construction 3359 | this->_Myvec.push_back(_Accum); | ~~~~~~^ c:\Program files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.35.32215\include\vector:3360:17: error: compile with '-ffixed-point' to enable fixed point types 3360 | _Accum = 0; | ^ c:\Program files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.35.32215\include\vector:3360:24: error: expected unqualified-id 3360 | _Accum = 0; | ^ c:\Program files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.35.32215\include\vector:3366:42: error: expected '(' for function-style cast or type construction 3366 | this->_Myvec.push_back(_Accum); | ~~~~~~^ 16 errors generated. See also comment here: https://github.com/llvm/llvm-project/pull/67750#issuecomment-1775264907
-
Ilya Leoshkevich authored
struct DEP defined in multiple testcases must correspond to runtime's struct kmp_depend_info. The former defines flags as int, and the latter as kmp_uint8_t. This discrepancy goes unnoticed on little-endian systems, but breaks big-endian ones. Make flags in struct DEP unsigned char.
-
Ilya Leoshkevich authored
structs kmp_depend_info.flags and kmp_tasking_flags contain bitfields, which overlay integer flag values. The current bitfield definitions target little-endian machines. On big-endian machines bitfields are laid out in the opposite order, so the current definitions do not work there. There are two ways to fix this: either provide big-endian bitfield definitions, or bit-swap integer flag values. Go with the former, since it's localized to one place and therefore is more maintainable.
-
Alpha Abdoulaye authored
This adds support in dsymutil for mergeable libraries [1]. dsymutil reads a new stab emitted by ld, allowing it to operate on dynamic libraries instead of object files. It also now loads the DWARF files associated to the libraries, and build the debug map for each binary from the list of symbols exported by the library. For each Debug Map Object, there is a new associated Relocation Map which is serialized from the information retrieved in the original debug_info (or debug_addr) section of the .o file. The final DWARF file has multiple compile units, so the offsets information of the relocations are adjusted relatively to the compile unit they will end up belonging to, inside the final linked DWARF file. [1] https://developer.apple.com/documentation/xcode/configuring-your-project-to-use-mergeable-libraries Differential revision: https://reviews.llvm.org/D158124
-
Jakub Kuderski authored
This is so that we can append multiple values at once without having to create a temporary array or repeatedly call `push_back`. Use the new function `append_values` to clean up the SPIR-V serializer code. (NFC)
-
Harvin Iriawan authored
This is the first of a series of patch to improve Alias Analysis on Scalable quantities. Keep Scalable information from TypeSize which will be used in Alias Analysis.
-
Fazlay Rabbi authored
The syntax of modifiers without comma separators in the map clause was deprecated in OpenMP 5.2. Reference: OpenMP 5.2 Spec, page 627, line 19
-
Rainer Orth authored
69660ccf broke the [Solaris/sparcv9 buildbot](https://lab.llvm.org/staging/#/builders/12/builds/264): `compiler-rt/lib/builtins/int_to_fp.h` unconditionally uses `*int128_t` which don't exist on 32-bit SPARC. As suggested in https://github.com/llvm/llvm-project/pull/67540, this patch fixes this by moving the `CRT_HAS_TF_MODE` guard up which does the necessary checks. Tested on `sparcv9-sun-solaris2.11`.
-
Craig Topper authored
Previously they were passed by non-const reference. No in tree target modifies the values. This makes it possible to call assignValueToAddress from assignCustomValue without a const_cast. For example in this patch https://github.com/llvm/llvm-project/pull/69138.
-
Augusto Noronha authored
When moving the GetTypeForDIE function from DWARFASTParserClang to DWARFASTParser, I kept the signature as-is. To match the rest of the function signatures in DWARFASTParser, remove the full name (lldb_private::plugin::dwarf::DWARFDIE -> DWARFDIE) in the signature of DWARFASTParser::GetTypeForDIE.
-
Alexander Richardson authored
GCC provides these functions (e.g. __addtf3, etc.) in libgcc on x86_64. Since Clang supports float128, we can also enable the existing code by using float128 for fp_t if either __FLOAT128__ or __SIZEOF_FLOAT128__ is defined instead of only supporting these builtins for platforms with 128-bit IEEE long doubles. This commit defines a new tf_float typedef that matches a float with attribute((mode(TF)) on each given architecture. There are more tests that could be enabled for x86, but to keep the diff smaller, I restricted test changes to ones that started failing as part of this refactoring. This change has been tested on x86 (natively) and aarch64,powerpc64,riscv64 and sparc64 via qemu-user. This supersedes https://reviews.llvm.org/D98261 and should also cover the changes from https://github.com/llvm/llvm-project/pull/68041.
-