<feed xmlns='http://www.w3.org/2005/Atom'>
<title>llvm-project.git/llvm/test/Transforms/IndVarSimplify/loop-predication.ll, branch users/nico/python-2</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/'/>
<entry>
<title>[IndVarSimplify] Convert more tests to opaque pointers (NFC)</title>
<updated>2022-12-14T14:37:58+00:00</updated>
<author>
<name>Nikita Popov</name>
<email>npopov@redhat.com</email>
</author>
<published>2022-12-14T14:31:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=3ce360f15b5a790a5fd9dcab716bbed7b4d3a347'/>
<id>3ce360f15b5a790a5fd9dcab716bbed7b4d3a347</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>[NFC] Port all IndVarSimplify tests to `-passes=` syntax</title>
<updated>2022-12-07T19:22:09+00:00</updated>
<author>
<name>Roman Lebedev</name>
<email>lebedev.ri@gmail.com</email>
</author>
<published>2022-12-07T19:10:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=6017d9a628fc71e5679c0e80bf6e13c2d55e0a1b'/>
<id>6017d9a628fc71e5679c0e80bf6e13c2d55e0a1b</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Return "[SCEV] Use context to strengthen flags of BinOps"</title>
<updated>2022-08-16T07:12:36+00:00</updated>
<author>
<name>Max Kazantsev</name>
<email>mkazantsev@azul.com</email>
</author>
<published>2022-08-16T06:41:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=ebabd6bf1889d38660f5e00c8b2d3724f9ee7e4a'/>
<id>ebabd6bf1889d38660f5e00c8b2d3724f9ee7e4a</id>
<content type='text'>
This reverts commit 354fa0b48008eca701a110badd6974bf449df257.

Returning as is. The patch was reverted due to a miscompile, but
this patch is not causing it. This patch made it possible to infer
some nuw flags in code guarded by `false` condition, and then someone
else to managed to propagate the flag from dead code outside.

Returning the patch to be able to reproduce the issue.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This reverts commit 354fa0b48008eca701a110badd6974bf449df257.

Returning as is. The patch was reverted due to a miscompile, but
this patch is not causing it. This patch made it possible to infer
some nuw flags in code guarded by `false` condition, and then someone
else to managed to propagate the flag from dead code outside.

Returning the patch to be able to reproduce the issue.
</pre>
</div>
</content>
</entry>
<entry>
<title>Revert "[SCEV] Use context to strengthen flags of BinOps"</title>
<updated>2022-08-15T11:51:59+00:00</updated>
<author>
<name>Max Kazantsev</name>
<email>mkazantsev@azul.com</email>
</author>
<published>2022-08-15T11:51:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=354fa0b48008eca701a110badd6974bf449df257'/>
<id>354fa0b48008eca701a110badd6974bf449df257</id>
<content type='text'>
This reverts commit 34ae308c73e4d76dbdab25a6206d3fbc5ebafdf5.

Our internal testing found a miscompile. Not sure if it's caused by
this patch or it revealed something else. Reverting while investigating.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This reverts commit 34ae308c73e4d76dbdab25a6206d3fbc5ebafdf5.

Our internal testing found a miscompile. Not sure if it's caused by
this patch or it revealed something else. Reverting while investigating.
</pre>
</div>
</content>
</entry>
<entry>
<title>[SCEV] Use context to strengthen flags of BinOps</title>
<updated>2022-08-03T07:08:57+00:00</updated>
<author>
<name>Max Kazantsev</name>
<email>mkazantsev@azul.com</email>
</author>
<published>2022-08-03T06:10:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=34ae308c73e4d76dbdab25a6206d3fbc5ebafdf5'/>
<id>34ae308c73e4d76dbdab25a6206d3fbc5ebafdf5</id>
<content type='text'>
Sometimes SCEV cannot infer nuw/nsw from something as simple as
```
  len in [0, MAX_INT]
...
  iv = phi(0, iv.next)
  guard(iv &lt;s len)
  guard(iv &lt;u len)
  iv.next = iv + 1
```
just because flag strenthening only relies on definition and does not use local facts.
This patch adds support for the simplest case: inference of flags of `add(x, constant)`
if we can contextually prove that `x &lt;= max_int - constant`.

In case if it has negative CT impact, we can add an option to switch it off. I woudln't
expect that though.

Differential Revision: https://reviews.llvm.org/D129643
Reviewed By: apilipenko
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Sometimes SCEV cannot infer nuw/nsw from something as simple as
```
  len in [0, MAX_INT]
...
  iv = phi(0, iv.next)
  guard(iv &lt;s len)
  guard(iv &lt;u len)
  iv.next = iv + 1
```
just because flag strenthening only relies on definition and does not use local facts.
This patch adds support for the simplest case: inference of flags of `add(x, constant)`
if we can contextually prove that `x &lt;= max_int - constant`.

In case if it has negative CT impact, we can add an option to switch it off. I woudln't
expect that though.

Differential Revision: https://reviews.llvm.org/D129643
Reviewed By: apilipenko
</pre>
</div>
</content>
</entry>
<entry>
<title>[SCEV] Use umin_seq for BECount of multi-exit loops</title>
<updated>2022-05-21T13:48:14+00:00</updated>
<author>
<name>Nikita Popov</name>
<email>nikita.ppv@gmail.com</email>
</author>
<published>2022-05-21T13:39:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=c8b675eaa1de1d4edebd0292ca6de3180c687127'/>
<id>c8b675eaa1de1d4edebd0292ca6de3180c687127</id>
<content type='text'>
When computing the BECount for multi-exit loops, we need to combine
individual exit counts using umin_seq rather than umin. This is
because an earlier exit may exit on the first iteration, in which
case later exit expressions will not be evaluated and could be
poisonous. We cannot propagate potential poison values from later
exits.

