aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2023-12-01[𝘀𝗽𝗿] initial versionusers/zacklj89/sprnfcasan-clang-format-for-asan_init-changeZachary Johnson3-15/+15
Created using spr 1.3.4
2023-11-29[NFC] Fix failing test introduced in #67700Chris Bieneman1-5/+15
This fixes the test to handle the changes in the AST printer. ../clang/test/SemaHLSL/Types/BuiltinVector/ScalarSwizzles.hlsl
2023-11-29Enable custom lowering of fabs_v16f16 with AVX and fabs_v32f16 with A… ↵David Li2-2283/+26
(#73565) This is the last patch for fabs lowering. v32f16 works for AVX as well with the patch (with type legalization).
2023-11-29[HLSL] Support vector swizzles on scalars (#67700)Chris B7-5/+387
HLSL supports vector swizzles on scalars by implicitly converting the scalar to a single-element vector. This syntax is a convienent way to initialize vectors based on filling a scalar value. There are two parts of this change. The first part in the Lexer splits numeric constant tokens when a `.x` or `.r` suffix is encountered. This splitting is a bit hacky but allows the numeric constant to be parsed separately from the vector element expression. There is an ambiguity here with the `r` suffix used by fixed point types, however fixed point types aren't supported in HLSL so this should not cause any exposable problems (a separate issue has been filed to track validating language options for HLSL: #67689). The second part of this change is in Sema::LookupMemberExpr. For HLSL, if the base type is a scalar, we implicit cast the scalar to a one-element vector then call back to perform the vector lookup. Fixes #56658 and #67511
2023-11-29[OpenMP][NFC] Move more declarations out of private.h (#73823)Johannes Doerfert5-116/+128
2023-11-29[flang] Cleanup of NYI messages (#73740)Pete Steinfeld12-140/+178
This update makes the user visible messages relating to features that are not yet implemented be more consistent. I also cleaned up some of the code. For NYI messages that refer to intrinsics, I made sure the the message begins with "not yet implemented: intrinsic:" to make them easier to recognize. I created some utility functions for NYI reporting that I put into .../include/Optimizer/Support/Utils.h. These mainly convert MLIR types to their Fortran equivalents. I converted the NYI code to use the newly created utility functions.
2023-11-29Remove an outdated comment; NFCAaron Ballman1-4/+1
StandardConversionSequence is significantly larger than a word.
2023-11-29[OpenMP][NFC] Put ExponentialBackoff in a Utils header (#73816)Johannes Doerfert3-30/+55
"private.h" will go.
2023-11-29Revert "[flang] Enable alias tags pass by default (#73111)" (#73821)Tom Eccles8-60/+21
This reverts commit caba0314cf631a3ba3e982cbcdc455224046c7a8. Serious performance regressions were reported by @vzakhari https://github.com/llvm/llvm-project/issues/58303#issuecomment-1830754173 Fixing this doesn't look quick so I will revert for now.
2023-11-29Correct the documentation category for the 'cleanup' attributeAaron Ballman1-1/+1
It was previously classified as a type attribute when it is actually a variable attribute.
2023-11-29[flang] fix codegen warning from #73641 (#73808)jeanPerier1-3/+3
2023-11-29[libc++][format] Fixes formatting code units as integers. (#73396)Mark de Wever12-83/+309
This paper was voted in as a DR, so it's retroactively enabled back to C++20; the C++ version that introduced std::format. Implements: - P2909R4 Fix formatting of code units as integers (Dude, where’s my ``char``?)
2023-11-29[OpenMP][NFC] Rename OmptCallback.cpp into OpenMP/OMPT/Callback.cpp (#73813)Johannes Doerfert2-9/+11
Also revert the ifdef OMPT_SUPPORT order to have the short fallback first and not after 400 lines.
2023-11-29[OpenMP][NFC] Replace unnecessary typedefs (#73815)Johannes Doerfert3-25/+20
2023-11-29[OpenMP][NFC] Move OMPT headers into OpenMP/OMPT (#73718)Johannes Doerfert13-27/+27
2023-11-29[llvm] Replace uses of Type::getPointerTo (NFC)Youngsuk Kim5-16/+14
Work towards removing method Type::getPointerTo. Opaque ptr cleanup effort.
2023-11-29[DebugInfo][RemoveDIs] Extract DPValues in CodeExtractor like dbg.values ↵Jeremy Morse2-24/+58
(#73252) CodeExtractor shifts dbg.value intrinsics out of the region being extracted and updates them to be appropriate in the extracted function. With new non-intrinsic variable locations, we need to manually do this too, with DPValues. Most of this patch shifts and refactors some utilities in fixupDebugInfoPostExtraction so that we can add a single extra helper lambda that iterates over DPValues and applies update-utilities. We also have to assign the IsNewDbgInfoFormat flag in a bunch of places -- this normally gets set the moment you insert a block into a function (or function into a module), however a few blocks are constructed here before being inserted, thus we have to do some manual setup. Tested via LoopExtractor_alloca.ll, which invokes debugify.
2023-11-29[X86InstrInfo] support memfold on spillable inline asm (#70832)Nick Desaulniers5-14/+267
This enables -regalloc=greedy to memfold spillable inline asm MachineOperands. Because no instruction selection framework marks MachineOperands as spillable, no language frontend can observe functional changes from this patch. That will change once instruction selection frameworks are updated. Link: https://github.com/llvm/llvm-project/issues/20571
2023-11-29[flang] Make adapt.valuebyref attribute work again (#73658)Mats Petersson40-113/+162
This got "lost" in the HLFIR transformation. This patch applies the old attribute to the AssociateOp that needs it, and forwards it to the AllocaOp that is generated when lowering to FIR.
2023-11-29Fix accsessing "PresentModifierLocs" array beyond its end. (#73579)jyu2-git2-3/+7
Currently PresentModifierLocs defined with size DefaultmapKindNum; where DefaultmapKindNum = OMPC_DEFAULTMAP_pointer + 1 Before 5.0 variable-category can not be omitted. For the test like \#pragma omp target map(tofrom: errors) defaultmap(present) error would be mitted. After 5.0 that is allowd. When try to: PresentModifierLocs[DMC->getDefaultmapKind()] = DMC->getDefaultmapModifierLoc(); It is accessed beyond array end. To fix this using OMPC_DEFAULTMAP_unknow instead OMPC_DEFAULTMAP_poiner.
2023-11-29[OpenMP][NFC] Flatten plugin-nextgen/common folder sturcture (#73725)Johannes Doerfert19-108/+99
For historic reasons we had it setup that there was ` plugin-nextgen/common/PluginInterface/<sources + headers>` which is not what we do anywhere else. Now it looks like the rest: ``` plugin-nextgen/common/include/<headers> plugin-nextgen/common/src/<sources> ``` As part of this, `dlwrap.h` was moved into common/include (as `DLWrap.h`) since it is exclusively used by the plugins.
2023-11-29[LICM] Add test for #64897 (NFC)Nikita Popov1-0/+46
2023-11-29[OpenMP][NFC] Extract timescope profile support into its own header (#73727)Johannes Doerfert7-19/+44
2023-11-29[workflows] Remove sync-release-repo.yml (#73682)Tom Stellard2-94/+0
This should not be needed now that the project uses PRs, plus the OpenSSF Scorecard report flagged this as insecure.
2023-11-29[C API] Add support for setting/getting new nneg flag on zext instructions ↵Benji Smith5-0/+34
(#73592) This flag was added in #67982, but was not yet accessible via the C API. This commit adds a getter/setter for this flag, and a test for it.
2023-11-29[libc++] Add initial support for picolibcMichael Platings63-14/+441
Picolibc is a C Standard Library that is commonly used in embedded environments. This patch adds initial support for this configuration along with pre-commit CI. As of this patch, the test suite only builds the tests and nothing is run. A follow-up patch will make the test suite actually run the tests. Differential Revision: https://reviews.llvm.org/D154246
2023-11-29[libc] Fix cast semantic in integer_to_string (#73804)Guillaume Chatelet1-1/+1
2023-11-29[ELF,LTO] Test calloc defined in a lazy bitcode file for (malloc+memset => ↵Fangrui Song1-0/+57
calloc) libcall optimization Similar to https://reviews.llvm.org/D50017: malloc+memset references can be combined to a calloc reference, which is not explicit in the referencer's IR symbol table. If calloc is defined in a lazy bitcode file, we should extract the archive member to satisfy possible references from LTO generated object files; otherwise (current status, which will be fixed by #72673), `calloc` as a LazyObject symbol will be resolved by compileBitcodeFiles generated Undefined, leading to an incorrectly-extracted Defined symbol without section, which will lower to an SHN_ABS symbol at address 0.
2023-11-29[clang-format] Indent Verilog case statements with comments (#71353)sstwcw2-1/+18
If a line contains a comment outside of (fake) parentheses, the part following it is indented according to `CurrentState.Indent`. A Verilog case label and the statement that follows are broken with mustBreakBefore. So the part that follows the case label needs some special handling. Previously, that variable was left out. So the indentation was wrong when there was a comment. old: ```Verilog case (data) 16'd0: result = // 10'b0111111111; endcase case (data) 16'd0: // // result = // 10'b0111111111; endcase ``` new: ```Verilog case (data) 16'd0: result = // 10'b0111111111; endcase case (data) 16'd0: // // result = // 10'b0111111111; endcase ```
2023-11-29[clang-format] Add spaces around the Verilog implication operator (#71352)sstwcw4-14/+23
The Verilog implication operator `->` is a binary operator meaning either the left hand side is false or the right hand side is true. Previously it was treated as the C++ struct member operator. I didn't even know it existed when I added the operator formatting part. And I didn't check all the tests for all the operators I added. That is how the bad test got in.
2023-11-29[libc] Fix the GPU build for the hashing support (#73799)Joseph Huber2-7/+17
Summary: For reasons unknown to me, this function is undefined only on the GPU build if you use `uintptr_t` but not `uint64_t` directly. This patch makes an ifdef to use this directly for the GPU build to fix the bots.
2023-11-29[X86] Add fneg vector test coverageSimon Pilgrim1-0/+6514
2023-11-29[X86] Rename vec_fneg.ll to combine-fneg.llSimon Pilgrim1-0/+0
These tests are for fneg canonicalization combines, not codegen coverage tests like most of the other vec_* test files.
2023-11-29[RISCV] Pre-commit test for FrameIndex handling in getMemOperandsWithOffsetWidthAlex Bradbury1-0/+13
Currently AArch64 handles a FrameIndex operand in this function, but we fail to.
2023-11-29[gn build] Port 1a5af34e6fcbLLVM GN Syncbot1-0/+1
2023-11-29[AArch64][SME2] Enable CLAMP multi-vector builtins for SME2 (#72272)Dinar Temirbulatov2-0/+757
Thing change add builtins for SME2: sclamp.single.x2 uclamp.single.x2 fclamp.single.x2 sclamp.single.x4 uclamp.single.x4 fclamp.single.x4 Patch by: Hassnaa Hamdi <hassnaa.hamdi@arm.com>
2023-11-29[libc++] Speed up classic locale (take 2) (#73533)Louis Dionne6-55/+172
Locale objects use atomic reference counting, which may be very expensive in parallel applications. The classic locale is used by default by all streams and can be very contended. But it's never destroyed, so the reference counting is also completely pointless on the classic locale. Currently ~70% of time in the parallel stringstream benchmarks is spent in locale ctor/dtor. And the execution radically slows down with more threads. Avoid reference counting on the classic locale. With this change parallel benchmarks start to scale with threads. This is a re-application of f8afc53d641c (aka PR #72112) which was reverted in 4e0c48b907f1 because it broke the sanitizer builds due to an initialization order fiasco. This issue has now been fixed by ensuring that the locale is constinit'ed. Co-authored-by: Dmitry Vyukov <dvyukov@google.com>
2023-11-29[libc++] Build the dylib with sanitizers when requested (#73656)Louis Dionne1-2/+5
We were detecting which sanitizer flags to use when building libc++.dylib but we were never actually adding those flags to the targets, which means that our sanitized builds would basically build the dylib without any sanitizers enabled.
2023-11-29[mlir][nvvm] Introduce `setmaxregister.sync.aligned` Op (#73780)Guray Ozen4-0/+55
This PR introduce `setmaxregister.sync.aligned` Op to increase or decrease the register size. https://docs.nvidia.com/cuda/parallel-thread-execution/index.html#miscellaneous-instructions-setmaxnreg
2023-11-29[libc++] Remove unused Python imports (#73724)Stephan T. Lavavej14-20/+5
VSCode's Pylance extension informed me, and text searching confirmed, that these imports are unused. I believe we should be able to remove them harmlessly.
2023-11-29 [MLIR][Vector] Refactor tests for contract -> OP transforms (3/N) (#73447)Andrzej Warzyński1-192/+279
This patch refactors tests for: vector.contract -> vector.outerproduct for matvec operations (b += Ax). Summary of changes: * names of LIT variables are unified, * "plain" tests (i.e. without masking and with fixed-width vectors) are moved to the top of their respective sections, * missing "plain" cases are added. This is a part of a larger effort to add cases with scalable vectors to tests for the Vector dialect. I am refactoring these tests so that it's easier to identify what cases are tested and where to add tests for scalable vectors. Implements #72834.
2023-11-29[X86] Add getTargetConstantPoolFromBasePtr helper. NFC.Simon Pilgrim1-3/+5
Split out of getTargetConstantFromBasePtr
2023-11-29[OpenMP] New Openmp device RTL functions (#73225)Dominik Adamski2-0/+284
Add new implementation of workshare loop functions. These functions will be used by OpenMPIRBuilder to support handling of OpenMP workshare loops for the target region. --------- Co-authored-by: Johannes Doerfert <johannes@jdoerfert.de>
2023-11-29[OpenMP][libomptarget] Use two SDMA engines (#73633)Jan Patrick Lehr1-2/+2
Limit the use to two SDMA engines which are optimized for such transfers.
2023-11-29[DebugInfo][RemoveDIs] Make debugify pass convert to/from RemoveDIs mode ↵Jeremy Morse33-6/+101
(#73251) Debugify is extremely useful as a testing and debugging tool, and a good number of LLVM-IR transform tests use it. We need it to support "new" non-instruction debug-info to get test coverage, but it's not important enough to completely convert right now (and it'd be a large undertaking). Thus: convert to/from dbg.value/DPValue mode on entry and exit of the pass, which gives us the functionality without any further work. The cost is compile-time, but again this is only happening during tests. Tested by: the large set of debugify tests enabled here. Note the InstCombine test (cast-mul-select.ll) that hasn't been fully enabled: this is because there's a debug-info sinking piece of code there that hasn't been instrumented.
2023-11-29Move documentation about -verify from a header to public docs (#73694)Aaron Ballman2-150/+169
The internals manual seems like a more obvious home for the details instead of hiding them away in a header file and relying on doxygen output to document it publicly.
2023-11-29[flang] Handle absent optional in LOC (#73530)jeanPerier2-148/+150
LOC is a GNU extension, so gfortran is the reference for it, and it accepts absent OPTIONAL and returns zero. Support this use case in flang too. Update the LOC test to use HLFIR while touching it. Fixes https://github.com/llvm/llvm-project/issues/72823.
2023-11-29[flang] Fix test ctofortran (#73738)Pete Steinfeld1-2/+11
After merge request #73124, the flang test Driver/ctofortran started failing because both the C and the Fortran code had main programs. This update fixes that by eliminating the C main program in the test.
2023-11-29[SelectionDAG] Fix assertion for widening of mask operand in MSTORE. (#73295)Francesco Petrogalli1-1/+1
According to the code in `SelectionDAG::getMaskedStore`, the Mask operator is in position 4, not 3: SDValue Ops[] = {Chain, Val, Base, Offset, Mask};
2023-11-29[clang][analyzer] Support `fgets` in the SteamChecker (#73638)Ben Shi4-36/+89