Commit Graph

487602 Commits

Author SHA1 Message Date
Quentin Dian
4c36ecbe0e [InstCombine] Fix shift calculation in InstCombineCasts (#84027)
Fixes #84025.

(cherry picked from commit e96c0c1d5e0a9916098b1a31acb006ea6c1108fb)
2024-03-11 13:33:20 -07:00
Fangrui Song
e90bfdb4dd [test] Make two sanitize-coverage tests pass with glibc 2.39+
glibc 2.39 added `nonnull` attribute to most libio functions accepting a
`FILE*` parameter, including fprintf[1]. The -fsanitize=undefined mode
checks the argument to fprintf and has extra counters, not expected by
two tests. Specify -fno-sanitize=nonnull-attribute to make the two tests
pass.

Fix #82883

[1]: https://sourceware.org/git/?p=glibc.git;a=commit;h=64b1a44183a3094672ed304532bedb9acc707554

Pull Request: https://github.com/llvm/llvm-project/pull/84231

(cherry picked from commit c3acbf6bb06f9039f9850e18e0ae2f2adef63905)
2024-03-11 13:07:50 -07:00
Florian Hahn
bf45c3a079 [DSE] Delay deleting non-memory-defs until end of DSE. (#83411)
DSE uses BatchAA, which caches queries using pairs of MemoryLocations.
At the moment, DSE may remove instructions that are used as pointers in
cached MemoryLocations. If a new instruction used by a new MemoryLoation
and this instruction gets allocated at the same address as a previosuly
cached and then removed instruction, we may access an incorrect entry in
the cache.

To avoid this delay removing all instructions except MemoryDefs until
the end of DSE. This should avoid removing any values used in BatchAA's
cache.

Test case by @vporpo from
https://github.com/llvm/llvm-project/pull/83181.
(Test not precommitted because the results are non-determinstic - memset
only sometimes gets removed)

PR: https://github.com/llvm/llvm-project/pull/83411
(cherry picked from commit 10f5e983a9e3162a569cbebeb32168716e391340)
2024-03-11 12:53:04 -07:00
Paul Kirth
16ab0812d2 [clang][fat-lto-objects] Make module flags match non-FatLTO pipelines (#83159)
In addition to being rather hard to follow, there isn't a good reason
why FatLTO shouldn't just share the same code for setting module flags
for (Thin)LTO. This patch simplifies the logic and makes sure we use set
these flags in a consistent way, independent of FatLTO.

Additionally, we now test that output in the .llvm.lto section actually
matches the output from Full and Thin LTO compilation.

(cherry picked from commit 7d8b50aaab8e0f935e3cb1f3f397e98b9e3ee241)
2024-03-11 12:47:52 -07:00
Jon Roelofs
267d9b1a74 Allow .alt_entry symbols to pass the .cfi nesting check (#82268)
A symbol with an `N_ALT_ENTRY` attribute may be defined in the middle of
a subsection, so it is reasonable to opt them out of the
`.cfi_{start,end}proc` nesting check.

Fixes: https://github.com/llvm/llvm-project/issues/82261
(cherry picked from commit 5b91647e3f82c9747c42c3239b7d7f3ade4542a7)
2024-03-11 12:35:50 -07:00
YunQiang Su
340ba4588c MIPS: fix emitDirectiveCpsetup on N32 (#80534)
In gas, .cpsetup may expand to one of two code sequences (one is related to `__gnu_local_gp`), depending on -mno-shared and -msym32.
Since Clang doesn't support -mno-shared or -msym32, .cpsetup expands to one code sequence.
The N32 condition incorrectly leads to the incorrect `__gnu_local_gp` code sequence.

```
00000000 <t1>:
   0:   ffbc0008        sd      gp,8(sp)
   4:   3c1c0000        lui     gp,0x0
                        4: R_MIPS_HI16  __gnu_local_gp
   8:   279c0000        addiu   gp,gp,0
                        8: R_MIPS_LO16  __gnu_local_gp
```

Fixes: #52785
(cherry picked from commit 860b6edfa9b344fbf8c500c17158c8212ea87d1c)
2024-03-11 12:32:11 -07:00
Mark de Wever
439e6f81e7 [libc++][modules] Fixes naming inconsistency. (#83036)
The modules used is-standard-library and is-std-library. The latter is
the name used in the SG15 proposal,

Fixes: https://github.com/llvm/llvm-project/issues/82879
(cherry picked from commit b50bcc7ffb6ad6caa4c141a22915ab59f725b7ae)
2024-03-11 12:24:53 -07:00
Tom Stellard
2ad8fbdbca
Bump version to 18.1.2 (#84655) 2024-03-11 07:31:28 -07:00
Tom Stellard
dba2a75e9c Bump version to 18.1.1 2024-03-07 21:27:31 -08:00
Tobias Hieta
b92012c777 Remove RC suffix 2024-03-07 21:18:24 -08:00
YunQiang Su
461274b81d MIPS: Fix asm constraints "f" and "r" for softfloat (#79116)
This include 2 fixes:
        1. Disallow 'f' for softfloat.
        2. Allow 'r' for softfloat.

Currently, 'f' is accpeted by clang, then LLVM meets an internal error.

'r' is rejected by LLVM by: couldn't allocate input reg for constraint
'r'.

Fixes: #64241, #63632

---------

Co-authored-by: Fangrui Song <i@maskray.me>
(cherry picked from commit c88beb4112d5bbf07d76a615ab7f13ba2ba023e6)
2024-02-27 09:18:54 -08:00
yingopq
e2182a6b91 [Mips] Fix unable to handle inline assembly ends with compat-branch o… (#77291)
…n MIPS

Modify:
Add a global variable 'CurForbiddenSlotAttr' to save current
instruction's forbidden slot and whether set reorder. This is the
judgment condition for whether to add nop. We would add a couple of
'.set noreorder' and '.set reorder' to wrap the current instruction and
the next instruction.
Then we can get previous instruction`s forbidden slot attribute and
whether set reorder by 'CurForbiddenSlotAttr'.
If previous instruction has forbidden slot and .set reorder is active
and current instruction is CTI. Then emit a NOP after it.

Fix https://github.com/llvm/llvm-project/issues/61045.

Because https://reviews.llvm.org/D158589 was 'Needs Review' state, not
ending, so we commit pull request again.

(cherry picked from commit 96abee5eef31274415681018553e1d4a16dc16c9)
2024-02-27 09:17:42 -08:00
Philipp Tomsich
6d8f9290b6 [NFC][AArch64] fix whitespace in AArch64SchedNeoverseV1 (#81744)
One of the whitespace fixes didn't get added to the commit introducing
the Ampere1B model.
Clean it up.

(cherry picked from commit 3369e341288b3d9bb59827f9a2911ebf3d36408d)
2024-02-26 17:38:41 -08:00
Philipp Tomsich
f1978d19a4 [AArch64] Initial Ampere1B scheduling model (#81341)
The Ampere1B core is enabled with a new scheduling/pipeline model, as it
provides significant updates over the Ampere1 core; it reduces latencies
on many instructions, has some micro-ops reassigned between the XY and X
units, and provides modelling for the instructions added since Ampere1
and Ampere1A.

As this is the first model implementing the CSSC instructions, we update
the UnsupportedFeatures on all other models (that have CompleteModel
set).

Testcases are added under llvm-mca: these showed the FullFP16 feature
missing, so we are adding it in as part of this commit.

This *adds tests and additional fixes* compared to the reverted #81338.

(cherry picked from commit dd1897c6cb028bda7d4d541d1bb33965eccf0a68)
2024-02-26 17:38:41 -08:00
Philipp Tomsich
83283342c3 [AArch64] Add the Ampere1B core (#81297)
The Ampere1B is Ampere's third-generation core implementing a
superscalar, out-of-order microarchitecture with nested virtualization,
speculative side-channel mitigation and architectural support for
defense against ROP/JOP style software attacks.

Ampere1B is an ARMv8.7+ implementation, adding support for the FEAT
WFxT, FEAT CSSC, FEAT PAN3 and FEAT AFP extensions. It also includes all
features of the second-generation Ampere1A, such as the Memory Tagging
Extension and SM3/SM4 cryptography instructions.

(cherry picked from commit fbba818a78f591d89f25768ba31783714d526532)
2024-02-26 17:38:41 -08:00
Anatoly Trosinenko
b4b76bdbf1 [AArch64] Make +pauth enabled in Armv8.3-a by default (#78027)
Add AEK_PAUTH to ARMV8_3A in TargetParser and let it propagate to
ARMV8R, as it aligns with GCC defaults.

After adding AEK_PAUTH, several tests from TargetParserTest.cpp crashed
when trying to format an error message, thus update a format string in
AssertSameExtensionFlags to account for bitmask being pre-formatted as
std::string.

The CHECK-PAUTH* lines in aarch64-target-features.c are updated to
account for the fact that FEAT_PAUTH support and pac-ret can be enabled
independently and all four combinations are possible.

(cherry picked from commit a52eea66795018550e95c4b060165a7250899298)
2024-02-26 17:38:41 -08:00
cor3ntin
a7a74ece1d [Clang] Fixes to immediate-escalating functions (#82281)
* Consider that immediate escalating function can appear at global
scope, fixing a crash

* Lambda conversion to function pointer was sometimes not performed in
an immediate function context when it should be.

Fixes #82258

(cherry picked from commit baf6bd303bd58a521809d456dd9b179636982fc5)
2024-02-26 17:03:46 -08:00
Tom Stellard
4cc7a75aa6 [llvm-shlib] Change libLLVM-$MAJOR.so symlink to point to versioned SO (#82660)
This symlink was added in 91a384621e5b762d9c173ffd247cfeadd5f436a2 to
maintain backwards compatibility, but it needs to point to
libLLVM.so.$MAJOR.$MINOR rather than libLLVM.so. This works better for
distros that ship libLLVM.so and libLLVM.so.$MAJOR.$MINOR in separate
packages and also prevents mistakes like
libLLVM-19.so -> libLLVM.so -> libLLVM.so.18.1

Fixes #82647

(cherry picked from commit 10c48a772742b7afe665a815b7eba2047f17dc4b)
2024-02-26 16:57:21 -08:00
Dani
d1a1d7afb1
[llvm][AArch64] Do not inline a function with different signing scheme. (#80642) (#82743)
f the signing scheme is different that maybe the functions assumes
different behaviours and dangerous to inline them without analysing
them. This should be a rare case.
2024-02-26 15:13:43 -08:00
Wentao Zhang
9274829eb6 [clang][CodeGen] Keep processing the rest of AST after encountering unsupported MC/DC expressions (#82464)
Currently, upon seeing unsupported decisions (more than 6 conditions, or
split nesting), the post-visitor hook dataTraverseStmtPost() returns a
false. As a result, in the rest of tree even supported decisions will
be skipped as well. Like in the below code:

{ // CompoundStmt
  a && b;           // 1: BinaryOperator (supported)
  a && foo(b && c); // 2: BinaryOperator (not yet supported due to split
                    //                    nesting)
  a && b;           // 3: BinaryOperator (supported)
}

Decision 3 will not be processed at all. And only one "Decision" region
will be emitted. Compiler explorer example:
https://godbolt.org/z/Px61sesoo

We hope to process such cases and emit two "Decision" regions (1 and 3)
in the above example.

(cherry picked from commit d4bfca3b2e673789f7c278d46a199ae8910ddd37)
2024-02-26 15:09:20 -08:00
Daniel Martinez
c8b11e9300 Fix build on musl by including stdint.h (#81434)
openmp fails to build on musl since it lacks the defines for int32_t

Co-authored-by: Daniel Martinez <danielmartinez@cock.li>
(cherry picked from commit 45fe67dd61a6ac7df84d3a586e41c36a4767757f)
2024-02-26 13:55:13 -08:00
Yingwei Zheng
a5b2e43ff0 [FlattenCFG] Fix the miscompilation where phi nodes exist in the merge point (#81987)
When there are phi nodes in the merge point of the if-region, we cannot
do the merge.
Alive2: https://alive2.llvm.org/ce/z/DbgEan
Fixes #70900.

(cherry picked from commit f920b746ea818f1d21f317116cbb105e3e85979a)
2024-02-26 13:47:48 -08:00
Yingwei Zheng
3aea3d2fd3 [GVN] Drop nsw/nuw flags when replacing the result of a with.overflow intrinsic with a overflowing binary operator (#82935)
Alive2: https://alive2.llvm.org/ce/z/gyL7mn
Fixes https://github.com/llvm/llvm-project/issues/82884.

(cherry picked from commit 892b4beeac50920e630f10905b2916295e2eb6d8)
2024-02-26 13:43:35 -08:00
Jonas Paulsson
9d51bd1c24 [SystemZ] Use VT (not ArgVT) for SlotVT in LowerCall(). (#82475)
When an integer argument is promoted and *not* split (like i72 -> i128 on
a new machine with vector support), the SlotVT should be i128, which is
stored in VT - not ArgVT.

Fixes #81417

(cherry picked from commit 9c0e45d7f0e2202e16dbd9a7b9f462e2bcb741ae)
2024-02-26 13:36:40 -08:00
Jonas Paulsson
5393a050f0 [SystemZ] Require D12 for i128 accesses in isLegalAddressingMode() (#79221)
Machines with vector support handle i128 in vector registers and
therefore only have the small displacement available for memory
accesses. Update isLegalAddressingMode() to reflect this.

(cherry picked from commit 84dcf3d35b6ea8d8b6c34bc9cf21135863c47b8c)
2024-02-26 15:49:43 +00:00
h-vetinari
cd2ca7f3f9
fix links on clang 18.1.0rc release page (#82739)
Looking at the [release
notes](https://prereleases.llvm.org/18.1.0/rc3/tools/clang/docs/ReleaseNotes.html)
for clang 18.1.0rc, there's some broken links, and many issue numbers
mis-formatted with an extra colon. Aside from being used inconsistently
(with/without colon), I think it should be uncontroversial that `See
(#62707).` is better than `See (#62707:).`

CC @tstellar @AaronBallman

Co-authored-by: Aaron Ballman <aaron@aaronballman.com>
2024-02-26 15:06:56 +01:00
Wentao Zhang
95b6a7f2b3
Backport 0bf4f82 to release/18.x (#82571)
Manually cherry-pick 0bf4f82f661817c79bd538c82c99515837cf1cf8 (#80952)
and resolve conflicts

Closes #82570
2024-02-23 16:07:23 -08:00
Tacet
c65d48da92
[libc++] Add details about string annotations (#82730)
This commit adds information that only long strings are annotated, and
with all allocators by default.

To read why short string annotations are not turned on yet, read
comments in a related PR:
https://github.com/llvm/llvm-project/pull/79536

Upstreamed in: 7661ade5d1ac4fc8e1e2339b2476cb8e45c24641
Upstream PR: #80912

---------

Co-authored-by: Mark de Wever <zar-rpg@xs4all.nl>

Co-authored-by: Mark de Wever <zar-rpg@xs4all.nl>
2024-02-23 13:06:47 -08:00
Fangrui Song
4ba68ab9b4 [llvm-readobj,ELF] Support --decompress/-z (#82594)
When a section has the SHF_COMPRESSED flag, -p/-x dump the compressed
content by default. In GNU readelf, if --decompress/-z is specified,
-p/-x will dump the decompressed content. This patch implements the
option.

Close #82507

(cherry picked from commit 26d71d9ed56c4c23e6284dac7a9bdf603a5801f3)
2024-02-23 12:51:05 -08:00
Ulrich Weigand
7103145024 [docs][llvm-objcopy] Add missing formats (#81981)
Bring list of supported formats in docs back in sync with the code.

(cherry picked from commit bf471c915d14035a24ec027fb2bb0373cefdabe1)
2024-02-23 12:48:38 -08:00
Louis Dionne
9c434b4733 [libc++] Only include <setjmp.h> from the C library if it exists (#81887)
In 2cea1babef, we removed the <setjmp.h> header provided by libc++. However, we did not conditionally include the underlying <setjmp.h>
header only if the C library provides one, which we otherwise do consistently (see e.g. 647ddc08f4).

rdar://122978778
(cherry picked from commit d8278b682386f51dfba204849c624672a3df40c7)
2024-02-23 12:46:52 -08:00
Luke Lau
4195885b95 [Loads] Fix crash in isSafeToLoadUnconditionally with scalable accessed type (#82650)
This fixes #82606 by updating isSafeToLoadUnconditionally to handle
fixed sized loads from a scalable accessed type.

(cherry picked from commit b0edc1c45284586fdb12edd666f95d99f5f62b43)
2024-02-23 12:44:49 -08:00
Fangrui Song
1ea6a98142
ReleaseNotes: mention -mtls-dialect=desc (#82731) 2024-02-23 12:43:55 -08:00
Thomas Preud'homme
b9029ed005 Extend GCC workaround to GCC < 8.4 for llvm::iterator_range ctor (#82643)
GCC SFINAE error with decltype was fixed in commit
ac5e28911abdfb8d9bf6bea980223e199bbcf28d which made it into GCC 8.4.
Therefore adjust GCC version test accordingly.

(cherry picked from commit 7f71fa909a10be182b82b9dfaf0fade6eb84796c)
2024-02-22 21:08:58 +00:00
Tom Stellard
6c90f8dd54 Fix llvm-x86_64-debian-dylib buildbot
This was broken by 91a384621e5b762d9c173ffd247cfeadd5f436a2.

(cherry picked from commit ff4d6c64ee4269e4a9b67a4dae7e0b82ae1c3419)
2024-02-20 21:14:50 -08:00
Tom Stellard
235306ba1f [cmake] Add minor version to library SONAME (#79376)
We need to do this now that we are bumping the minor release number when
we create the release branch.

This also results in a slight change to the library names for LLVM. The
main library now has a more convential library name:
'libLLVM.so.$major.$minor'. The old library name: libLLVM-$major.so is
now a symlink that points to the new library. However, the symlink is
not present in the build directory. It is only present in the install
directory.

The library name was changed because it helped to keep the CMake changes
more simple.

Fixes #76273

(cherry picked from commit 91a384621e5b762d9c173ffd247cfeadd5f436a2)
2024-02-20 21:14:50 -08:00
Tom Stellard
d84c1e9474 [workflows] Fix permissions check for creating new releases (#81163)
The default GitHub token does not have read permissions on the org, so
we need to use a custom token in order to read the members of the
llvm-release-managers team.

(cherry picked from commit 2836d8edbfbcd461b25101ed58f93c862d65903a)
2024-02-20 21:10:59 -08:00
Rainer Orth
bba39443eb [Release] Don't build during test-release.sh Phase 3 install (#82001)
As described in [test-release.sh ninja install does builds in Phase
3](https://github.com/llvm/llvm-project/issues/80999), considerable
parts of Phase 3 of a `test-release.sh` build are run by `ninja
install`, ignoring both `$Verbose` and the parallelism set via `-j NUM`.

This patches fixes this by not specifying any explicit build target for
Phase 3, thus running the full build as usual.

Tested on `sparc64-unknown-linux-gnu`.

(cherry picked from commit f6ac598c104ed3c9f4bcbbe830f86500c8d1013e)
2024-02-20 17:57:11 -08:00
Nikita Popov
94dcc1d6ae [IndVarSimplify] Fix poison-safety when reusing instructions (#80458)
IndVars may replace an instruction with one of its operands, if they
have the same SCEV expression. However, such a replacement may be more
poisonous.

First, check whether the operand being poison implies that the
instruction is also poison, in which case the replacement is always
safe. If this fails, check whether SCEV can determine that reusing the
instruction is safe, using the same check as SCEVExpander.

Fixes https://github.com/llvm/llvm-project/issues/79861.

(cherry picked from commit 7d2b6f0b355bc98bbe3aa5bae83316a708da33ee)
2024-02-20 16:44:46 -08:00
Nikita Popov
dc0ed54ac5 [SCEV] Move canReuseInstruction() helper into SCEV (NFC)
To allow reusing it in IndVars.

(cherry picked from commit 43dd1e84df1ecdad872e1004af47b489e08fc228)
2024-02-20 16:44:46 -08:00
Nikita Popov
4223b2264c [SCEVExpander] Do not reuse disjoint or (#80281)
SCEV treats "or disjoint" the same as "add nsw nuw". However, when
expanding, we cannot generally replace an add SCEV node with an "or
disjoint" instruction. Just dropping the poison flag is insufficient in
this case, we would have to actually convert the or into an add.

This is a partial fix for #79861.

(cherry picked from commit 5b8e1a6ebf11b6e93bcc96a0d009febe4bb3d7bc)
2024-02-20 16:44:46 -08:00
Nikita Popov
688566b2df [IndVars] Add tests for #79861 (NFC)
(cherry picked from commit c105848fd29d3b46eeb794bb6b10dad04f903b09)
2024-02-20 16:44:46 -08:00
Chuanqi Xu
66351a501e [Serialization] Record whether the ODR is skipped (#82302)
Close https://github.com/llvm/llvm-project/issues/80570.

In

a0b6747804,
we skipped ODR checks for decls in GMF. Then it should be natural to
skip storing the ODR values in BMI.

Generally it should be fine as long as the writer and the reader keep
consistent.

However, the use of preamble in clangd shows the tricky part.

For,

```
// test.cpp
module;

// any one off these is enough to crash clangd
// #include <iostream>
// #include <string_view>
// #include <cmath>
// #include <system_error>
// #include <new>
// #include <bit>
// probably many more

// only ok with libc++, not the system provided libstdc++ 13.2.1

// these are ok

export module test;
```

clangd will store the headers as preamble to speedup the parsing and the
preamble reuses the serialization techniques. (Generally we'd call the
preamble as PCH. However it is not true strictly. I've tested the PCH
wouldn't be problematic.) However, the tricky part is that the preamble
is not modules. It literally serialiaze and deserialize things. So
before clangd parsing the above test module, clangd will serialize the
headers into the preamble. Note that there is no concept like GMF now.
So the ODR bits are stored. However, when clangd parse the file
actually, the decls from preamble are thought as in GMF literally, then
hte ODR bits are skipped. Then mismatch happens.

To solve the problem, this patch adds another bit for decls to record
whether or not the ODR bits are skipped.

(cherry picked from commit 49775b1dc0cdb3a9d18811f67f268e3b3a381669)
2024-02-20 16:41:33 -08:00
Ulrich Weigand
5ef297ab61 [llvm-objcopy] Add SystemZ support (#81841)
This is also necessary for enabling ClangBuiltLinux:
https://github.com/ClangBuiltLinux/linux/issues/1530

(cherry picked from commit 3c02cb7492fc78fb678264cebf57ff88e478e14f)
2024-02-20 16:36:39 -08:00
David CARLIER
390dcd4cbb [compiler-rt][profile] Fix InstrProfilingFile possible resource leak. (#81363)
close #79708

(cherry picked from commit 0a255fcf4a90f9e864ae9321b28e4956f7c865fb)
2024-02-20 12:59:02 -08:00
Qiu Chaofan
3b4b047642 [PowerPC] Mask constant operands in ValueBit tracking (#67653)
In IR or C code, shift amount larger than value size is undefined
behavior. But in practice, backend lowering for shift_parts produces
add/sub of shift amounts, thus constant shift amounts might be
negative or larger than value size, which depends on ISA definition.

PowerPC ISA says, the lowest 7 bits (6 bits for 32-bit instruction)
will be taken, and if the highest among them is 1, result will be
zero, otherwise the low 6 bits (or 5 on 32-bit) are used as shift
amount.

This commit emulates the behavior and avoids array overflow in bit
permutation's value bits calculator.

(cherry picked from commit 292d9e869fcfc2ece694848db4022b0b939847e3)
2024-02-20 12:54:33 -08:00
Frederic Cambus
12114d2d5a [llvm-objdump] Add support for the PT_OPENBSD_SYSCALLS segment type. (#82121)
Reference: https://github.com/openbsd/src/blob/master/sys/sys/exec_elf.h
(cherry picked from commit 1b894864862d8049e4a2567a472efdc2eda1e035)
2024-02-20 11:59:21 -08:00
Frederic Cambus
3af6881cab [llvm-readobj] Add support for the PT_OPENBSD_SYSCALLS segment type. (#82122)
Reference: https://github.com/openbsd/src/blob/master/sys/sys/exec_elf.h
(cherry picked from commit a8d7511811c7d7c689c3e8f858e8e00a56aba152)
2024-02-20 11:57:09 -08:00
Xing Xue
801a10d305 [OpenMP][AIX]Add assembly file containing microtasking routines and unnamed common block definitions (#81770)
This patch adds assembly file `z_AIX_asm.S` that contains the 32- and
64-bit XCOFF version of microtasking routines and unnamed common block
definitions. This code has been run through the libomp LIT tests and a
user package successfully.

(cherry picked from commit 94100bc2fb1a39dbeb43d18a95176097c53f1324)
2024-02-20 11:54:09 -08:00
Nikita Popov
ebc589e44f [InstCombine] Fold gep of exact unsigned division (#82334)
Extend the transform added in
https://github.com/llvm/llvm-project/pull/76458 to also handle unsigned
division. X exact/ Y * Y == X holds independently of whether the
division is signed or unsigned.

Proofs: https://alive2.llvm.org/ce/z/wFd5Ec
(cherry picked from commit 26d4afc3de86ca5416c8e38000362c526b6808cd)
2024-02-20 12:02:48 +00:00