- Jun 18, 2020
-
-
David Sherwood authored
There are now quite a few SVE tests in LLVM and Clang that do not emit warnings related to invalid use of EVT::getVectorNumElements() and VectorType::getNumElements(). For these tests I have added additional checks that there are no warnings in order to prevent any future regressions. Differential Revision: https://reviews.llvm.org/D80712
-
Haojian Wu authored
Summary: Also delete two overloads, which don't seem necessary. Reviewers: sammccall Subscribers: cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D82047
-
Jean Perier authored
Summary: This patch changes speficic extremum functions rewrite to generic MIN/MAX. It applies to AMAX0, AMIN0, AMAX1, AMIN1, MAX0, MIN0, MAX1, MIN1, DMAX1, and DMIN1. - Do not re-write specific extremums to MAX/MIN in intrinsic Probe and let folding rewrite it and introduc the conversion on the MIN/MAX result. - Also make operand promotion explicit in MIN/MAX folding. For instance, after this patch: AMAX0(int8, int4) is rewritten to REAL(MAX(int8, INT(int4, 8))) All this care is to avoid rewritting it to MAX(REAL(int8), REAL(int4)) that may not always be numerically equivalent to the first rewrite. Reviewers: klausler, schweitz, sscalpone, jdoerfert, DavidTruby Reviewed By: klausler, schweitz Subscribers: llvm-commits, flang-commits Tags: #flang, #llvm Differential Revision: https://reviews.llvm.org/D81940
-
Kristof Beyls authored
-
Kristof Beyls authored
This also enables running the AArch64 SLSHardening pass with GlobalISel, so add a test for that. Differential Revision: https://reviews.llvm.org/D81403
-
Kristof Beyls authored
The enum values for AArch64 registers are not all consecutive. Therefore, the computation "__llvm_slsblr_thunk_x" + utostr(Reg - AArch64::X0) is not always correct. utostr(Reg - AArch64::X0) will not generate the expected string for the registers that do not have consecutive values in the enum. This happened to work for most registers, but does not for AArch64::FP (i.e. register X29). This can get triggered when the X29 is not used as a frame pointer. Differential Revision: https://reviews.llvm.org/D81997
-
Max Kazantsev authored
-
Xing GUO authored
This patch helps make the `Code` optional in abbreviations table. Reviewed By: jhenderson Differential Revision: https://reviews.llvm.org/D81826
-
Rahul Joshi authored
- This will allow calling these functions from Op's that support this interface (like FuncOp) directly: ``` FuncOp func = ... func.isPrivate() ``` Differential Revision: https://reviews.llvm.org/D82060
-
Greg McGary authored
Summary: Forgot to `git add` it when patching D80677
-
Greg McGary authored
Summary: Add front-end support for `lld::macho::Configuration::frameworkSearchPath`. Depends on D80582. Reviewers: ruiu, pcc, MaskRay, smeenai, int3, Ktwu, alexshap, christylee Reviewed By: int3 Subscribers: ormris, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D80677
-
Jez Ng authored
Summary: Previously, we weren't updating isecAddr when aligning InputSections, resulting in truncated sections under the right conditions. Reviewers: #lld-macho, compnerd Reviewed By: #lld-macho, compnerd Subscribers: smeenai, compnerd, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D81298
-
Jez Ng authored
Summary: llvm-mc emits `__bss` sections with an offset of zero, but we weren't expecting that in our input, so we were copying non-zero data from the start of the file and putting it in `__bss`, with obviously undesirable runtime results. (It appears that the kernel will copy those nonzero bytes as long as the offset is nonzero, regardless of whether S_ZERO_FILL is set.) I debated on whether to make a special ZeroFillSection -- separate from a regular InputSection -- but it seemed like too much work for now. But I'm happy to refactor if anyone feels strongly about having it as a separate class. Depends on D80857. Reviewers: ruiu, pcc, MaskRay, smeenai, alexshap, gkm, Ktwu, christylee Reviewed By: smeenai Subscribers: llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D80859
-
Jez Ng authored
Summary: Turns out this case is actually really common -- it happens whenever there's a reference to an `extern` variable that ends up statically linked. Depends on D80856. Reviewers: ruiu, pcc, MaskRay, smeenai, alexshap, gkm, Ktwu, christylee Reviewed By: smeenai Subscribers: llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D80857
-
Jez Ng authored
Summary: As far as I can tell, it's identical to _GOT_LOAD. llvm-mc has the following comment explaining why _GOT exists: ``` // x86_64 distinguishes movq foo@GOTPCREL so that the linker can // rewrite the movq to an leaq at link time if the symbol ends up in // the same linkage unit. ``` Depends on D80855. Reviewers: ruiu, pcc, MaskRay, smeenai, alexshap, gkm, Ktwu, christylee Reviewed By: MaskRay, smeenai Subscribers: llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D80856
-
Jez Ng authored
Summary: Depends on D80854. Reviewers: ruiu, pcc, MaskRay, smeenai, alexshap, gkm, Ktwu, christylee Subscribers: llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D80855
-
Jez Ng authored
Summary: As mentioned in https://reviews.llvm.org/D81326#2093931, I'm not sure it makes sense to use the default target triple to determine -arch. Long-term we should probably detect it from the input object files, but in the meantime it would be nice not to have to add it to all our tests by using a convenient default. Reviewers: #lld-macho Subscribers: arphaman, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D81983
-
Mehdi Amini authored
This is fixing warning from clang: warning: private field 'ModuleSlice' is not used [-Wunused-private-field] SmallPtrSetImpl<Function *> &ModuleSlice; ^ Differential Revision: https://reviews.llvm.org/D82027 -
Kang Zhang authored
Summary: For PPC BinaryOperator of fp128 will become libcall, we shouldn't convert loop to CTR loop if the loop contain libCall. But currently, in the PPCTTIImpl::mightUseCTR() function, we only deal with BinaryOperator for ppc_fp128, don't deal with the fp128. Reviewed By: shchenz Differential Revision: https://reviews.llvm.org/D81353
-
Xing GUO authored
This patch enables yaml2elf emit the .debug_abbrev section. The generated .debug_abbrev is verified using `llvm-dwarfdump`. Known issues that will be addressed later: - Current implementation doesn't support generating multiple abbreviation tables in one .debug_abbrev section. Reviewed By: jhenderson, grimar Differential Revision: https://reviews.llvm.org/D81820
-
Esme-Yi authored
Summary: A bug is reported in bugzilla-45628, where the swap_with_shift case can’t be matched to a single HW instruction xxswapd as expected. In fact the case matches the idiom of rotate. We have MatchRotate to handle an ‘or’ of two operands and generate a rot[lr] if the case matches the idiom of rotate. While PPC doesn’t support ROTL v1i128. We can custom lower ROTL v1i128 to the vector_shuffle. The vector_shuffle will be matched to a single HW instruction during the phase of instruction selection. Reviewed By: steven.zhang Differential Revision: https://reviews.llvm.org/D81076
-
Fangrui Song authored
A hasWildcard pattern iterates over symVector, which can be slow when there are many --export-dynamic-symbol. In optimistic cases, most patterns don't use a wildcard character. hasWildcard: false can avoid a symbol table iteration. While here, add two tests using `[` and `?`, respectively.
-
Sam Clegg authored
For some reason we hadn't seen such cases in the wild which makes me think that clang and rustc don't generate these. In the bug which reproduces it only occurs with LTO so my guess is that some LTO pass is creating this alias + gep. See: https://github.com/emscripten-core/emscripten/issues/8731 Differential Revision: https://reviews.llvm.org/D79462
-
Ryan Prichard authored
Summary: The Android NDK's clang driver is used with an Android -target setting, and the driver automatically finds the Android sysroot at a path relative to the driver. The sysroot has the libc++ headers in it. Remove Hurd::computeSysRoot as it is equivalent to the new ToolChain::computeSysRoot method. Fixes PR46213. Reviewers: srhines, danalbert, #libc, kristina Reviewed By: srhines, danalbert Subscribers: ldionne, sthibaul, asb, rbar, johnrusso, simoncook, sabuasal, niosHD, jrtc27, MaskRay, zzheng, edward-jones, rogfer01, MartinMosbeck, brucehoult, the_o, PkmX, jocewei, Jim, lenary, s.egerton, pzheng, sameer.abuasal, apazos, luismarques, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D81622
-
Matt Arsenault authored
It seems to be a hardware defect that the half inline constants do not work as expected for the 16-bit integer operations (the inverse does work correctly). Experimentation seems to show these are really reading the 32-bit inline constants, which can be observed by writing inline asm using op_sel to see what's in the high half of the constant. Theoretically we could fold the high halves of the 32-bit constants using op_sel. The *_asm_all.s MC tests are broken, and I don't know where the script to autogenerate these are. I started manually fixing it, but there's just too many cases to fix. This also does break the assembler/disassembler support for these values, and I'm not sure what to do about it. These are still valid encodings, so it seems like you should be able to use them in some way. If you wrote assembly using them, you could have really meant it (perhaps to read the high bits with op_sel?). The disassembler will print the invalid l...
-
Richard Smith authored
This change depends on reverted change c7fbe219. This reverts commit c851d6cf.
-
Richard Smith authored
This change may have caused some self-host failures. Reverting while investigating. This reverts commit c7fbe219.
-
peter klausler authored
Summary: - Remove C++ library dependence from lock.h - Implement LEN_TRIM, REPEAT, ADJUSTL, ADJUSTR, MAX/MIN intrinsic functions for CHARACTER Reviewers: tskeith, PeteSteinfeld, sscalpone, schweitz, DavidTruby Reviewed By: PeteSteinfeld Subscribers: llvm-commits, flang-commits Tags: #flang, #llvm Differential Revision: https://reviews.llvm.org/D82054
-
River Riddle authored
We previously weren't properly updating the SCC iterator when nodes were removed, leading to asan failures in certain situations. This commit adds a CallGraphSCC class and defers operation deletion until inlining has finished. Differential Revision: https://reviews.llvm.org/D81984
-
HazemAbdelhafez authored
Summary: - Define the MatrixTimesScalar operation and add roundtrip tests. - Added a new base class for matrix-specific operations to avoid invalid operands type mismatch check. - Created a separate Matrix arithmetic operations td file to add more operations in the future. - Augmented the automatically generated verify method to print more fine-grained error messages. - Made minor Updates to the matrix type tests. Reviewers: antiagainst, rriddle, mravishankar Reviewed By: antiagainst Subscribers: mehdi_amini, jpienaar, shauheen, nicolasvasilache, arpith-jacob, mgester, lucyrfox, aartbik, liufengdb, stephenneuendorffer, Joonsoo, bader, grosul1, frgossen, Kayjukh, jurahul, msifontes Tags: #mlir Differential Revision: https://reviews.llvm.org/D81677
-
Artem Belevich authored
Otherwise the -Werror tests fail if the locally installed CUDA version found by the driver is newer than 10.1 and produces a warning.
-
mydeveloperday authored
Update Clang-Formatted Formatted status
-
Yonghong Song authored
In BTF, pointee type pruning is used to reduce cluttering too many unused types into prog BTF. For example, struct task_struct { ... struct mm_struct *mm; ... } If bpf program does not access members of "struct mm_struct", there is no need to bring types for "struct mm_struct" to BTF. This patch fixed a bug where an incorrect pruning happened. The test case like below: struct t; typedef struct t _t; struct s1 { _t *c; }; int test1(struct s1 *arg) { ... } struct t { int a; int b; }; struct s2 { _t c; } int test2(struct s2 *arg) { ... } After processing test1(), among others, BPF backend generates BTF types for "struct s1", "_t" and a placeholder for "struct t". Note that "struct t" is not really generated. If later a direct access to "struct t" member happened, "struct t" BTF type will be generated properly. During processing test2(), when processing member type "_t c", BPF backend sees type "_t" already generated, so returned. This caused the problem that "struct t" BTF type is never generated and eventually causing incorrect type definition for "struct s2". To fix the issue, during DebugInfo type traversal, even if a typedef/const/volatile/restrict derived type has been recorded in BTF, if it is not a type pruning candidate, type traversal of its base type continues. Differential Revision: https://reviews.llvm.org/D82041 -
Richard Smith authored
outer levels as retained rather than omitting their arguments. This better reflects what's going on (we're performing a substitution while still inside a template). In theory this is also more correct, but I've not found a testcase where it matters in practice (largely because we don't allow alias templates to be declared inside a function).
-
Richard Smith authored
templated class. When a defaulted operator<=> results in the injection of a defaulted operator==, that operator== can be named by unqualified name within the same class, even if the class is templated. To make this work, perform the transform from defaulted operator<=> to defaulted operator== in the template definition context instead of the template instantiation context. This results in our substituting into a declaration from a context where we don't have a full list of template arguments (or indeed any), for which we are now more careful to not spuriously instantiate declarations that are not dependent on the arguments we're substituting.
-
George Mitenkov authored
Added support of simple logical ops: `LogicalAnd`, `LogicalOr`, `LogicalEqual` and `LogicalNotEqual`. Added a missing conversion for `UMod` op. Also, implemented SPIR-V cast ops conversion. There are 4 simple case where there is a clear equivalent in LLVM (e.g. `ConvertFToS` is `fptosi`). For `FConvert`, `SConvert` and `UConvert` we distinguish between truncation and extension based on the bit width of the operand. Differential Revision: https://reviews.llvm.org/D81812
-
Eric Christopher authored
used in debug only code. This reverts commit 07a17490.
-
Eric Schweitz authored
Differential revision: https://reviews.llvm.org/D82050
-
Eric Christopher authored
-
Stephan Herhut authored
Summary: Parallel loop tiling did not properly compute the updated loop indices when tiling, which lead to wrong results. Differential Revision: https://reviews.llvm.org/D82013
-