diff options
author | Datta Nagraj <datta.nagraj@gmail.com> | 2021-06-23 11:18:25 -0400 |
---|---|---|
committer | Sanjay Patel <spatel@rotateright.com> | 2021-06-23 11:19:12 -0400 |
commit | ad0085d3381a28041244fe6847f6ac1ce8dd052e (patch) | |
tree | 60064ec1c4b38eeb94874ea81287004df995dd83 /llvm/lib/Demangle/RustDemangle.cpp | |
parent | 38b7b1d4a2930cc82e69a8069fad4b363f73a212 (diff) | |
download | llvm-ad0085d3381a28041244fe6847f6ac1ce8dd052e.zip llvm-ad0085d3381a28041244fe6847f6ac1ce8dd052e.tar.gz llvm-ad0085d3381a28041244fe6847f6ac1ce8dd052e.tar.bz2 |
[InstCombine] Eliminate casts to optimize ctlz operation
If a ctlz operation is performed on higher datatype and then
downcasted, then this can be optimized by doing a ctlz operation
on a lower datatype and adding the difference bitsize to the result
of ctlz to provide the same output:
https://alive2.llvm.org/ce/z/8uup9M
The original problem is shown in
https://llvm.org/PR50173
Differential Revision: https://reviews.llvm.org/D103788
Diffstat (limited to 'llvm/lib/Demangle/RustDemangle.cpp')
0 files changed, 0 insertions, 0 deletions