|
Revision tags: llvmorg-20.1.0, llvmorg-20.1.0-rc3, llvmorg-20.1.0-rc2, llvmorg-20.1.0-rc1, llvmorg-21-init, llvmorg-19.1.7, llvmorg-19.1.6, llvmorg-19.1.5, llvmorg-19.1.4, llvmorg-19.1.3, llvmorg-19.1.2, llvmorg-19.1.1, llvmorg-19.1.0, llvmorg-19.1.0-rc4, llvmorg-19.1.0-rc3, llvmorg-19.1.0-rc2, llvmorg-19.1.0-rc1, llvmorg-20-init, llvmorg-18.1.8, llvmorg-18.1.7, llvmorg-18.1.6, llvmorg-18.1.5, llvmorg-18.1.4, llvmorg-18.1.3, llvmorg-18.1.2, llvmorg-18.1.1, llvmorg-18.1.0, llvmorg-18.1.0-rc4, llvmorg-18.1.0-rc3, llvmorg-18.1.0-rc2, llvmorg-18.1.0-rc1, llvmorg-19-init, llvmorg-17.0.6, llvmorg-17.0.5, llvmorg-17.0.4, llvmorg-17.0.3, llvmorg-17.0.2, llvmorg-17.0.1, llvmorg-17.0.0, llvmorg-17.0.0-rc4, llvmorg-17.0.0-rc3, llvmorg-17.0.0-rc2, llvmorg-17.0.0-rc1, llvmorg-18-init, llvmorg-16.0.6, llvmorg-16.0.5, llvmorg-16.0.4, llvmorg-16.0.3, llvmorg-16.0.2, llvmorg-16.0.1, llvmorg-16.0.0, llvmorg-16.0.0-rc4, llvmorg-16.0.0-rc3, llvmorg-16.0.0-rc2, llvmorg-16.0.0-rc1, llvmorg-17-init, llvmorg-15.0.7, llvmorg-15.0.6, llvmorg-15.0.5, llvmorg-15.0.4, llvmorg-15.0.3, llvmorg-15.0.2, llvmorg-15.0.1, llvmorg-15.0.0, llvmorg-15.0.0-rc3, llvmorg-15.0.0-rc2, llvmorg-15.0.0-rc1, llvmorg-16-init |
|
| #
cb193931 |
| 08-Jul-2022 |
Peter Klausler <[email protected]> |
[flang][runtime] Complete list-directed character input with DECIMAL='COMMA'
Most of the infrastructure for DECIMAL='COMMA' mode was in place in the I/O runtime support library, but I dropped the ba
[flang][runtime] Complete list-directed character input with DECIMAL='COMMA'
Most of the infrastructure for DECIMAL='COMMA' mode was in place in the I/O runtime support library, but I dropped the ball for list-directed character input, which has its own detection of input separators. Finish the job.
Differential Revision: https://reviews.llvm.org/D129679
show more ...
|
|
Revision tags: llvmorg-14.0.6 |
|
| #
ede42131 |
| 17-Jun-2022 |
Peter Klausler <[email protected]> |
[flang][runtime] Handle READ of non-UTF-8 data into multi-byte CHARACTER
When a READ statement reads into a CHARACTER(2 or 4) variable from a unit whose encoding is not UTF-8, don't copy bytes direc
[flang][runtime] Handle READ of non-UTF-8 data into multi-byte CHARACTER
When a READ statement reads into a CHARACTER(2 or 4) variable from a unit whose encoding is not UTF-8, don't copy bytes directly; they must each be zero-extended.
Differential Revision: https://reviews.llvm.org/D128390
show more ...
|
| #
8ef10753 |
| 10-Jun-2022 |
Peter Klausler <[email protected]> |
[flang][runtime] Signal END from character input
There's code in EditCharacterInput() that causes that template function to silently return false if it is invoked at the end of the input file. This
[flang][runtime] Signal END from character input
There's code in EditCharacterInput() that causes that template function to silently return false if it is invoked at the end of the input file. This overrides other checks that properly call SignalEnd() later.
Differential Revision: https://reviews.llvm.org/D127786
show more ...
|
|
Revision tags: llvmorg-14.0.5 |
|
| #
850097d6 |
| 08-Jun-2022 |
Peter Klausler <[email protected]> |
[flang][runtime] Don't loop in runtime if blank appears in BOZ input
The code for scanning BOZ input allows for blanks and tabs to appear, but can hang if they do and the BOZ input value is not foll
[flang][runtime] Don't loop in runtime if blank appears in BOZ input
The code for scanning BOZ input allows for blanks and tabs to appear, but can hang if they do and the BOZ input value is not followed by extra valid digits; the repositioning for the second sweep simply needed to be done in units of character, not valid digits.
Differential Revision: https://reviews.llvm.org/D127431
show more ...
|
| #
4c42e67b |
| 09-Jun-2022 |
Peter Klausler <[email protected]> |
[flang][runtime] Fix overflow detection for REAL input
The test for an overflow during decimal->binary conversion was taking place too late, causing the data not to be rescanned from the beginning.
[flang][runtime] Fix overflow detection for REAL input
The test for an overflow during decimal->binary conversion was taking place too late, causing the data not to be rescanned from the beginning.
Differential Revision: https://reviews.llvm.org/D127427
show more ...
|
| #
9c54d762 |
| 03-Jun-2022 |
Peter Klausler <[email protected]> |
[flang][runtime] Signal new I/O error on floating-point input overflow
Besides raising the IEEE floating-point overflow exception, treat a floating-point overflow on input as an I/O error catchable
[flang][runtime] Signal new I/O error on floating-point input overflow
Besides raising the IEEE floating-point overflow exception, treat a floating-point overflow on input as an I/O error catchable with ERR=, IOSTAT=, &/or IOMSG=.
Differential Revision: https://reviews.llvm.org/D127022
show more ...
|
|
Revision tags: llvmorg-14.0.4 |
|
| #
cdd54cbd |
| 20-May-2022 |
Peter Klausler <[email protected]> |
[flang][runtime] Catch decimal integer input overflow
B/O/Z input overflow is already caught, and real input overflow is signalled as an IEEE arithmetic exception, but regular decimal integer overfl
[flang][runtime] Catch decimal integer input overflow
B/O/Z input overflow is already caught, and real input overflow is signalled as an IEEE arithmetic exception, but regular decimal integer overflow was silent.
Differential Revision: https://reviews.llvm.org/D126155
show more ...
|
|
Revision tags: llvmorg-14.0.3 |
|
| #
cea8b8a7 |
| 27-Apr-2022 |
Peter Klausler <[email protected]> |
[flang][runtime] Don't pad CHARACTER input at end of record unless PAD='YES'
When formatted CHARACTER input runs into the end of an input record, the runtime usually fills the remainder of the varia
[flang][runtime] Don't pad CHARACTER input at end of record unless PAD='YES'
When formatted CHARACTER input runs into the end of an input record, the runtime usually fills the remainder of the variable with spaces, but this should be conditional, and not done when PAD='NO'.
And while here, add some better comments to two members of connection.h to make their non-obvious relationship more clear.
Differential Revision: https://reviews.llvm.org/D125053
show more ...
|
| #
2f31b4b1 |
| 26-Apr-2022 |
Peter Klausler <[email protected]> |
[flang][runtime] Fix input of NAN(...) on non-fast path
The closing parenthesis needs to be consumed when a NaN with parenthesized (ignored) information is read on the real input path that preproces
[flang][runtime] Fix input of NAN(...) on non-fast path
The closing parenthesis needs to be consumed when a NaN with parenthesized (ignored) information is read on the real input path that preprocesses input characters before passing them to the decimal-to-binary converter.
Differential Revision: https://reviews.llvm.org/D125048
show more ...
|
| #
53f775bb |
| 27-Apr-2022 |
Peter Klausler <[email protected]> |
[flang][runtime] Support B/O/Z editing of CHARACTER
This is a common extension, though semantics differ across compilers. I've chosen to interpret the CHARACTER data as if it were an arbitrary-prec
[flang][runtime] Support B/O/Z editing of CHARACTER
This is a common extension, though semantics differ across compilers. I've chosen to interpret the CHARACTER data as if it were an arbitrary-precision integer value and format or read it as such. This matches Intel's compilers and nvfortran. (GNU Fortran can't handle lengths > 1 and XLF seems to get the enddianness wrong.)
This patch generalizes the previous implementations of B/O/Z input and output so that they'll work for arbitrary data in memory, and then uses them for all B/O/Z input/output, including (now) CHARACTER.
Differential Revision: https://reviews.llvm.org/D124547
show more ...
|
|
Revision tags: llvmorg-14.0.2 |
|
| #
f1dbf8e4 |
| 13-Apr-2022 |
Peter Klausler <[email protected]> |
[flang][runtime] Fix edge-case FP input bugs
Blanks are allowed in more places than I allowed for, and "NAN(foobar)" is allowed to have any parenthesis-balanced characters in parentheses.
Update: F
[flang][runtime] Fix edge-case FP input bugs
Blanks are allowed in more places than I allowed for, and "NAN(foobar)" is allowed to have any parenthesis-balanced characters in parentheses.
Update: Fix up old sanity test, then avoid usage of "limit" when null.
Differential Revision: https://reviews.llvm.org/D124294
show more ...
|
| #
839f0abd |
| 21-Apr-2022 |
Peter Klausler <[email protected]> |
[flang][runtime] Accept "." as REAL input
".", possibly followed by an exponent, is a valid REAL input value (meaning zero).
Differential Revision: https://reviews.llvm.org/D124279
|
| #
cbbc6629 |
| 21-Apr-2022 |
Peter Klausler <[email protected]> |
[flang][runtime] Ignore leading spaces even in BZ mode
When editing numeric input, always skip leading spaces, even if BZ mode (or BLANK='ZERO') is in effect; otherwise, a sign character preceded by
[flang][runtime] Ignore leading spaces even in BZ mode
When editing numeric input, always skip leading spaces, even if BZ mode (or BLANK='ZERO') is in effect; otherwise, a sign character preceded by blanks will not be recognized.
Differential Revision: https://reviews.llvm.org/D124278
show more ...
|
|
Revision tags: llvmorg-14.0.1 |
|
| #
e6873bfb |
| 06-Apr-2022 |
Peter Klausler <[email protected]> |
[flang][runtime] Don't skip input spaces when they are significant
When formatted input (not list-directed or NAMELIST) is in "BZ" mode, either because a BZ control edit descriptor appeared in a FOR
[flang][runtime] Don't skip input spaces when they are significant
When formatted input (not list-directed or NAMELIST) is in "BZ" mode, either because a BZ control edit descriptor appeared in a FORMAT or BLANK="ZERO" appeared in OPEN or READ, input editing must not skip over blanks before or within the input field.
Differential Revision: https://reviews.llvm.org/D123725
show more ...
|
| #
de026aeb |
| 04-Apr-2022 |
Peter Klausler <[email protected]> |
[flang] Raise FP exceptions from runtime conversion to binary
Formatted READs of REAL should convert the exception flags from the decimal-to-binary conversion library into real runtime FP exceptions
[flang] Raise FP exceptions from runtime conversion to binary
Formatted READs of REAL should convert the exception flags from the decimal-to-binary conversion library into real runtime FP exceptions so that they at least show up in the termination message of a STOP statement.
Differential Revision: https://reviews.llvm.org/D123714
show more ...
|
| #
bafbae23 |
| 16-Mar-2022 |
Peter Klausler <[email protected]> |
[flang] Initial UTF-8 support in runtime I/O
Implements UTF-8 encoding and decoding for external units with OPEN(ENCODING='UTF-8'). This encoding applies to default CHARACTER values that are not 7-
[flang] Initial UTF-8 support in runtime I/O
Implements UTF-8 encoding and decoding for external units with OPEN(ENCODING='UTF-8'). This encoding applies to default CHARACTER values that are not 7-bit ASCII as well as to the wide CHARACTER kinds 2 and 4. Basic testing is in place via direct calls to the runtime I/O APIs, but serious checkout awaits lowering support of the wide CHARACTER kinds.
Differential Revision: https://reviews.llvm.org/D122038
show more ...
|
|
Revision tags: llvmorg-14.0.0, llvmorg-14.0.0-rc4, llvmorg-14.0.0-rc3, llvmorg-14.0.0-rc2 |
|
| #
ef7f6f7c |
| 23-Feb-2022 |
Peter Klausler <[email protected]> |
[flang] Use faster path for default formatted character input
Rather than reading default character variables in formatted input one byte at a time via NextInField(), skip and read them via blocks o
[flang] Use faster path for default formatted character input
Rather than reading default character variables in formatted input one byte at a time via NextInField(), skip and read them via blocks of available buffer data. This eliminates a bottleneck that affected reads of large character values. (It also exposed a problem with sequential reads with RECL= set on the OPEN statement, so that's fixed too.)
Differential Revision: https://reviews.llvm.org/D121144
show more ...
|
|
Revision tags: llvmorg-14.0.0-rc1, llvmorg-15-init |
|
| #
991696c2 |
| 28-Jan-2022 |
Peter Klausler <[email protected]> |
[flang] Debugging of ACCESS='STREAM' I/O (take 2)
Corrects the runtime implementation of I/O on files with the access mode ACCESS='STREAM'. This is a collection of edge-case tweaks to ensure that t
[flang] Debugging of ACCESS='STREAM' I/O (take 2)
Corrects the runtime implementation of I/O on files with the access mode ACCESS='STREAM'. This is a collection of edge-case tweaks to ensure that the distinctions between stream and direct/sequential files, unformatted or formatted, are respected where appropriate.
Moves NextInField() from io-stmt.h to io-stmt.cpp -- it was getting too big to keep in a header.
This patch exposed a problem with the I/O runtime on Windows and it was reverted. This version also fixes that problem; files are now opened on Windows in binary mode to prevent inadvertent insertions of carriage returns before line feeds, and those line endings (CR+LF) are now explicitly generated.
Differential Revision: https://reviews.llvm.org/D119015
show more ...
|
| #
4e53e283 |
| 03-Feb-2022 |
Andrzej Warzynski <[email protected]> |
Revert "[flang] Debugging of ACCESS='STREAM' I/O"
This reverts commit be9946b877add0db906090d22840b213c3f41dd2.
This change has caused Flang's Windows buildbot to start failing: * https://lab.llvm.
Revert "[flang] Debugging of ACCESS='STREAM' I/O"
This reverts commit be9946b877add0db906090d22840b213c3f41dd2.
This change has caused Flang's Windows buildbot to start failing: * https://lab.llvm.org/buildbot/#/builders/172/builds/7664
show more ...
|
| #
be9946b8 |
| 28-Jan-2022 |
Peter Klausler <[email protected]> |
[flang] Debugging of ACCESS='STREAM' I/O
Corrects the runtime implementation of I/O on files with the access mode ACCESS='STREAM'. This is a collection of edge-case tweaks to ensure that the distin
[flang] Debugging of ACCESS='STREAM' I/O
Corrects the runtime implementation of I/O on files with the access mode ACCESS='STREAM'. This is a collection of edge-case tweaks to ensure that the distinctions between stream and direct/sequential files, unformatted or formatted, are respected where appropriate. Moves NextInField() from io-stmt.h to io-stmt.cpp -- it was getting too big to keep in a header.
Differential Revision: https://reviews.llvm.org/D118834
show more ...
|
| #
0f5c60f1 |
| 27-Jan-2022 |
Peter Klausler <[email protected]> |
[flang] Fix edge-case I/O regressions
A blank field in an input record that exists must be interpreted as a zero value for numeric input editing, but advancing to a next record that doesn't exist sh
[flang] Fix edge-case I/O regressions
A blank field in an input record that exists must be interpreted as a zero value for numeric input editing, but advancing to a next record that doesn't exist should leave an input variable unmodified (and signal END=). On internal output, blank fill the "current record" array element even if nothing has been written to it if it is the only record.
Differential Revision: https://reviews.llvm.org/D118720
show more ...
|
|
Revision tags: llvmorg-13.0.1, llvmorg-13.0.1-rc3 |
|
| #
896a543e |
| 20-Jan-2022 |
Peter Klausler <[email protected]> |
[flang] Support DECIMAL='COMMA' mode in namelist I/O
DECIMAL='COMMA' mode affects item separators, real editing, and complex editing.
Differential Revision: https://reviews.llvm.org/D117906
|
|
Revision tags: llvmorg-13.0.1-rc2 |
|
| #
ac4202fe |
| 07-Jan-2022 |
Peter Klausler <[email protected]> |
[flang] Signal runtime error on WRITE after ENDFILE
After an ENDFILE statement, a WRITE is an error without a prior BACKSPACE. Also fix the return value for the case of formatted integer input with
[flang] Signal runtime error on WRITE after ENDFILE
After an ENDFILE statement, a WRITE is an error without a prior BACKSPACE. Also fix the return value for the case of formatted integer input with no input digits to be false (exposed by new test).
Differential Revision: https://reviews.llvm.org/D117346
show more ...
|
|
Revision tags: llvmorg-13.0.1-rc1 |
|
| #
d02b318a |
| 19-Nov-2021 |
Peter Klausler <[email protected]> |
[flang] Remove typo that affected complex namelist input
A recent patch to real/complex formatted input included what must have been an editing hiccup: "++ ++p" instead of "++p". This compiles, and
[flang] Remove typo that affected complex namelist input
A recent patch to real/complex formatted input included what must have been an editing hiccup: "++ ++p" instead of "++p". This compiles, and it broke the consumption of the trailing ')' of a complex value in namelist input by skipping over the character.
Extend existing test to cover this case.
Differential Revision: https://reviews.llvm.org/D114297
show more ...
|
| #
da25f968 |
| 02-Nov-2021 |
Peter Klausler <[email protected]> |
[flang] Runtime performance improvements to real formatted input
Profiling a basic internal real input read benchmark shows some hot spots in the code used to prepare input for decimal-to-binary con
[flang] Runtime performance improvements to real formatted input
Profiling a basic internal real input read benchmark shows some hot spots in the code used to prepare input for decimal-to-binary conversion, which is of course where the time should be spent. The library that implements decimal to/from binary conversions has been optimized, but not the code in the Fortran runtime that calls it, and there are some obvious light changes worth making here.
Move some member functions from *.cpp files into the class definitions of Descriptor and IoStatementState to enable inlining and specialization.
Make GetNextInputBytes() the new basic input API within the runtime, replacing GetCurrentChar() -- which is rewritten in terms of GetNextInputBytes -- so that input routines can have the ability to acquire more than one input character at a time and amortize overhead.
These changes speed up the time to read 1M random reals using internal I/O from a character array from 1.29s to 0.54s on my machine, which on par with Intel Fortran and much faster than GNU Fortran.
Differential Revision: https://reviews.llvm.org/D113697
show more ...
|