diff options
author | Richard Smith <richard@metafoo.co.uk> | 2020-01-23 12:22:07 -0800 |
---|---|---|
committer | Richard Smith <richard@metafoo.co.uk> | 2020-01-23 12:26:43 -0800 |
commit | ed63454d984f2262ce332b9b15d49917be3eac98 (patch) | |
tree | 4b6d764720b2a01616de374437314d6a943b49d4 | |
parent | b079266dcb6d1ee6446d074ebd1d212a13ce0665 (diff) | |
download | bcm5719-llvm-ed63454d984f2262ce332b9b15d49917be3eac98.tar.gz bcm5719-llvm-ed63454d984f2262ce332b9b15d49917be3eac98.zip |
Update documentation and release notes to match the state of
-flax-vector-conversions on the Clang 10 release branch.
-rw-r--r-- | clang/docs/CommandGuide/clang.rst | 11 | ||||
-rw-r--r-- | clang/docs/ReleaseNotes.rst | 31 |
2 files changed, 26 insertions, 16 deletions
diff --git a/clang/docs/CommandGuide/clang.rst b/clang/docs/CommandGuide/clang.rst index 7b0873600fc..6947450beb4 100644 --- a/clang/docs/CommandGuide/clang.rst +++ b/clang/docs/CommandGuide/clang.rst @@ -278,9 +278,18 @@ Language Selection and Mode Options Make all string literals default to writable. This disables uniquing of strings and other optimizations. -.. option:: -flax-vector-conversions +.. option:: -flax-vector-conversions, -flax-vector-conversions=<kind>, -fno-lax-vector-conversions Allow loose type checking rules for implicit vector conversions. + Possible values of <kind>: + + - ``none``: allow no implicit conversions between vectors + - ``integer``: allow implicit bitcasts between integer vectors of the same + overall bit-width + - ``all``: allow implicit bitcasts between any vectors of the same + overall bit-width + + <kind> defaults to ``integer`` if unspecified. .. option:: -fblocks diff --git a/clang/docs/ReleaseNotes.rst b/clang/docs/ReleaseNotes.rst index 8c48724e7c6..caa6abd4b79 100644 --- a/clang/docs/ReleaseNotes.rst +++ b/clang/docs/ReleaseNotes.rst @@ -102,14 +102,13 @@ Non-comprehensive list of changes in this release the found gcc installation is older than 4.7.0. Add ``-fno-use-init-array`` to get the old behavior (``.ctors``). -* Lax vector conversions involving floating-point vectors have been disabled - by default, and can no longer be enabled with ``-flax-vector-conversions``. - This matches the behavior of these flags in GCC, but code relying on implicit - vector bitcasts between integer and floating-point types that used to compile - with older versions of Clang is no longer accepted by default in Clang 10. - The old behavior can be restored with ``-flax-vector-conversions=all``. - In a future release of Clang, we intend to change the default to - ``-fno-lax-vector-conversions``. +* The behavior of the flag ``-flax-vector-conversions`` has been modified to + more closely match GCC, as described below. In Clang 10 onwards, command lines + specifying this flag do not permit implicit vector bitcasts between integer + vectors and floating-point vectors. Such conversions are still permitted by + default, however, and the default can be explicitly requested with the + Clang-specific flag ``-flax-vector-conversions=all``. In a future release of + Clang, we intend to change the default to ``-fno-lax-vector-conversions``. New Compiler Flags ------------------ @@ -142,19 +141,21 @@ Modified Compiler Flags to the ``-march`` flag, overriding the target provided by ``-triple``. - ``-flax-vector-conversions`` has been split into three different levels of - laxness: + laxness, and has been updated to match the GCC semantics: - - ``-flax-vector-conversions=all``: This is Clang's historical default, and + - ``-flax-vector-conversions=all``: This is Clang's current default, and permits implicit vector conversions (performed as bitcasts) between any two vector types of the same overall bit-width. + Former synonym: ``-flax-vector-conversions`` (Clang <= 9). - - ``-flax-vector-conversions=integer``: This is Clang's current default, - and permits implicit vector conversions (performed as bitcasts) between - any two integer vector types of the same overall bit-width. - Synonym: ``-flax-vector-conversions``. + - ``-flax-vector-conversions=integer``: This permits implicit vector + conversions (performed as bitcasts) between any two integer vector types of + the same overall bit-width. + Synonym: ``-flax-vector-conversions`` (Clang >= 10). - ``-flax-vector-conversions=none``: Do not perform any implicit bitcasts - between vector types. Synonym: ``-fno-lax-vector-conversions``. + between vector types. + Synonym: ``-fno-lax-vector-conversions``. New Pragmas in Clang -------------------- |