In particular, this avoids the introduction of "branch on poison"
UB when optimizing multi-exit loops.

Differential Revision: https://reviews.llvm.org/D124910
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When computing the BECount for multi-exit loops, we need to combine
individual exit counts using umin_seq rather than umin. This is
because an earlier exit may exit on the first iteration, in which
case later exit expressions will not be evaluated and could be
poisonous. We cannot propagate potential poison values from later
exits.

In particular, this avoids the introduction of "branch on poison"
UB when optimizing multi-exit loops.

Differential Revision: https://reviews.llvm.org/D124910
</pre>
</div>
</content>
</entry>
<entry>
<title>[NFC][llvm] Inclusive language: reword uses of sanity test and check</title>
<updated>2021-11-25T12:21:42+00:00</updated>
<author>
<name>Zarko Todorovski</name>
<email>zarko@ca.ibm.com</email>
</author>
<published>2021-11-25T02:56:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=7f7dac712694ed661b2e774573b9ee1f99208882'/>
<id>7f7dac712694ed661b2e774573b9ee1f99208882</id>
<content type='text'>
Part of continuing work to use more inclusive language. Reworded uses
of sanity check and sanity test in llvm/test/
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Part of continuing work to use more inclusive language. Reworded uses
of sanity check and sanity test in llvm/test/
</pre>
</div>
</content>
</entry>
<entry>
<title>[NFCI] SCEVExpander: emit intrinsics for integral {u,s}{min,max} SCEV expressions</title>
<updated>2021-03-06T18:52:46+00:00</updated>
<author>
<name>Roman Lebedev</name>
<email>lebedev.ri@gmail.com</email>
</author>
<published>2021-02-26T13:48:58+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=b46c085d2b6d15873fb53718f0a70b3848e19e4a'/>
<id>b46c085d2b6d15873fb53718f0a70b3848e19e4a</id>
<content type='text'>
These intrinsics, not the icmp+select are the canonical form nowadays,
so we might as well directly emit them.

This should not cause any regressions, but if it does,
then then they would needed to be fixed regardless.

Note that this doesn't deal with `SCEVExpander::isHighCostExpansion()`,
but that is a pessimization, not a correctness issue.

Additionally, the non-intrinsic form has issues with undef,
see https://reviews.llvm.org/D88287#2587863
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
These intrinsics, not the icmp+select are the canonical form nowadays,
so we might as well directly emit them.

This should not cause any regressions, but if it does,
then then they would needed to be fixed regardless.

Note that this doesn't deal with `SCEVExpander::isHighCostExpansion()`,
but that is a pessimization, not a correctness issue.

Additionally, the non-intrinsic form has issues with undef,
see https://reviews.llvm.org/D88287#2587863
</pre>
</div>
</content>
</entry>
<entry>
<title>[IndVars] Eliminate loop exits with equivalent exit counts</title>
<updated>2019-10-20T23:38:02+00:00</updated>
<author>
<name>Philip Reames</name>
<email>listmail@philipreames.com</email>
</author>
<published>2019-10-20T23:38:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=8cbcd2f484a2bc6720d9fd66b71aeaf50a49bc70'/>
<id>8cbcd2f484a2bc6720d9fd66b71aeaf50a49bc70</id>
<content type='text'>
We can end up with two loop exits whose exit counts are equivalent, but whose textual representation is different and non-obvious. For the sub-case where we have a series of exits which dominate one another (common), eliminate any exits which would iterate *after* a previous exit on the exiting iteration.

As noted in the TODO being removed, I'd always thought this was a good idea, but I've now seen this in a real workload as well.

Interestingly, in review, Nikita pointed out there's let another oppurtunity to leverage SCEV's reasoning.  If we kept track of the min of dominanting exits so far, we could discharge exits with EC &gt;= MDE.  This is less powerful than the existing transform (since later exits aren't considered), but potentially more powerful for any case where SCEV can prove a &gt;= b, but neither a == b or a &gt; b.  I don't have an example to illustrate that oppurtunity, but won't be suprised if we find one and return to handle that case as well.  

Differential Revision: https://reviews.llvm.org/D69009

llvm-svn: 375379
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We can end up with two loop exits whose exit counts are equivalent, but whose textual representation is different and non-obvious. For the sub-case where we have a series of exits which dominate one another (common), eliminate any exits which would iterate *after* a previous exit on the exiting iteration.

As noted in the TODO being removed, I'd always thought this was a good idea, but I've now seen this in a real workload as well.

Interestingly, in review, Nikita pointed out there's let another oppurtunity to leverage SCEV's reasoning.  If we kept track of the min of dominanting exits so far, we could discharge exits with EC &gt;= MDE.  This is less powerful than the existing transform (since later exits aren't considered), but potentially more powerful for any case where SCEV can prove a &gt;= b, but neither a == b or a &gt; b.  I don't have an example to illustrate that oppurtunity, but won't be suprised if we find one and return to handle that case as well.  

Differential Revision: https://reviews.llvm.org/D69009

llvm-svn: 375379
</pre>
</div>
</content>
</entry>
<entry>
<title>Remove a stale comment, noted in post commit review for rL375038</title>
<updated>2019-10-16T20:27:10+00:00</updated>
<author>
<name>Philip Reames</name>
<email>listmail@philipreames.com</email>
</author>
<published>2019-10-16T20:27:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=ac77947315c5cf9a79b1aa5b813baaa2d018cbe3'/>
<id>ac77947315c5cf9a79b1aa5b813baaa2d018cbe3</id>
<content type='text'>
llvm-svn: 375040
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
llvm-svn: 375040
</pre>
</div>
</content>
</entry>
</feed>
