- Jan 19, 2022
-
-
Matt Arsenault authored
This was ignoring the requested result register, resulting in a missing def when this happened in the IRTranslator. Fixes some crashes and verifier errors at -O0. Alternatively we could pass DstOps to the constant fold functions.
-
Sam Clegg authored
We already perform memory initialization and apply global relocations during start. It makes sense to performs data relocations too. I think the reason we were not doing this already is solely historical. Differential Revision: https://reviews.llvm.org/D117412
-
Ed Maste authored
The kern.elf64.aslr.pie_enable and kern.elf32.aslr.pie_enable sysctls control the default setting for PIE binary address randomization, but it is possible to enable or disable ASLR on a per-process basis. So, use procctl(2) to query whether ASLR is enabled. (Note that with ASLR enabled but sysctl kern.elf64.aslr.pie_enable=0 a PIE binary will in effect have randomization disabled, and would be functional with msan. This is not intended as as a user-facing control though; proccontrol(1) should be used to disable aslr for the process.) Reviewed By: devnexen Differential Revision: https://reviews.llvm.org/D117521
-
Matt Arsenault authored
If the conversion artifact introduced in the unmerge of cast of merge combine already existed in the function, this would introduce dead copies which kept the old casts around, neither of which were deleted, and would fail legalization. This would fail as follows: The G_UNMERGE_VALUES of the G_SEXT of the G_BUILD_VECTOR would introduce a G_SEXT for each of the scalars. Some of the required G_SEXTs already existed in the function, so CSE moves them up in the function and introduces a copy to the original result register. The introduced CSE copies are dead, since the originally G_SEXTs were already directly used. These copies add a use to the illegal G_SEXTs, so they are not deleted. The artifact combiner does not see the defs that need to be updated, since it was hidden inside the CSE builder. I see 2 potential fixes, and opted for the mechanically simpler one, which is to just not insert the cast if the result operand isn't used. Alternatively, we could not insert the cast directly into the result register, and use replaceRegOrBuildCopy similar to the case where there is no conversion. I suspect this is a wider problem in the artifact combiner.
-
Mehdi Amini authored
Before this patch, deferred location in operation like `test.pretty_printed_region` would break the parser, and so the IR round-trip. Depends On D117088 Reviewed By: rriddle Differential Revision: https://reviews.llvm.org/D117413
-
Chris Bieneman authored
This change gets the split-file tests passing on Windows when autocrlf=true.
-
Stanislav Gatev authored
This is part of the implementation of the dataflow analysis framework. See "[RFC] A dataflow analysis framework for Clang AST" on cfe-dev. Reviewed-by: xazax.hun Differential Revision: https://reviews.llvm.org/D117567
-
Amir Ayupov authored
Summary: Show individual bytes in the annotation mask. Test Plan: ninja llvm-bolt Reviewers: maksfb FBD30026393
-
Amir Ayupov authored
Summary: Move the annotation to avoid dynamic memory allocations. Improves the CPU time of instrumenting a large binary by 1% (+-0.8%, p-value 0.01) Test Plan: NFC Reviewers: maksfb FBD30091656
-
Sam McCall authored
Knowing the type of more dependent expressions means we can diagnose more errors at template parsing rather than instantiation time. Such templates are IFNDR, so this is a QoI improvement. I hadn't anticipated this in the original patch, so had no test.
-
David Green authored
This extends the code in SearchForAndLoads to be able to look through ANY_EXTEND nodes, which can be created from mismatching IR types where the AND node we begin from only demands the low parts of the register. That turns zext and sext into any_extends as only the low bits are demanded. To be able to look through ANY_EXTEND nodes we need to handle mismatching types in a few places, potentially truncating the mask to the size of the final load. Recommitted with a more conservative check for the type of the extend. Differential Revision: https://reviews.llvm.org/D117457
-
Philip Reames authored
A readonly operand bundle disallows inference of readnone from the callee, but it should not prevent us from using the readnone fact on the callee to infer readonly for the callsite. Fixes pr53270. Differential Revision: https://reviews.llvm.org/D117591
-
Mehdi Amini authored
This will allow to return to the client of `parseLocationInstance` a location that is resolved later. Reviewed By: rriddle Differential Revision: https://reviews.llvm.org/D117088
-
Chris Bieneman authored
Trimming whitespace or carriage returns from symbols allows this code to work on Windows and makes it match other places symbol lists are handled. Reviewed By: MaskRay Differential Revision: https://reviews.llvm.org/D117570
-
Philip Reames authored
If we have a writeonly function called from a callsite with a potentially reading operand bundle, we can not conclude the callsite is writeonly. The changed test is the only one I've been able to demonstrate a current miscompile on, but an incorrect result here could show up in a bunch of subtle ways. For instance, this issue caused several spurious test changes when combined with D117591.
-
John Ericson authored
I am breaking apart D99484 so the cause of build failures is easier to understand. Reviewed By: Meinersbur Differential Revision: https://reviews.llvm.org/D117541
-
Sam Clegg authored
It seems the first half of this test was disabled in error as part of https://reviews.llvm.org/D93066. Differential Revision: https://reviews.llvm.org/D117594
-
spupyrev authored
This is an extension of **profi** post-processing step that rebalances counts in CFGs that have basic blocks w/o probes (aka "unknown" blocks). Specifically, the new version finds many more "unknown" subgraphs and marks more "unknown" basic blocks as hot (which prevents unwanted optimization passes). I see up to 0.5% perf on some (large) binaries, e.g., clang-10 and gcc-8. The algorithm is still linear and yields no build time overhead.
-
Fabian Wolff authored
Fixes PR#52245. I've also added a few test cases beyond PR#52245 that would also fail with the current implementation, which is quite brittle in many respects (e.g. it uses the `hasDescendant()` matcher to find the container that is being accessed, which is very easy to trick, as in the example in PR#52245). I have not been able to reproduce the second issue mentioned in PR#52245 (namely that using the `data()` member function is suggested even for containers that don't have it), but I've added a test case for it to be sure. Reviewed By: aaron.ballman Differential Revision: https://reviews.llvm.org/D113863
-
Philip Reames authored
-
Philip Reames authored
-
Craig Topper authored
Remove fshl/fshr with constant shift amount isel patterns. Replace with fsr/fsl with constant isel patterns. This hack was trying to preserve as much optimization opportunity for fshl/fshr by constant as possible, but the conversion to RISCVISD::FSR/FSL happens so late it probably isn't worth much. The new isel patterns are needed by D117468 anyway.
-
Joseph Huber authored
Reverting to investigate break on AMDGPU. This reverts commit 0203ff19.
-
Joseph Huber authored
Reverting to investigate break on AMDPGU. This reverts commit d081bfcd.
-
Casey Carter authored
MSVCSTL's are actually bidirectional. Differential Revision: https://reviews.llvm.org/D117369
-
Vladislav Khmelevsky authored
In case the case the DW_AT_ranges tag already exists for the object the low pc values won't be updated and will be incorrect in after-bolt binaries. Vladislav Khmelevsky, Advanced Software Technology Lab, Huawei Differential Revision: https://reviews.llvm.org/D117216
-
Casey Carter authored
... it's easier to suppress warnings internally, where we can detect the compiler. * Rename `TEST_COMPILER_C1XX` to `TEST_COMPILER_MSVC` * Rename all `TEST_WORKAROUND_C1XX_<meow>` to `TEST_WORKAROUND_MSVC_<meow>` Differential Revision: https://reviews.llvm.org/D117422
-
Mircea Trofin authored
Because CoroEarly is also run, the `coroutine.presplit` attr should be 0.
-
Nikolas Klauser authored
Use `_LIBCPP_DEBUG_ASSERT` in <unordered_map> Reviewed By: ldionne, Mordante, #libc Spies: libcxx-commits Differential Revision: https://reviews.llvm.org/D117401
-
Nikolas Klauser authored
Currently it is not checked that operator in_in_result<II1, II2>() SFINAEs away properly Reviewed By: ldionne, #libc Spies: libcxx-commits Differential Revision: https://reviews.llvm.org/D117517
-
Peter Klausler authored
Implements substring references into potentially partial CHARACTER scalars and array elements in NAMELIST input. Differential Revision: https://reviews.llvm.org/D117576
-
Alex Brachet authored
`T` is not a valid identifier for libc++ to use, use `_Tp` instead. Caught from D116957 Reviewed By: Quuxplusone Differential Revision: https://reviews.llvm.org/D117582
-
Amir Aupov authored
Matching an exact byte offset is fragile if a different version of compiler is used (e.g. distro clang). Resolves an issue with running with BOLT_CLANG_EXE + clang-12 Reviewed By: maksfb Differential Revision: https://reviews.llvm.org/D117440
-
Ellis Hoag authored
The `InstrProfInstBase` class is for all `llvm.instrprof.*` intrinsics. In a later diff we will add new instrinsic of this type. Also refactor some logic in `InstrProfiling.cpp`. Reviewed By: davidxl Differential Revision: https://reviews.llvm.org/D117261
-
Matt Arsenault authored
-
Adrian Tong authored
This is just a test commit to check whether I got commit permission.
-
Craig Topper authored
Recommit "[RISCV] Make the operand order for RISCVISD::FSL(W)/FSR(W) match the instruction register numbering." This reverts the revert commit e3283857. Accidental demanded bits change has been removed. The demanded bits code itself was remove in a pre-commit since it isn't tested. Original commit message: Previous we used the fshl/fshr operand ordering for simplicity. This made things confusing when D117468 proposed adding intrinsics for the instructions. We can't just use the generic funnel shifting intrinsics because fsl/fsr have different functionality that should be exposed to software. Now we use rs1, rs3, rs2/shamt order which matches the instruction printing order and the order used in this intrinsic header https://github.com/riscv/riscv-bitmanip/blob/main-history/cproofs/rvintrin.h
-
Craig Topper authored
Testing may be easier after D117468. Right now we get demanded bits optimizations done on ISD::FSHL/FSHR before they become FSR/FSL. This makes it hard to test.
-
Matt Arsenault authored
-
Matt Arsenault authored
This fixes a verifier error I ran into at -O0. A subregister copy had an implicit kill of an overlapping superregister, which was partially redefined by the copy. The preserved implicit operand killed subregisters made live earlier in the sequence. AMDGPU already uses similar logic for whether to preserve the kill of the superregister on the final instruction if there's overlap.
-