- Aug 11, 2020
-
-
Jay Foad authored
This is equivalent to the new llvm.abs intrinsic added by D84125 with is_int_min_poison=0. Differential Revision: https://reviews.llvm.org/D85718
-
Gousemoodhin Nadaf authored
- Fixed point to floating point conversion is unimplemented. - If one of the operands has a floating type and the other operand has a fixed-point type, the function handleFloatConversion() is called because one of the operands has a floating type, but we do not handle fixed point type in this function (Implementation of fixed point to floating point conversion is missing), due to this compiler crashes. In order to avoid compiler crash, when one of the operands has a floating type and the other operand has a fixed-point type, return NULL. - FIXME: Implementation of fixed point to floating point conversion. - I am going to resolve FIXME in followup patches. - Add the test case. Reviewed By: ebevhan Differential Revision: https://reviews.llvm.org/D81904
-
Bevin Hansson authored
ASTContext::removeAddrSpaceQualType does not properly deal with sugar. QualTypes derive their ASes from the AS on the canonical type, not the type itself. However, removeAddrSpaceQualType only strips the outermost qualifiers, which means that it can fail to remove addrspace qualifiers if there is sugar in the way. Change the function to desugar types until the address space really no longer exists on the corresponding QualType. This should guarantee the removal of the address space. This fixes the erroneous behavior in D62574. Reviewed By: rjmccall, svenvh Differential Revision: https://reviews.llvm.org/D83325
-
Sanjay Patel authored
I think this is the last remaining translation of an existing instcombine transform for the corresponding cmp+sel idiom. This interpretation is more general though - we can remove mismatched signed/unsigned combinations in addition to the more obvious cases. min/max(X, Y) must produce X or Y as the result, so this is just another clause in the existing transform that was already matching a min/max of min/max.
-
Sanjay Patel authored
There are 4*4*4 = 64 variations. We currently handle some, but not all, of the alternative patterns with cmp+sel in instcombine.
-
Sanjay Patel authored
-
Alex Zinenko authored
Now that LLVM dialect types are implemented directly in the dialect, we can use MLIR hooks for verifying type construction invariants. Implement the verifiers and use them in the parser. Reviewed By: rriddle Differential Revision: https://reviews.llvm.org/D85663
-
Simon Pilgrim authored
Handles some HOP(SHUFFLE,SHUFFLE) patterns and sets us up to improve some of the cases mentioned in PR41813.
-
Matt Arsenault authored
Slight restructuring of the code to avoid formatting changes when more cases are handled here.
-
Matt Arsenault authored
The wrong alignment or addrspace was used. Also add various cases to stress a future patch.
-
Fangrui Song authored
For an InputSection, the `buf` argument of `InputSectionBase::relocate` points to the content of the containing OutputSection, instead of the content of the InputSection itself, so `outSecOff` needs to be added in its callees. This is counter-intuitive and leads to many `- outSecOff` and `+ outSecOff`. This patch makes `InputSection::writeTo` call `InputSectionBase::relocate` with `outSecOff` added. relocAlloc/relocNonAlloc/relocateNonAllocForRelocatable can thus be simplified now. Updated test: * non-abs-reloc.s: A minor offset bug is fixed for a diagnostic in `relocateNonAlloc` Reviewed By: grimar Differential Revision: https://reviews.llvm.org/D85618
-
Fangrui Song authored
Catch problems when outSecOff is not zero and outSecOff is added twice or not added.
-
Fangrui Song authored
where stdio.h ::remove() may set errno to EEXIST instead of ENOTEMPTY. POSIX.1-2017 allows EEXIST for unlink() (which is called by remove()): > [EEXIST] or [ENOTEMPTY] > The flag parameter has the AT_REMOVEDIR bit set and the path argument names a directory that is not an empty directory, or there are hard links to the directory other than dot or a single entry in dot-dot. Reviewed By: ro Differential Revision: https://reviews.llvm.org/D85690
-
Bruno Ricci authored
There are already matchers for type template parameters and non-type template parameters, but somehow no matcher exists for template template parameters and I need it to write unit tests. Differential Revision: https://reviews.llvm.org/D85536 Reviewed By: aaron.ballman
-
David Stenberg authored
Allow the GNU .debug_macro extension to be emitted for DWARF versions earlier than 5. The extension is basically what became DWARF 5's format, except that a DW_AT_GNU_macros attribute is emitted, and some entries like the strx entries are missing. In this patch I emit GNU's indirect entries, which are the same as DWARF 5's strp entries. This patch adds the extension behind a hidden LLVM flag, -use-gnu-debug-macro. I would later want to enable it by default when tuning for GDB and targeting DWARF versions earlier than 5. The size of a Clang 8.0 binary built with RelWithDebInfo and the flags "-gdwarf-4 -fdebug-macro" reduces from 1533 MB to 1349 MB with .debug_macro (compared to 1296 MB without -fdebug-macro). Reviewed By: SouraVX, dblaikie Differential Revision: https://reviews.llvm.org/D82975
-
David Stenberg authored
Broken out from a review comment on D82975. This is an NFC expect for that the Macinfo macro string is now emitted using a single emitBytes() invocation, so it can be done using a single string directive. Reviewed By: dblaikie Differential Revision: https://reviews.llvm.org/D83557
-
Benjamin Kramer authored
-
Xing GUO authored
Currently, the line table uses the first compilation unit's address size as its address size. It's not the right behavior. The address size should be inferred from the target machine. Reviewed By: jhenderson Differential Revision: https://reviews.llvm.org/D85707
-
Valentin Clement authored
This patch takes advantage of the directive information and tablegen generation to replace the clauses class parse tree and in the dump parse tree sections. Reviewed By: sscalpone Differential Revision: https://reviews.llvm.org/D85549
-
Matt Arsenault authored
This mirrors the support for the equivalent extracts. This also creates a huge mess that would be greatly improved if we had any bit operation combines.
-
Dinar Temirbulatov authored
switch to SmallString, this is part of D57779.
-
Raphael Isemann authored
`addDecl` is making the ivar visible in its primary context. The primary context of the ivar here is in a 'fragile' ABI the ObjCInterfaceDecl and in a 'non-fragile' ABI the current ObjCImplementationDecl. The additional call to `makeDeclVisibleInContext` to make the ivar visible in the ObjCInterfaceDecl is only necessary in the 'non-fragile' case (as in the 'fragile' case the Decl becomes automatically visible in the ObjCInterfaceDecl with the `addDecl` call as thats its primary context). See `Sema::ActOnIvar` for where the ivar is put into a different context depending on the ABI. To put this into an example: ``` lang=c++ @implementation SomeClass { id ivar1; } @end fragile case: implicit ObjCInterfaceDecl 'SomeClass' `- ivar1 (in primary context and will be automatically made visible) ObjCImplementationDecl 'SomeClass' non-fragile case: implicit ObjCInterfaceDecl 'SomeClass' `-<<<ivar1 not visible here and needs to be manually marked as visible.>>> ObjCImplementationDecl 'SomeClass' `- ivar1 (in its primary context and will be automatically made visible here) ``` Making a Decl visible multiple times in the same context is inefficient and potentially can lead to crashes. See D84827 for more info and what this is breaking. Reviewed By: aprantl Differential Revision: https://reviews.llvm.org/D84829 -
Raphael Isemann authored
`addDecl` is making the Decl visible, so there is no need to make it explicitly visible again. Making it visible twice will also make the lookup storage less efficient and potentially lead to crashes, see D84827 for that. Reviewed By: aprantl Differential Revision: https://reviews.llvm.org/D84828
-
Matt Arsenault authored
ISD::ATOMIC_STORE arbitrarily has the operands in the opposite order from regular ISD::STORE, which always introduced an annoying duplication of patterns to handle both cases. Since in GlobalISel there's just the one G_STORE, we need to swap the operands to correctly emit the type check for the pointer operand. Some work started in 20aafa31 to migrate SelectionDAG to use ISD::STORE for atomics, but that work seems to have stalled. Since this is the pretty much the last operation which matters which isn't supported for AMDGPU, use this compatibility hack to unblock declaring it functionally complete. Not sure what's going on with the pending_phis AArch64 test. It seems it didn't always use atomics, and I'm not sure what it was originally testing matters anymore.
-
Tim Keith authored
According to llvm/cmake/config-ix.cmake, gcc's potentially uninitialized use analysis has lots of false positives. We are encountering one in flang/lib/Lower/CharacterExpr.cpp. That warning is disabled for gcc in in-tree builds; this does the same thing for out-of-tree builds. Differential Revision: https://reviews.llvm.org/D85694
-
Sam Parker authored
Add some tests around thresholds and minsize.
-
Kadir Cetinkaya authored
This was resulting in inserting headers at bogus locations, see https://github.com/ycm-core/YouCompleteMe/issues/3736 for an example. Differential Revision: https://reviews.llvm.org/D85590
-
Kadir Cetinkaya authored
This tweak uses constructs like auto and refs, which are not available in C. Differential Revision: https://reviews.llvm.org/D85727
-
Kadir Cetinkaya authored
fixes https://github.com/clangd/clangd/issues/489 Differential Revision: https://reviews.llvm.org/D85721
-
clementval authored
This reverts commit bf93edc4. Buildbot failure
-
Georgii Rymar authored
It removes all `unwrapOrError` calls except the first one, which is is bit different and can be removed separately. Differential revision: https://reviews.llvm.org/D85303
-
Rainer Orth authored
Two tests currently `XPASS` on sparcv9: Unexpectedly Passed Tests (2): Builtins-sparcv9-sunos :: compiler_rt_logbl_test.c Builtins-sparcv9-sunos :: divtc3_test.c The following patch fixes this. Tested on `sparcv9-sun-solaris2.11`. Differential Revision: https://reviews.llvm.org/D85119 -
Georgii Rymar authored
program-headers.test was merged to gnu-phdrs.test and removed in D85526. Now, gnu-phdrs.test contains tests for both GNU and LLVM style. It was decided that this renaming should be done separately for a better commit history and diffing purposes.
-
Valentin Clement authored
This patch takes advantage of the directive information and tablegen generation to replace the clauses class parse tree and in the dump parse tree sections. Reviewed By: sscalpone Differential Revision: https://reviews.llvm.org/D85549
-
Georgii Rymar authored
We have `gnu-phdrs.test` that tests `-l`, `--program-headers` and `--segment` options for `llvm-readelf`. We also have: 1) `program-headers.test` that tests `--program-headers` and `-l` for `llvm-readobj`. It doesn't test `--segment` and also uses lots of precompiled objects. It is very incomplete in compare with the `gnu-phdrs.test`. 2) `pt-gnu-property.test` that contains a simple test for the `PT_GNU_PROPERTY` segment. There is no reason to have it in a separate file. This patch: 1) Merges `program-headers.test` and `pt-gnu-property.test` to `gnu-phdrs.test`. 2) Removes 2 precompiled binaries used by `program-headers.test` (other ones are still used by another tests). Differential revision: https://reviews.llvm.org/D85526
-
Sjoerd Meijer authored
-
Pavel Labath authored
Fixes some unused variable warnings with gcc.
-
Pavel Labath authored
These definitions are needed by any file which uses gtest. Previously we were adding them in the add_unittest function, but over time we've accumulated libraries (which don't go through add_unittest) building on gtest and this has resulted in proliferation of the definitions. Making this a part of the library interface enables them to be managed centrally. This follows a patch for -Wno-suggest-override (D84554) which took a similar approach. Differential Revision: https://reviews.llvm.org/D84748
-
Simon Pilgrim authored
This should be addressed by combineHorizOpWithShuffle once we enable it for HADD/SUB
-
Simon Pilgrim authored
This should be addressed by combineHorizOpWithShuffle once we enable it for HADD/SUB
-