<feed xmlns='http://www.w3.org/2005/Atom'>
<title>llvm-project.git/flang-rt/lib/runtime/extensions.cpp, branch main</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>[flang] Implement FNUM() (#159433)</title>
<updated>2025-09-19T15:09:39+00:00</updated>
<author>
<name>Peter Klausler</name>
<email>pklausler@nvidia.com</email>
</author>
<published>2025-09-19T15:09:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=80fa3bddd0dfd5c1ed4301033e5647a3c7f226ee'/>
<id>80fa3bddd0dfd5c1ed4301033e5647a3c7f226ee</id>
<content type='text'>
The GNU Fortran library function FNUM(u) returns the UNIX file
descriptor that corresponds to an open Fortran unit number, if any;
otherwise -1.

This implementation is a library extension only, not an intrinsic.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The GNU Fortran library function FNUM(u) returns the UNIX file
descriptor that corresponds to an open Fortran unit number, if any;
otherwise -1.

This implementation is a library extension only, not an intrinsic.</pre>
</div>
</content>
</entry>
<entry>
<title>[flang] Implement DSECNDS intrinsic (PGI extension) (#157573)</title>
<updated>2025-09-14T16:30:31+00:00</updated>
<author>
<name>Šárka Holendová</name>
<email>72979252+mlir-maiden@users.noreply.github.com</email>
</author>
<published>2025-09-14T16:30:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=3e254ed9041530cf14594f33f6c87a37c8a96640'/>
<id>3e254ed9041530cf14594f33f6c87a37c8a96640</id>
<content type='text'>
Add support for DSECNDS, the double-precision variant of SECNDS. 
The implementation mirrors SECNDS, reusing the shared `SecndsImpl&lt;T&gt;`
runtime template.
Includes:
- Registration in intrinsics table
- Lowering handler and runtime call wiring
- Hook into shared SecndsImpl in extensions.cpp
- Documentation in Intrinsics.md
- Regression test dsecnds.f90

CC @eugeneepshteyn @klausler

---------

Co-authored-by: Eugene Epshteyn &lt;eepshteyn@nvidia.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add support for DSECNDS, the double-precision variant of SECNDS. 
The implementation mirrors SECNDS, reusing the shared `SecndsImpl&lt;T&gt;`
runtime template.
Includes:
- Registration in intrinsics table
- Lowering handler and runtime call wiring
- Hook into shared SecndsImpl in extensions.cpp
- Documentation in Intrinsics.md
- Regression test dsecnds.f90

CC @eugeneepshteyn @klausler

---------

Co-authored-by: Eugene Epshteyn &lt;eepshteyn@nvidia.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>[Flang][OpenMP][Runtime] Minor Flang runtime for OpenMP AMDGPU modifications (#152631)</title>
<updated>2025-08-29T21:04:48+00:00</updated>
<author>
<name>agozillon</name>
<email>Andrew.Gozillon@amd.com</email>
</author>
<published>2025-08-29T21:04:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=30d2cb5a7ecd34cf19843533681a53aa7bd8d351'/>
<id>30d2cb5a7ecd34cf19843533681a53aa7bd8d351</id>
<content type='text'>
We have some modifications downstream to compile the flang runtime for
amdgpu using clang OpenMP, some more hacky than others to workaround
(hopefully temporary) compiler issues. The additions here are the
non-hacky alterations.

Main changes:
* Create freestanding versions of memcpy, strlen and memmove, and
replace std:: references with these so that we can default to std:: when
it's available, or our own Flang implementation when it's not. * Wrap
more bits and pieces of the library in declare target wrappers (RT_*
macros). * Fix some warnings that'll pose issues with werror on, in this
case having the namespace infront of variables passed to templates.

Another minor issues that'll likely still pop up depending on the
program you're linking with is that abort will be undefined, it is
perhaps possible to solve it with a freestanding implementation as with
memcpy etc. but we end up with multiple definitions in this case. An
alternative is to create an empty extern "c" version (which can be empty
or forwrd on to the builtin).

Co-author: Dan Palermo Dan.Palermo@amd.com</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We have some modifications downstream to compile the flang runtime for
amdgpu using clang OpenMP, some more hacky than others to workaround
(hopefully temporary) compiler issues. The additions here are the
non-hacky alterations.

Main changes:
* Create freestanding versions of memcpy, strlen and memmove, and
replace std:: references with these so that we can default to std:: when
it's available, or our own Flang implementation when it's not. * Wrap
more bits and pieces of the library in declare target wrappers (RT_*
macros). * Fix some warnings that'll pose issues with werror on, in this
case having the namespace infront of variables passed to templates.

Another minor issues that'll likely still pop up depending on the
program you're linking with is that abort will be undefined, it is
perhaps possible to solve it with a freestanding implementation as with
memcpy etc. but we end up with multiple definitions in this case. An
alternative is to create an empty extern "c" version (which can be empty
or forwrd on to the builtin).

Co-author: Dan Palermo Dan.Palermo@amd.com</pre>
</div>
</content>
</entry>
<entry>
<title>[flang-rt] Runtime implementation of extended intrinsic function SECNDS() (#152021)</title>
<updated>2025-08-06T20:02:27+00:00</updated>
<author>
<name>Eugene Epshteyn</name>
<email>eepshteyn@nvidia.com</email>
</author>
<published>2025-08-06T20:02:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=cae7bebcaa41e4c459e973b9688215f5a57bcb56'/>
<id>cae7bebcaa41e4c459e973b9688215f5a57bcb56</id>
<content type='text'>
Until the compiler part is fully hooked up via
https://github.com/llvm/llvm-project/pull/151878, tested this using
`external`:
```
external secnds
real s1, s2
s1 = secnds(0.0)
print *, "Seconds from midnight:", s1
call sleep(2)
s2 = secnds(s1)
print *, "Seconds from s1", s2
print *, "Seconds from midnight:", secnds(0.0)
end
```</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Until the compiler part is fully hooked up via
https://github.com/llvm/llvm-project/pull/151878, tested this using
`external`:
```
external secnds
real s1, s2
s1 = secnds(0.0)
print *, "Seconds from midnight:", s1
call sleep(2)
s2 = secnds(s1)
print *, "Seconds from s1", s2
print *, "Seconds from midnight:", secnds(0.0)
end
```</pre>
</div>
</content>
</entry>
<entry>
<title>[flang][runtime] MCLOCK library routine (#148960)</title>
<updated>2025-07-16T16:10:07+00:00</updated>
<author>
<name>Peter Klausler</name>
<email>pklausler@nvidia.com</email>
</author>
<published>2025-07-16T16:10:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=bbcdad1f8eab303a9d56c76a0bced7b17c6d2656'/>
<id>bbcdad1f8eab303a9d56c76a0bced7b17c6d2656</id>
<content type='text'>
Add MCLOCK as an interface to std::clock().</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add MCLOCK as an interface to std::clock().</pre>
</div>
</content>
</entry>
<entry>
<title>[flang] Implement external routine usage of hostnm() (#134900)</title>
<updated>2025-04-15T23:04:59+00:00</updated>
<author>
<name>Eugene Epshteyn</name>
<email>eepshteyn@nvidia.com</email>
</author>
<published>2025-04-15T23:04:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=3428cc94c893f9a09728c707baf018b9cdfaf243'/>
<id>3428cc94c893f9a09728c707baf018b9cdfaf243</id>
<content type='text'>
Previously, `hostnm` extended intrinsic was implemented as proper
intrinsic. Since then we found out that some applications use `hostnm`
as external routine via `external hostnm`. This prevents `hostnm` from
being recognized as an intrinsic. This PR implements `hostnm` as
external routine.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Previously, `hostnm` extended intrinsic was implemented as proper
intrinsic. Since then we found out that some applications use `hostnm`
as external routine via `external hostnm`. This prevents `hostnm` from
being recognized as an intrinsic. This PR implements `hostnm` as
external routine.</pre>
</div>
</content>
</entry>
<entry>
<title>[flang] Implement FSEEK and FTELL (#133003)</title>
<updated>2025-04-04T15:40:51+00:00</updated>
<author>
<name>Peter Klausler</name>
<email>pklausler@nvidia.com</email>
</author>
<published>2025-04-04T15:40:51+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=c8bde44cfcc75a8389f1a72917e0aadc125f5e22'/>
<id>c8bde44cfcc75a8389f1a72917e0aadc125f5e22</id>
<content type='text'>
Add function and subroutine forms of FSEEK and FTELL as intrinsic
procedures. Accept common aliases from legacy compilers as well.
    
A separate patch to llvm-test-suite will enable tests for these
procedures once this patch has merged.
    
Depends on https://github.com/llvm/llvm-project/pull/132423; CI builds
will likely fail until that patch is merged and this PR is rebased.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add function and subroutine forms of FSEEK and FTELL as intrinsic
procedures. Accept common aliases from legacy compilers as well.
    
A separate patch to llvm-test-suite will enable tests for these
procedures once this patch has merged.
    
Depends on https://github.com/llvm/llvm-project/pull/132423; CI builds
will likely fail until that patch is merged and this PR is rebased.</pre>
</div>
</content>
</entry>
<entry>
<title>[flang][intrinsics] Implement the time intrinsic (#133823)</title>
<updated>2025-04-03T22:33:40+00:00</updated>
<author>
<name>Andre Kuhlenschmidt</name>
<email>andre.kuhlenschmidt@gmail.com</email>
</author>
<published>2025-04-03T22:33:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=b11eece1bb582fa1d06ca61e210f9741e0a357b7'/>
<id>b11eece1bb582fa1d06ca61e210f9741e0a357b7</id>
<content type='text'>
This PR implements the nonstandard intrinsic time.

In addition to running the unit tests, I also double checked that the
example code works by manually compiling and running it.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This PR implements the nonstandard intrinsic time.

In addition to running the unit tests, I also double checked that the
example code works by manually compiling and running it.</pre>
</div>
</content>
</entry>
<entry>
<title>[flang/flang-rt] Implement PERROR intrinsic form GNU Extension (#132406)</title>
<updated>2025-04-01T13:47:54+00:00</updated>
<author>
<name>Jean-Didier PAILLEUX</name>
<email>jean-didier.pailleux@sipearl.com</email>
</author>
<published>2025-04-01T13:47:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=513a91a5f155746c7323a555a6e5ad0505627ca7'/>
<id>513a91a5f155746c7323a555a6e5ad0505627ca7</id>
<content type='text'>
Add the implementation of the `PERROR(STRING) ` intrinsic from the GNU
Extension to prints on the stderr a newline-terminated error message
corresponding to the last system error prefixed by `STRING`.
(https://gcc.gnu.org/onlinedocs/gfortran/PERROR.html)</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add the implementation of the `PERROR(STRING) ` intrinsic from the GNU
Extension to prints on the stderr a newline-terminated error message
corresponding to the last system error prefixed by `STRING`.
(https://gcc.gnu.org/onlinedocs/gfortran/PERROR.html)</pre>
</div>
</content>
</entry>
<entry>
<title>[flang] add QSORT extension intrinsic to the runtime (#132033)</title>
<updated>2025-03-19T15:14:37+00:00</updated>
<author>
<name>jeanPerier</name>
<email>jperier@nvidia.com</email>
</author>
<published>2025-03-19T15:14:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=cd0a2a3f1bdaf8dc54d4a4d3c478d41345671e72'/>
<id>cd0a2a3f1bdaf8dc54d4a4d3c478d41345671e72</id>
<content type='text'>
Add support for legacy Fortran intrinsic QSORT from lib 3f.
This is a thin Fortran wrapper over libc qsort.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add support for legacy Fortran intrinsic QSORT from lib 3f.
This is a thin Fortran wrapper over libc qsort.</pre>
</div>
</content>
</entry>
</feed>
