<feed xmlns='http://www.w3.org/2005/Atom'>
<title>llvm-project.git/llvm/lib/Transforms/Utils/GlobalStatus.cpp, 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>[LLVM] Don't peek through bitcast on pointers and gep with zero indices. NFC. (#102889)</title>
<updated>2024-08-13T14:38:50+00:00</updated>
<author>
<name>Yingwei Zheng</name>
<email>dtcxzyw2333@gmail.com</email>
</author>
<published>2024-08-13T14:38:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=f364b2ee22209e4072c39a153b3385806974f8b0'/>
<id>f364b2ee22209e4072c39a153b3385806974f8b0</id>
<content type='text'>
Since we are using opaque pointers now, we don't need to peek through
bitcast on pointers and gep with zero indices.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Since we are using opaque pointers now, we don't need to peek through
bitcast on pointers and gep with zero indices.</pre>
</div>
</content>
</entry>
<entry>
<title>GlobalOpt: Handle threadlocal.address intrinsic (#88454)</title>
<updated>2024-04-29T16:21:50+00:00</updated>
<author>
<name>Matthias Braun</name>
<email>matze@braunis.de</email>
</author>
<published>2024-04-29T16:21:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=dede19caf0da31d9b8b69d014602cde41ab9a96e'/>
<id>dede19caf0da31d9b8b69d014602cde41ab9a96e</id>
<content type='text'>
This changes `GlobalOpt` to skip/look-through `threadlocal.address`
intrinsic where apropriate.

This fixes issue #73314</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This changes `GlobalOpt` to skip/look-through `threadlocal.address`
intrinsic where apropriate.

This fixes issue #73314</pre>
</div>
</content>
</entry>
<entry>
<title>[GlobalOpt] Perform store-&gt;dominated load forwarding for stored once globals</title>
<updated>2022-06-24T16:09:26+00:00</updated>
<author>
<name>Arthur Eubanks</name>
<email>aeubanks@google.com</email>
</author>
<published>2022-06-18T21:14:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=e422c0d3b26eaf3e5646960351d4fe6ff7c0b573'/>
<id>e422c0d3b26eaf3e5646960351d4fe6ff7c0b573</id>
<content type='text'>
The initial land incorrectly optimized forwarding non-Constants in non-nosync/norecurse functions. Bail on non-Constants since norecurse should cause global -&gt; alloca promotion anyway.

The initial land also incorrectly assumed that StoredOnceStore was the only store to the global, but it actually means that only one value other than the global initializer is stored. Add a check that there's only one store.

Compile time tracker:
https://llvm-compile-time-tracker.com/compare.php?from=c80b88ee29f34078d2149de94e27600093e6c7c0&amp;to=ef2c2b7772424b6861a75e794f3c31b45167304a&amp;stat=instructions

Reviewed By: nikic, asbirlea, jdoerfert

Differential Revision: https://reviews.llvm.org/D128128
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The initial land incorrectly optimized forwarding non-Constants in non-nosync/norecurse functions. Bail on non-Constants since norecurse should cause global -&gt; alloca promotion anyway.

The initial land also incorrectly assumed that StoredOnceStore was the only store to the global, but it actually means that only one value other than the global initializer is stored. Add a check that there's only one store.

Compile time tracker:
https://llvm-compile-time-tracker.com/compare.php?from=c80b88ee29f34078d2149de94e27600093e6c7c0&amp;to=ef2c2b7772424b6861a75e794f3c31b45167304a&amp;stat=instructions

Reviewed By: nikic, asbirlea, jdoerfert

Differential Revision: https://reviews.llvm.org/D128128
</pre>
</div>
</content>
</entry>
<entry>
<title>[GlobalStatus] Keep Visited set in isSafeToDestroyConstant()</title>
<updated>2022-02-22T09:02:37+00:00</updated>
<author>
<name>Nikita Popov</name>
<email>npopov@redhat.com</email>
</author>
<published>2022-02-22T08:53:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=f8d72100323b127b39fed5f5890b86d81b8a0335'/>
<id>f8d72100323b127b39fed5f5890b86d81b8a0335</id>
<content type='text'>
Constants cannot be cyclic, but they can be tree-like. Keep a
visited set to ensure we do not degenerate to exponential run-time.

This fixes the problem reported in https://reviews.llvm.org/D117223#3335482,
though I haven't been able to construct a concise test case for
the issue. This requires a combination of dead constants and the
kind of constant expression tree that textual IR cannot represent
(because the textual representation, unlike the in-memory
representation, is also exponential in size).
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Constants cannot be cyclic, but they can be tree-like. Keep a
visited set to ensure we do not degenerate to exponential run-time.

This fixes the problem reported in https://reviews.llvm.org/D117223#3335482,
though I haven't been able to construct a concise test case for
the issue. This requires a combination of dead constants and the
kind of constant expression tree that textual IR cannot represent
(because the textual representation, unlike the in-memory
representation, is also exponential in size).
</pre>
</div>
</content>
</entry>
<entry>
<title>[GlobalStatus] Skip non-pointer dead constant users</title>
<updated>2022-02-01T14:51:32+00:00</updated>
<author>
<name>Nikita Popov</name>
<email>npopov@redhat.com</email>
</author>
<published>2022-02-01T14:49:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=236fbf571dc6cebcb81ac5187a170c8de6d5bc0e'/>
<id>236fbf571dc6cebcb81ac5187a170c8de6d5bc0e</id>
<content type='text'>
Constant expressions with a non-pointer result type used an early
exit that bypassed the later dead constant user check, and resulted
in different optimization outcomes depending on whether dead users
were present or not.

This fixes the issue reported in https://reviews.llvm.org/D117223#3287039.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Constant expressions with a non-pointer result type used an early
exit that bypassed the later dead constant user check, and resulted
in different optimization outcomes depending on whether dead users
were present or not.

This fixes the issue reported in https://reviews.llvm.org/D117223#3287039.
</pre>
</div>
</content>
</entry>
<entry>
<title>[GlobalStatus] Remove unused HasNonInstructionUser member (NFC)</title>
<updated>2022-01-12T08:40:54+00:00</updated>
<author>
<name>Nikita Popov</name>
<email>npopov@redhat.com</email>
</author>
<published>2022-01-12T08:40:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=47a47733f01f3e230c1aa6ab8844f86d67dc8e17'/>
<id>47a47733f01f3e230c1aa6ab8844f86d67dc8e17</id>
<content type='text'>
This hasn't been used in a long time.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This hasn't been used in a long time.
</pre>
</div>
</content>
</entry>
<entry>
<title>[GlobalStatus] Look through non-constexpr casts</title>
<updated>2022-01-11T15:02:35+00:00</updated>
<author>
<name>Nikita Popov</name>
<email>npopov@redhat.com</email>
</author>
<published>2022-01-11T15:00:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=94d62633914b8dcda2eac5c8e947172e0ddac93d'/>
<id>94d62633914b8dcda2eac5c8e947172e0ddac93d</id>
<content type='text'>
analyzeGlobal() looks through non-constexpr cast instructions when
looking for users. However, this particular place only strips the
casts again if they are constexprs. We should be looking through all
casts here.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
analyzeGlobal() looks through non-constexpr cast instructions when
looking for users. However, this particular place only strips the
casts again if they are constexprs. We should be looking through all
casts here.
</pre>
</div>
</content>
</entry>
<entry>
<title>Reapply "[GlobalOpt][FIX] Do not embed initializers into AS!=0 globals""</title>
<updated>2021-09-10T20:22:56+00:00</updated>
<author>
<name>Johannes Doerfert</name>
<email>johannes@jdoerfert.de</email>
</author>
<published>2021-09-10T18:44:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=c09fbbdcfb92c410ea85aee6d9ce976b6f78c4a4'/>
<id>c09fbbdcfb92c410ea85aee6d9ce976b6f78c4a4</id>
<content type='text'>
This reapplies commit 7dbba3376f633cabcf4df568bc9ca95f44a35203, or, put
differently, this reverts commit d9a8d20827dcddad831751bc38ff178e70f0b2f5.

The test now requires the amdgpu and nvptx backend explicitly as it
won't work without properly.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This reapplies commit 7dbba3376f633cabcf4df568bc9ca95f44a35203, or, put
differently, this reverts commit d9a8d20827dcddad831751bc38ff178e70f0b2f5.

The test now requires the amdgpu and nvptx backend explicitly as it
won't work without properly.
</pre>
</div>
</content>
</entry>
<entry>
<title>Revert "[GlobalOpt][FIX] Do not embed initializers into AS!=0 globals"</title>
<updated>2021-09-10T17:23:08+00:00</updated>
<author>
<name>Johannes Doerfert</name>
<email>johannes@jdoerfert.de</email>
</author>
<published>2021-09-10T17:23:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=d9a8d20827dcddad831751bc38ff178e70f0b2f5'/>
<id>d9a8d20827dcddad831751bc38ff178e70f0b2f5</id>
<content type='text'>
This reverts commit 7dbba3376f633cabcf4df568bc9ca95f44a35203.

There seems to be a problem with the tests, investigating now:
  https://lab.llvm.org/buildbot/#/builders/61/builds/14574
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This reverts commit 7dbba3376f633cabcf4df568bc9ca95f44a35203.

There seems to be a problem with the tests, investigating now:
  https://lab.llvm.org/buildbot/#/builders/61/builds/14574
</pre>
</div>
</content>
</entry>
<entry>
<title>[GlobalOpt][FIX] Do not embed initializers into AS!=0 globals</title>
<updated>2021-09-10T17:08:50+00:00</updated>
<author>
<name>Johannes Doerfert</name>
<email>johannes@jdoerfert.de</email>
</author>
<published>2021-09-02T19:12:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=7dbba3376f633cabcf4df568bc9ca95f44a35203'/>
<id>7dbba3376f633cabcf4df568bc9ca95f44a35203</id>
<content type='text'>
Not all address spaces support initializers for globals and we can
therefore not set them without checking if they are allowed. This
patch adds a hook into TTI to check if an AS allows non-undef
initializers. We disable it for all but address space 0 by default,
NVPTX and AMDGPU targets allow all but address space 3.

Reviewed By: tra

Differential Revision: https://reviews.llvm.org/D109337
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Not all address spaces support initializers for globals and we can
therefore not set them without checking if they are allowed. This
patch adds a hook into TTI to check if an AS allows non-undef
initializers. We disable it for all but address space 0 by default,
NVPTX and AMDGPU targets allow all but address space 3.

Reviewed By: tra

Differential Revision: https://reviews.llvm.org/D109337
</pre>
</div>
</content>
</entry>
</feed>
