<feed xmlns='http://www.w3.org/2005/Atom'>
<title>llvm-project.git/llvm/test/Transforms/ScalarizeMaskedMemIntrin, 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][IR] Use splat syntax when printing Constant[Data]Vector. (#112548)</title>
<updated>2024-11-06T11:53:33+00:00</updated>
<author>
<name>Paul Walker</name>
<email>paul.walker@arm.com</email>
</author>
<published>2024-11-06T11:53:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=38fffa630ee80163dc65e759392ad29798905679'/>
<id>38fffa630ee80163dc65e759392ad29798905679</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>[ScalarizeMaskedMemIntr] Don't use a scalar mask on GPUs (#104842)</title>
<updated>2024-08-23T00:02:45+00:00</updated>
<author>
<name>Krzysztof Drewniak</name>
<email>Krzysztof.Drewniak@amd.com</email>
</author>
<published>2024-08-23T00:02:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=25d976b45cb5b3d222d3a9cd94caa8a54031bbb7'/>
<id>25d976b45cb5b3d222d3a9cd94caa8a54031bbb7</id>
<content type='text'>
ScalarizedMaskedMemIntr contains an optimization where the &lt;N x i1&gt; mask
is bitcast into an iN and then bit-tests with powers of two are used to
determine whether to load/store/... or not.

However, on machines with branch divergence (mainly GPUs), this is a
mis-optimization, since each i1 in the mask will be stored in a
condition register - that is, ecah of these "i1"s is likely to be a word
or two wide, making these bit operations counterproductive.

Therefore, amend this pass to skip the optimizaiton on targets that it
pessimizes.

Pre-commit tests #104645</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
ScalarizedMaskedMemIntr contains an optimization where the &lt;N x i1&gt; mask
is bitcast into an iN and then bit-tests with powers of two are used to
determine whether to load/store/... or not.

However, on machines with branch divergence (mainly GPUs), this is a
mis-optimization, since each i1 in the mask will be stored in a
condition register - that is, ecah of these "i1"s is likely to be a word
or two wide, making these bit operations counterproductive.

Therefore, amend this pass to skip the optimizaiton on targets that it
pessimizes.

Pre-commit tests #104645</pre>
</div>
</content>
</entry>
<entry>
<title>Pre-commit AMDGPU tests for masked load/store/scatter/gather (#104645)</title>
<updated>2024-08-19T19:52:21+00:00</updated>
<author>
<name>Krzysztof Drewniak</name>
<email>Krzysztof.Drewniak@amd.com</email>
</author>
<published>2024-08-19T19:52:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=1393aeb91e88381ced7512788761e42bde8fd1cc'/>
<id>1393aeb91e88381ced7512788761e42bde8fd1cc</id>
<content type='text'>
I'm planning to fix the masked operation scalarazer to not generate
suboptimal code on AMD GPUs and other SIMT machines, and so am adding
tests now.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
I'm planning to fix the masked operation scalarazer to not generate
suboptimal code on AMD GPUs and other SIMT machines, and so am adding
tests now.</pre>
</div>
</content>
</entry>
<entry>
<title>[ScalarizeMaskedMemIntr] Optimize splat non-constant masks (#104537)</title>
<updated>2024-08-16T21:24:25+00:00</updated>
<author>
<name>Krzysztof Drewniak</name>
<email>Krzysztof.Drewniak@amd.com</email>
</author>
<published>2024-08-16T21:24:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=70995a1a3379ed3c21b1c5da6723f04166cb0ae6'/>
<id>70995a1a3379ed3c21b1c5da6723f04166cb0ae6</id>
<content type='text'>
In cases (like the ones added in the tests) where the condition of a
masked load or store is a splat but not a constant (that is, a masked
operation is being used to implement patterns like "load if the current
lane is in-bounds, otherwise return 0"), optimize the 'scalarized' code
to perform an aligned vector load/store if the splat constant is true.

Additionally, take a few steps to preserve aliasing information and
names when nothing is scalarized while I'm here.

As motivation, some LLVM IR users will genatate masked load/store in
cases that map to this kind of predicated operation (where either the
vector is loaded/stored or it isn't) in order to take advantage of
hardware primitives, but on AMDGPU, where we don't have a masked load or
store, this pass would scalarize a load or store that was intended to be
- and can be - vectorized while also introducing expensive branches.

Fixes #104520

Pre-commit tests at #104527</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In cases (like the ones added in the tests) where the condition of a
masked load or store is a splat but not a constant (that is, a masked
operation is being used to implement patterns like "load if the current
lane is in-bounds, otherwise return 0"), optimize the 'scalarized' code
to perform an aligned vector load/store if the splat constant is true.

Additionally, take a few steps to preserve aliasing information and
names when nothing is scalarized while I'm here.

As motivation, some LLVM IR users will genatate masked load/store in
cases that map to this kind of predicated operation (where either the
vector is loaded/stored or it isn't) in order to take advantage of
hardware primitives, but on AMDGPU, where we don't have a masked load or
store, this pass would scalarize a load or store that was intended to be
- and can be - vectorized while also introducing expensive branches.

Fixes #104520

Pre-commit tests at #104527</pre>
</div>
</content>
</entry>
<entry>
<title>[ScalarizeMaskedMemIntr] Pre-commit tests for splat optimizations (#104527)</title>
<updated>2024-08-16T01:46:59+00:00</updated>
<author>
<name>Krzysztof Drewniak</name>
<email>Krzysztof.Drewniak@amd.com</email>
</author>
<published>2024-08-16T01:46:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=648f4d0658ab00cf1e95330c8811aaea9481a274'/>
<id>648f4d0658ab00cf1e95330c8811aaea9481a274</id>
<content type='text'>
Commit tests that track the current behavior when the mask argument to a
llvm.masked.load or llvm.masked.store is a splat of a con-constant value
(that is, it does nothing special).</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Commit tests that track the current behavior when the mask argument to a
llvm.masked.load or llvm.masked.store is a splat of a con-constant value
(that is, it does nothing special).</pre>
</div>
</content>
</entry>
<entry>
<title>[AArch64] NFC: Rename -force-streaming-compatible-sve to -force-streaming-compatible (#92774)</title>
<updated>2024-05-22T06:58:54+00:00</updated>
<author>
<name>Sander de Smalen</name>
<email>sander.desmalen@arm.com</email>
</author>
<published>2024-05-22T06:58:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=1015f51dd94a6154df7183004743e1a86e566858'/>
<id>1015f51dd94a6154df7183004743e1a86e566858</id>
<content type='text'>
The behaviour of the flag should be equivalent to
__arm_streaming_compatible.

At the moment, the name suggests that '-force-streaming-compatible-sve'
on its own (i.e. without specifying `+sve`) enables the compiler to use
the streaming-compatible subset of SVE instructions, but the semantics
merely are that the function can be called with either PSTATE.SM=0 or
PSTATE.SM=1.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The behaviour of the flag should be equivalent to
__arm_streaming_compatible.

At the moment, the name suggests that '-force-streaming-compatible-sve'
on its own (i.e. without specifying `+sve`) enables the compiler to use
the streaming-compatible subset of SVE instructions, but the semantics
merely are that the function can be called with either PSTATE.SM=0 or
PSTATE.SM=1.</pre>
</div>
</content>
</entry>
<entry>
<title>[Transforms] Convert tests to opaque pointers (NFC)</title>
<updated>2024-02-05T10:57:34+00:00</updated>
<author>
<name>Nikita Popov</name>
<email>npopov@redhat.com</email>
</author>
<published>2024-02-05T10:56:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=2d69827c5c754f0eca98e497ecf0e52ed54b4fd3'/>
<id>2d69827c5c754f0eca98e497ecf0e52ed54b4fd3</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>[ScalarizeMaskedMemIntrin] Add missing lit.local.cfg (NFC)</title>
<updated>2023-10-23T13:08:53+00:00</updated>
<author>
<name>Nikita Popov</name>
<email>npopov@redhat.com</email>
</author>
<published>2023-10-23T13:08:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=e3adc6a1f7ddba9475940205eb55f2258c71aa84'/>
<id>e3adc6a1f7ddba9475940205eb55f2258c71aa84</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>[AArch64] Allow SVE code generation for fixed-width vectors (#67122)</title>
<updated>2023-10-23T11:41:34+00:00</updated>
<author>
<name>Igor Kirillov</name>
<email>igor.kirillov@arm.com</email>
</author>
<published>2023-10-23T11:41:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=b507509f6a938f3eb74b39c381327841d9fa46b1'/>
<id>b507509f6a938f3eb74b39c381327841d9fa46b1</id>
<content type='text'>
This patch allows the generation of SVE code with masks that mimic Neon.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch allows the generation of SVE code with masks that mimic Neon.</pre>
</div>
</content>
</entry>
<entry>
<title>[ScalarizeMaskedMemIntrin] Use poison instead of undef as placeholder [NFC]</title>
<updated>2023-07-17T09:11:14+00:00</updated>
<author>
<name>Nuno Lopes</name>
<email>nuno.lopes@tecnico.ulisboa.pt</email>
</author>
<published>2023-07-17T09:11:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=68f1391a6281488ab52848abc7871b0212fc1dc5'/>
<id>68f1391a6281488ab52848abc7871b0212fc1dc5</id>
<content type='text'>
This is used for masked out lanes, that are replaced with the passthrough value
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This is used for masked out lanes, that are replaced with the passthrough value
</pre>
</div>
</content>
</entry>
</feed>
