- Aug 30, 2022
-
-
Matthias Springer authored
A part of the functionality of `bufferize` is extracted into `getBufferType`. Also, bufferized scf.yields inside scf.if are now created with the correct bufferized type from the get-to. Differential Revision: https://reviews.llvm.org/D132862
-
Matthias Springer authored
A part of the functionality of `bufferize` is extracted into `getBufferType`. Differential Revision: https://reviews.llvm.org/D132861
-
zhijian authored
Summary: Some of code in the patch are contributed by David Tenty. 1. We currently only check driver Wl options and don't check for the plain -b, -Xlinker or other options which get passed through to the linker when we decide whether to run llvm-nm --export-symbols, so we may run it in situations where we wouldn't if the user had used the equivalent -Wl, prefixed options. If we run the export list utility when the user has specified an export list, we could export more symbols than they intended. 2. Add a new functionality to allow redirecting the stdin, stdout, stderr of individual Jobs, if redirects are set for the Job use them, otherwise fall back to the global Compilation redirects if any. Reviewers: David Tenty, Fangrui Song, Steven Wan Differential Revision: https://reviews.llvm.org/D119147
-
Matthias Springer authored
Even though iter_arg and init_arg of an scf.for loop may have the same tensor type, their bufferized memref types are not necessarily equal. It is sometimes necessary to insert a cast in case of differing layout maps. Differential Revision: https://reviews.llvm.org/D132860
-
Jon Chesterfield authored
-
Matthias Springer authored
This change generalizes getBufferType. This function can be used to predict the buffer type of any tensor value (not just BlockArguments) without changing any IR. It also subsumes getMemorySpace. This is useful for loop bufferization, where the precise buffer type of an iter_arg cannot be known without examining the loop body. Differential Revision: https://reviews.llvm.org/D132859
-
Dmitry Preobrazhensky authored
Differential Revision: https://reviews.llvm.org/D132876
-
Dmitry Preobrazhensky authored
Differential Revision: https://reviews.llvm.org/D132869
-
Dmitry Preobrazhensky authored
Differential Revision: https://reviews.llvm.org/D132690
-
Dmitry Preobrazhensky authored
Differential Revision: https://reviews.llvm.org/D132857
-
Alexey Bataev authored
Removed EnableFP parameter in getOperandInfo function since it is not needed, the operands kinds also controlled by the operation code, which allows to remove extra check for the type of the operands. Also, added analysis for uniform constant float values. This change currently does not trigger any changes in the code since TTI does not do analysis for constant floats, so it can be considered NFC. Tested with llvm-test-suite + SPEC2017, no changes. Differential Revision: https://reviews.llvm.org/D132886
-
Dmitry Preobrazhensky authored
Differential Revision: https://reviews.llvm.org/D132854
-
Timm Bäder authored
This was passing a 6 to the diagnostic engine, which the diagnostic message didn't handle. Add the new value to the diagnosic message, remove an unused value and add a test. This fixes https://github.com/llvm/llvm-project/issues/57415 Differential Revision: https://reviews.llvm.org/D132821
-
Matheus Izvekov authored
Setting the symbolizer is required for getting a pretty stack trace when Clang crashes. Signed-off-by:
Matheus Izvekov <mizvekov@gmail.com> Differential Revision: https://reviews.llvm.org/D132807
-
serge-sans-paille authored
The test to check if an array was a FAM in the context of array bound checking and strict-flex-arrays=1 was inverted. As a by product, improve test coverage. Differential Revision: https://reviews.llvm.org/D132853
-
Markus Böck authored
When building LLVM with LLVM_BUILD_TOOLS as OFF, numerous tools such as llvm-ar or llvm-objcopy end up still being built. The reason for this is that the symlink targets are unconditionally included in a Build-all build, causing the tool they're symlinking to be built after all. This patch changes that behaviour to be more intuitive by only including the symlink in a Build-all build if the target they're linking to is also included. Differential Revision: https://reviews.llvm.org/D132883
-
zhongyunde authored
We aleady support the transform: `(X+C1)*CI -> X*CI+C1*CI` Here the case is a little special as the form of `(X+C1)*CI` is transformed into `(X|C1)*CI`, so we should also support the transform: `(X|C1)*CI -> X*CI+C1*CI` Fixes https://github.com/llvm/llvm-project/issues/57278 Reviewed By: bcl5980, spatel, RKSimon Differential Revision: https://reviews.llvm.org/D132658
-
Florian Hahn authored
Update isWriteAtEndOfFunction to look through MemoryPhis. The reason MemoryPhis were skipped so far was the known AliasAnalysis issue with it missing loop-carried dependences. This problem is already addressed in other parts of the code by skipping MemoryDefs that may be in difference loops. I think the same logic can be applied here. This can have a substantial impact on the number of stores removed in some cases. For MultiSource/SPEC2006/SPEC2017 with -O3: ``` Metric: dse.NumFastStores Program dse.NumFastStores base patch diff External/S...CINT2017rate/557.xz_r/557.xz_r 14.00 45.00 221.4% External/S...te/538.imagick_r/538.imagick_r 439.00 1267.00 188.6% MultiSourc...e/Applications/SIBsim4/SIBsim4 6.00 15.00 150.0% MultiSourc...Prolangs-C/simulator/simulator 3.00 7.00 133.3% MultiSource/Applications/siod/siod 3.00 7.00 133.3% MultiSourc...arks/FreeBench/distray/distray 6.00 9.00 50.0% MultiSourc...e/Applications/obsequi/Obsequi 22.00 30.00 36.4% MultiSource/Benchmarks/Ptrdist/bc/bc 23.00 28.00 21.7% External/S...NT2017rate/502.gcc_r/502.gcc_r 1258.00 1512.00 20.2% External/S...te/520.omnetpp_r/520.omnetpp_r 954.00 1143.00 19.8% External/S...rate/510.parest_r/510.parest_r 5961.00 7122.00 19.5% External/S...C/CINT2006/445.gobmk/445.gobmk 47.00 56.00 19.1% External/S...00.perlbench_r/500.perlbench_r 241.00 286.00 18.7% External/S...NT2006/471.omnetpp/471.omnetpp 36.00 42.00 16.7% External/S...06/400.perlbench/400.perlbench 183.00 210.00 14.8% MultiSource/Applications/SPASS/SPASS 72.00 81.00 12.5% External/S...17rate/541.leela_r/541.leela_r 72.00 80.00 11.1% External/SPEC/CINT2006/403.gcc/403.gcc 585.00 642.00 9.7% MultiSourc...e/Applications/sqlite3/sqlite3 120.00 131.00 9.2% MultiSourc...Applications/hexxagon/hexxagon 11.00 12.00 9.1% External/S.../CFP2006/453.povray/453.povray 566.00 615.00 8.7% External/S...rate/511.povray_r/511.povray_r 578.00 627.00 8.5% External/S...FP2006/482.sphinx3/482.sphinx3 12.00 13.00 8.3% MultiSource/Applications/oggenc/oggenc 130.00 140.00 7.7% MultiSourc...e/Applications/ClamAV/clamscan 250.00 268.00 7.2% MultiSourc.../mediabench/jpeg/jpeg-6a/cjpeg 19.00 20.00 5.3% MultiSourc...ch/consumer-jpeg/consumer-jpeg 19.00 20.00 5.3% External/S...te/526.blender_r/526.blender_r 3747.00 3928.00 4.8% MultiSourc...OE-ProxyApps-C++/miniFE/miniFE 104.00 108.00 3.8% MultiSourc...ch/consumer-lame/consumer-lame 54.00 56.00 3.7% MultiSource/Benchmarks/Bullet/bullet 1222.00 1264.00 3.4% MultiSourc...nchmarks/tramp3d-v4/tramp3d-v4 973.00 1005.00 3.3% External/S.../CFP2006/447.dealII/447.dealII 2699.00 2780.00 3.0% External/S...06/483.xalancbmk/483.xalancbmk 788.00 810.00 2.8% External/S.../CFP2006/450.soplex/450.soplex 180.00 185.00 2.8% MultiSourc.../DOE-ProxyApps-C++/CLAMR/CLAMR 338.00 345.00 2.1% MultiSourc...Benchmarks/7zip/7zip-benchmark 685.00 699.00 2.0% External/S...FP2017rate/544.nab_r/544.nab_r 158.00 160.00 1.3% MultiSourc...sumer-typeset/consumer-typeset 772.00 781.00 1.2% External/S...2017rate/525.x264_r/525.x264_r 410.00 414.00 1.0% External/S...23.xalancbmk_r/523.xalancbmk_r 998.00 1002.00 0.4% ``` Compile-time is almost neutral: https://llvm-compile-time-tracker.com/compare.php?from=b3125ad3d60531a97eea20009cc9629a87755862&to=84007eee59004f43464eda7f5ba8263ed5158df8&stat=instructions NewPM-O3: +0.03% NewPM-ReleaseThinLTO: -0.01% NewPM-ReleaseLTO-g: +0.03% Reviewed By: asbirlea Differential Revision: https://reviews.llvm.org/D132365 -
Johannes Reifferscheid authored
It's only used from there, and this lets us remove the dependency from Analysis to the Arith dialect. Reviewed By: springerm Differential Revision: https://reviews.llvm.org/D132928
-
Thomas Symalla authored
Reviewed By: foad Differential Revision: https://reviews.llvm.org/D132930
-
Valentin Clement authored
This patch creates a temporary of the appropriate length while lowering SetLength. The corresponding character can be truncated or padded if necessary. This fix issue with array constructor in argument and also with statement function. D132464 was fixing the same issue in genval. Reviewed By: jeanPerier Differential Revision: https://reviews.llvm.org/D132866
-
Nikita Popov authored
-
Utkarsh Saxena authored
Differential Revision: https://reviews.llvm.org/D132919
-
Tomas Matheson authored
When selecting G_EXTRACT to COPY for extracting a 64-bit GPR from a 128-bit register pair (XSeqPair) we know enough to constrain the destination register class to gpr64. Without this it may have only a register bank and some copy elimination code would assert while assuming that a register class existed. The register class has to be set explicitly because we might hit the COPY -> COPY case where register class can't be inferred. This would cause the following to crash in selection, where the store is commented (otherwise the store constrains the register class): define dso_local i128 @load_atomic_i128_unordered(i128* %p) { %pair = cmpxchg i128* %p, i128 0, i128 0 acquire acquire %val = extractvalue { i128, i1 } %pair, 0 ; store i128 %val, i128* %p ret i128 %val } Differential Revision: https://reviews.llvm.org/D132665 -
Tomas Matheson authored
widenScalarDst updates the insert point to after MI, so widenScalarSrc must be called before widenScalarDst. Otherwise The updated Src values will appear after MI and break SSA. e.g.: %14:_(s64), %15:_(s1) = G_UADDE %9:_, %11:_, %13:_ becomes %14:_(s64), %16:_(s32) = G_UADDE %9:_, %11:_, %17:_ %15:_(s1) = G_TRUNC %16:_(s32) %17:_(s32) = G_ZEXT %13:_(s1) Differential Revision: https://reviews.llvm.org/D132547 Change-Id: Ie3458747a6879433f4d5ab9939d2bd102dd0f2db
-
OCHyams authored
Taking the example from the test included in this patch: $ cat test.cpp -n 1 void fun(int *a, int cond) { 2 if (cond) 3 a[1] = 1; 4 else 5 a[1] = 2; 6 } mldst-motion will merge and sink the stores in if.then and if.else into if.end. The resultant PHI, gep and store should be attributed line zero with the innermost common scope rather than picking a debug location from one of the original stores. Reviewed By: djtodoro Differential Revision: https://reviews.llvm.org/D132741 -
Benjamin Kramer authored
[bazel] Stop building PassGenTest.cpp.inc, it was removed in 13ed6958
-
Ting Wang authored
Add isNotDuplicable to CTRLoop pseudo instructions, to avoid other pass such as early-tailduplication break the loop structure by duplicating pseudo instructions. Reviewed By: shchenz Differential Revision: https://reviews.llvm.org/D132738
-
Pavel Samolysov authored
Also, some local variables were renamed in accordance with the code style as well as `std::tie` occurrences and `.first`/`.second` member uses were replaced with structure bindings. Differential Revision: https://reviews.llvm.org/D132806
-
Michele Scuttari authored
Being the generated code macro-guarded, the autogenerated `.cpp.inc` file has been merged into the `.h.inc` to reduce the build steps. Reviewed By: mehdi_amini, rriddle Differential Revision: https://reviews.llvm.org/D132884
-
Shoaib Meenai authored
Folding them will cause the unwinder to compute the incorrect function start address for the folded entries, which in turn will cause the personality function to interpret the LSDA incorrectly and break exception handling. You can verify the end-to-end flow by creating a simple C++ file: ``` void h(); int main() { h(); } ``` and then linking this file against the liblsda.dylib produced by the test case added here. Before this change, running the resulting program would result in a program termination with an uncaught exception. Afterwards, it works correctly. Reviewed By: #lld-macho, thevinster Differential Revision: https://reviews.llvm.org/D132845 -
Martin Storsjö authored
This fixes a warning when building for Windows: ../tools/lldb/source/Host/common/TCPSocket.cpp:297:16: warning: comparison of integers of different signs: 'int' and 'const NativeSocket' (aka 'const unsigned long long') [-Wsign-compare] if (sock != kInvalidSocketValue) { ~~~~ ^ ~~~~~~~~~~~~~~~~~~~ Differential Revision: https://reviews.llvm.org/D132841 -
Martin Storsjö authored
We don't need to check for `_LIBCPP_HAS_NO_LOCALIZATION` here; this was copied over by mistake from the test above (which does use locale.h). Differential Revision: https://reviews.llvm.org/D132834
-
Ting Wang authored
Reviewed By: shchenz Differential Revision: https://reviews.llvm.org/D132899
-
Xiang1 Zhang authored
-
Richard Smith authored
This can be set at configure time and might include other characters.
-
liqinweng authored
Reviewed By: reames Differential Revision: https://reviews.llvm.org/D132822
-
Vitaly Buka authored
-
jacquesguan authored
This patch supports the FP part of D111082. Differential Revision: https://reviews.llvm.org/D125750
-
wanglian authored
Reviewed By: craig.topper Differential Revision: https://reviews.llvm.org/D132359
-