<feed xmlns='http://www.w3.org/2005/Atom'>
<title>llvm-project.git/flang/lib/Optimizer/Transforms/FunctionAttr.cpp, branch users/mingmingl-llvm/samplefdo-profile-format</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>[IR][CodeGen] Remove "approx-func-fp-math" attribute (#155740)</title>
<updated>2025-08-29T01:52:07+00:00</updated>
<author>
<name>paperchalice</name>
<email>liujunchang97@outlook.com</email>
</author>
<published>2025-08-29T01:52:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=205d461a19f88be9b2044d7c863c747907181981'/>
<id>205d461a19f88be9b2044d7c863c747907181981</id>
<content type='text'>
Remove "approx-func-fp-math" attribute and related command line option,
users should always use afn flag in IR.
Resolve FIXME in `TargetMachine::resetTargetOptions` partially.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Remove "approx-func-fp-math" attribute and related command line option,
users should always use afn flag in IR.
Resolve FIXME in `TargetMachine::resetTargetOptions` partially.</pre>
</div>
</content>
</entry>
<entry>
<title>[flang] Add support for -mrecip[=&lt;list&gt;] (#143418)</title>
<updated>2025-06-10T14:25:33+00:00</updated>
<author>
<name>Cameron McInally</name>
<email>cameron.mcinally@nyu.edu</email>
</author>
<published>2025-06-10T14:25:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=cde1035a2fc6d472168ce6c6e117f16c76c5bbc4'/>
<id>cde1035a2fc6d472168ce6c6e117f16c76c5bbc4</id>
<content type='text'>
This patch adds support for the -mrecip command line option. The parsing
of this options is equivalent to Clang's and it is implemented by
setting the "reciprocal-estimates" function attribute.

Also move the ParseMRecip(...) function to CommonArgs, so that Flang is
able to make use of it as well.

---------

Co-authored-by: Cameron McInally &lt;cmcinally@nvidia.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch adds support for the -mrecip command line option. The parsing
of this options is equivalent to Clang's and it is implemented by
setting the "reciprocal-estimates" function attribute.

Also move the ParseMRecip(...) function to CommonArgs, so that Flang is
able to make use of it as well.

---------

Co-authored-by: Cameron McInally &lt;cmcinally@nvidia.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>[flang] Add support for -mprefer-vector-width=&lt;value&gt; (#142073)</title>
<updated>2025-05-30T13:50:18+00:00</updated>
<author>
<name>Cameron McInally</name>
<email>cameron.mcinally@nyu.edu</email>
</author>
<published>2025-05-30T13:50:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=ce9cef79ea3f1ee86e4dc674d4c05b2fa8b3c7a8'/>
<id>ce9cef79ea3f1ee86e4dc674d4c05b2fa8b3c7a8</id>
<content type='text'>
This patch adds support for the -mprefer-vector-width= command line
option. The parsing of this options is equivalent to Clang's and it is
implemented by setting the "prefer-vector-width" function attribute.

Co-authored-by: Cameron McInally &lt;cmcinally@nvidia.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch adds support for the -mprefer-vector-width= command line
option. The parsing of this options is equivalent to Clang's and it is
implemented by setting the "prefer-vector-width" function attribute.

Co-authored-by: Cameron McInally &lt;cmcinally@nvidia.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>Reland "[flang] Added noalias attribute to function arguments. (#140803)"</title>
<updated>2025-05-29T20:42:57+00:00</updated>
<author>
<name>Slava Zakharin</name>
<email>szakharin@nvidia.com</email>
</author>
<published>2025-05-29T00:18:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=a0d699a8e686cba99690cf28463d14526c5bfbc8'/>
<id>a0d699a8e686cba99690cf28463d14526c5bfbc8</id>
<content type='text'>
This helps to disambiguate accesses in the caller and the callee
after LLVM inlining in some apps. I did not see any performance
changes, but this is one step towards enabling other optimizations
in the apps that I am looking at.

The definition of llvm.noalias says:
```
... indicates that memory locations accessed via pointer values based on the argument or return value are not also accessed, during the execution of the function, via pointer values not based on the argument or return value. This guarantee only holds for memory locations that are modified, by any means, during the execution of the function.
```

I believe this exactly matches Fortran rules for the dummy arguments
that are modified during their subprogram execution.

I also set llvm.noalias and llvm.nocapture on the !fir.box&lt;&gt; arguments,
because the corresponding descriptors cannot be captured and cannot
alias anything (not based on them) during the execution of the
subprogram.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This helps to disambiguate accesses in the caller and the callee
after LLVM inlining in some apps. I did not see any performance
changes, but this is one step towards enabling other optimizations
in the apps that I am looking at.

The definition of llvm.noalias says:
```
... indicates that memory locations accessed via pointer values based on the argument or return value are not also accessed, during the execution of the function, via pointer values not based on the argument or return value. This guarantee only holds for memory locations that are modified, by any means, during the execution of the function.
```

I believe this exactly matches Fortran rules for the dummy arguments
that are modified during their subprogram execution.

I also set llvm.noalias and llvm.nocapture on the !fir.box&lt;&gt; arguments,
because the corresponding descriptors cannot be captured and cannot
alias anything (not based on them) during the execution of the
subprogram.
</pre>
</div>
</content>
</entry>
<entry>
<title>Revert "[flang] Added noalias attribute to function arguments." (#141884)</title>
<updated>2025-05-29T01:06:11+00:00</updated>
<author>
<name>Slava Zakharin</name>
<email>szakharin@nvidia.com</email>
</author>
<published>2025-05-29T01:06:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=6ee2453360e986c1258e83ce854919adf452b990'/>
<id>6ee2453360e986c1258e83ce854919adf452b990</id>
<content type='text'>
Reverts llvm/llvm-project#140803

Buildbot failure:
https://lab.llvm.org/buildbot/#/builders/143/builds/8041</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Reverts llvm/llvm-project#140803

Buildbot failure:
https://lab.llvm.org/buildbot/#/builders/143/builds/8041</pre>
</div>
</content>
</entry>
<entry>
<title>[flang] Added noalias attribute to function arguments. (#140803)</title>
<updated>2025-05-29T00:18:04+00:00</updated>
<author>
<name>Slava Zakharin</name>
<email>szakharin@nvidia.com</email>
</author>
<published>2025-05-29T00:18:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=2426ac686516c275b980e0ede3d9e75fa9df1150'/>
<id>2426ac686516c275b980e0ede3d9e75fa9df1150</id>
<content type='text'>
This helps to disambiguate accesses in the caller and the callee
after LLVM inlining in some apps. I did not see any performance
changes, but this is one step towards enabling other optimizations
in the apps that I am looking at.

The definition of llvm.noalias says:
```
... indicates that memory locations accessed via pointer values based on the argument or return value are not also accessed, during the execution of the function, via pointer values not based on the argument or return value. This guarantee only holds for memory locations that are modified, by any means, during the execution of the function.
```

I believe this exactly matches Fortran rules for the dummy arguments
that are modified during their subprogram execution.

I also set llvm.noalias and llvm.nocapture on the !fir.box&lt;&gt; arguments,
because the corresponding descriptors cannot be captured and cannot
alias anything (not based on them) during the execution of the
subprogram.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This helps to disambiguate accesses in the caller and the callee
after LLVM inlining in some apps. I did not see any performance
changes, but this is one step towards enabling other optimizations
in the apps that I am looking at.

The definition of llvm.noalias says:
```
... indicates that memory locations accessed via pointer values based on the argument or return value are not also accessed, during the execution of the function, via pointer values not based on the argument or return value. This guarantee only holds for memory locations that are modified, by any means, during the execution of the function.
```

I believe this exactly matches Fortran rules for the dummy arguments
that are modified during their subprogram execution.

I also set llvm.noalias and llvm.nocapture on the !fir.box&lt;&gt; arguments,
because the corresponding descriptors cannot be captured and cannot
alias anything (not based on them) during the execution of the
subprogram.</pre>
</div>
</content>
</entry>
<entry>
<title>[flang][flang-driver] Support  flag -finstrument-functions (#137996)</title>
<updated>2025-05-02T14:38:44+00:00</updated>
<author>
<name>Anchu Rajendran S</name>
<email>asudhaku@amd.com</email>
</author>
<published>2025-05-02T14:38:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=580da48a93ea3065cced426bb37df65a933c21f7'/>
<id>580da48a93ea3065cced426bb37df65a933c21f7</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>[flang] Apply nocapture attribute to dummy arguments (#116182)</title>
<updated>2024-11-28T06:39:26+00:00</updated>
<author>
<name>s-watanabe314</name>
<email>watanabe.shu-06@fujitsu.com</email>
</author>
<published>2024-11-28T06:39:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=f3cf24fcc46ab1b9612d7dcb55ec5f18ea2dc62f'/>
<id>f3cf24fcc46ab1b9612d7dcb55ec5f18ea2dc62f</id>
<content type='text'>
Apply llvm.nocapture attribute to dummy arguments that do not have the
target, asynchronous, volatile, or pointer attributes in a procedure
that is not a bind(c). This was discussed in


https://discourse.llvm.org/t/applying-the-nocapture-attribute-to-reference-passed-arguments-in-fortran-subroutines/81401</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Apply llvm.nocapture attribute to dummy arguments that do not have the
target, asynchronous, volatile, or pointer attributes in a procedure
that is not a bind(c). This was discussed in


https://discourse.llvm.org/t/applying-the-nocapture-attribute-to-reference-passed-arguments-in-fortran-subroutines/81401</pre>
</div>
</content>
</entry>
<entry>
<title>[flang][Transforms][NFC] reduce boilerplate in func attr pass (#94739)</title>
<updated>2024-06-10T09:43:56+00:00</updated>
<author>
<name>Tom Eccles</name>
<email>tom.eccles@arm.com</email>
</author>
<published>2024-06-10T09:43:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=a6129a56d3640e70198d91fc97b4fc65525cb59c'/>
<id>a6129a56d3640e70198d91fc97b4fc65525cb59c</id>
<content type='text'>
Use tablegen to automatically create the pass constructor.

The purpose of this pass is to add attributes to functions, so it
doesn't need to work on other top level operations.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Use tablegen to automatically create the pass constructor.

The purpose of this pass is to add attributes to functions, so it
doesn't need to work on other top level operations.</pre>
</div>
</content>
</entry>
<entry>
<title>[flang] Set fast math related function attributes for -Ofast/-ffast-math (#79301)</title>
<updated>2024-02-05T19:39:12+00:00</updated>
<author>
<name>Alex Bradbury</name>
<email>asb@igalia.com</email>
</author>
<published>2024-02-05T19:39:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=22544e2a54370a3c0b12765981c312f9ec04f1cc'/>
<id>22544e2a54370a3c0b12765981c312f9ec04f1cc</id>
<content type='text'>
The implemented logic matches the logic used for Clang in emitting these
attributes. Although it's hoped that function attributes won't be needed
in the future (vs using fast math flags in individual IR instructions),
there are codegen differences currently with/without these attributes,
as can be seen in issues like #79257 or by hacking Clang to avoid
producing these attributes and observing codegen changes.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The implemented logic matches the logic used for Clang in emitting these
attributes. Although it's hoped that function attributes won't be needed
in the future (vs using fast math flags in individual IR instructions),
there are codegen differences currently with/without these attributes,
as can be seen in issues like #79257 or by hacking Clang to avoid
producing these attributes and observing codegen changes.</pre>
</div>
</content>
</entry>
</feed>
