1- =======================================
2- Clang 7.0.0 (In-Progress) Release Notes
3- =======================================
1+ =========================
2+ Clang 7.0.0 Release Notes
3+ =========================
44
55.. contents ::
66 :local:
77 :depth: 2
88
9- Written by the `LLVM Team <http://llvm.org/ >`_
10-
11- .. warning ::
12-
13- These are in-progress notes for the upcoming Clang 7 release.
14- Release notes for previous releases can be found on
15- `the Download Page <http://releases.llvm.org/download.html >`_.
9+ Written by the `LLVM Team <https://llvm.org/ >`_
1610
1711Introduction
1812============
@@ -22,18 +16,13 @@ frontend, part of the LLVM Compiler Infrastructure, release 7.0.0. Here we
2216describe the status of Clang in some detail, including major
2317improvements from the previous release and new feature work. For the
2418general LLVM release notes, see `the LLVM
25- documentation <http ://llvm.org/docs/ReleaseNotes.html> `_. All LLVM
19+ documentation <https ://llvm.org/docs/ReleaseNotes.html> `_. All LLVM
2620releases may be downloaded from the `LLVM releases web
27- site <http ://llvm.org/releases/> `_.
21+ site <https ://llvm.org/releases/> `_.
2822
2923For more information about Clang or LLVM, including information about the
30- latest release, please see the `Clang Web Site <http://clang.llvm.org >`_ or the
31- `LLVM Web Site <http://llvm.org >`_.
32-
33- Note that if you are reading this file from a Subversion checkout or the
34- main Clang web page, this document applies to the *next * release, not
35- the current one. To see the release notes for a specific release, please
36- see the `releases page <http://llvm.org/releases/ >`_.
24+ latest release, please see the `Clang Web Site <https://clang.llvm.org >`_ or the
25+ `LLVM Web Site <https://llvm.org >`_.
3726
3827What's New in Clang 7.0.0?
3928==========================
@@ -55,9 +44,9 @@ Major New Features
5544 information, including the new .debug_names accelerator table. Type units
5645 and split DWARF are known not to conform, and higher optimization levels
5746 will likely get a mix of v4 and v5 formats.
58-
47+
5948Improvements to Clang's diagnostics
60- ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
49+ -----------------------------------
6150
6251- ``-Wc++98-compat-extra-semi `` is a new flag, which was previously inseparable
6352 from ``-Wc++98-compat-pedantic ``. The latter still controls the new flag.
@@ -81,6 +70,9 @@ Non-comprehensive list of changes in this release
8170 For example, the ``clang `` binary will be called ``clang-7 ``
8271 instead of ``clang-7.0 ``.
8372
73+ - The optimization flag to merge constants (``-fmerge-all-constants ``) is no
74+ longer applied by default.
75+
8476- Clang implements a collection of recent fixes to the C++ standard's definition
8577 of "standard-layout". In particular, a class is only considered to be
8678 standard-layout if all base classes and the first data member (or bit-field)
@@ -90,7 +82,7 @@ Non-comprehensive list of changes in this release
9082 to apply only to non-static data members and not to base classes. This fixes
9183 an ABI difference between Clang and GCC, but creates an ABI difference between
9284 Clang 7 and earlier versions. The old behavior can be restored by setting
93- ``-fclang-abi-compat `` to ``6 `` or earlier .
85+ ``-fclang-abi-compat `` to ``6 `` or lower .
9486
9587- Clang implements the proposed resolution of LWG issue 2358, along with the
9688 `corresponding change to the Itanium C++ ABI
@@ -114,64 +106,50 @@ Non-comprehensive list of changes in this release
114106 relocation scanning. The ``-faddrsig `` and ``-fno-addrsig `` flags can be
115107 used to control whether to emit the address-significance table.
116108
117- - Integrated assembler is enabled by default on OpenBSD / FreeBSD
109+ - The integrated assembler is enabled by default on OpenBSD / FreeBSD
118110 for MIPS 64-bit targets.
119111
120- - On MIPS FreeBSD default CPUs have been changed to ``mips2 ``
112+ - On MIPS FreeBSD, default CPUs have been changed to ``mips2 ``
121113 for 32-bit targets and ``mips3 `` for 64-bit targets.
122114
123- - ...
124115
125116New Compiler Flags
126117------------------
127118
128119- ``-fstrict-float-cast-overflow `` and ``-fno-strict-float-cast-overflow ``.
129120
130- When a floating-point value is not representable in a destination integer
131- type, the code has undefined behavior according to the language standard. By
121+ When converting a floating-point value to int and the value is not
122+ representable in the destination integer type,
123+ the code has undefined behavior according to the language standard. By
132124 default, Clang will not guarantee any particular result in that case. With the
133125 'no-strict' option, Clang attempts to match the overflowing behavior of the
134126 target's native float-to-int conversion instructions.
135127
136128- ``-fforce-emit-vtables `` and ``-fno-force-emit-vtables ``.
137129
138- In order to improve devirtualization, forces emitting of vtables even in
139- modules where it isn't necessary. It causes more inline virtual functions
140- to be emitted.
130+ In order to improve devirtualization, forces emission of vtables even in
131+ modules where it isn't necessary. It causes more inline virtual functions
132+ to be emitted.
141133
142- - Added the``-mcrc`` and ``-mno-crc `` flags to enable/disable using
134+ - Added the ``-mcrc `` and ``-mno-crc `` flags to enable/disable using
143135 of MIPS Cyclic Redundancy Check instructions.
144136
145- - Added the``-mvirt`` and ``-mno-virt `` flags to enable/disable using
137+ - Added the ``-mvirt `` and ``-mno-virt `` flags to enable/disable using
146138 of MIPS Virtualization instructions.
147139
148- - Added the``-mginv`` and ``-mno-ginv `` flags to enable/disable using
140+ - Added the ``-mginv `` and ``-mno-ginv `` flags to enable/disable using
149141 of MIPS Global INValidate instructions.
150142
151- - ...
152-
153- Deprecated Compiler Flags
154- -------------------------
155-
156- The following options are deprecated and ignored. They will be removed in
157- future versions of Clang.
158-
159- - ...
160143
161144Modified Compiler Flags
162145-----------------------
163146
164- - Before Clang 7, we prepended the `# ` character to the `--autocomplete `
165- argument to enable cc1 flags. For example, when the `-cc1 ` or `-Xclang ` flag
147+ - Before Clang 7, we prepended the `# ` character to the `` --autocomplete ` `
148+ argument to enable cc1 flags. For example, when the `` -cc1 `` or `` -Xclang ` ` flag
166149 is in the :program: `clang ` invocation, the shell executed
167- `clang --autocomplete=#-<flag to be completed> `. Clang 7 now requires the
168- whole invocation including all flags to be passed to the `--autocomplete ` like
169- this: `clang --autocomplete=-cc1,-xc++,-fsyn `.
170-
171- New Pragmas in Clang
172- --------------------
173-
174- Clang now supports the ...
150+ ``clang --autocomplete=#-<flag to be completed> ``. Clang 7 now requires the
151+ whole invocation including all flags to be passed to the ``--autocomplete `` like
152+ this: ``clang --autocomplete=-cc1,-xc++,-fsyn ``.
175153
176154
177155Attribute Changes in Clang
@@ -181,10 +159,8 @@ Attribute Changes in Clang
181159 based x86/x86-64 environments by using indirect functions. This implementation
182160 has a few minor limitations over the GCC implementation for the sake of AST
183161 sanity, however it is otherwise compatible with existing code using this
184- feature for GCC. Consult the documentation for the target attribute for more
185- information.
186-
187- - ...
162+ feature for GCC. Consult the `documentation for the target attribute
163+ <AttributeReference.html#target-gnu-target> `_ for more information.
188164
189165Windows Support
190166---------------
@@ -196,8 +172,8 @@ Windows Support
196172 the pch file (matching cl.exe). This speeds up builds using pch files
197173 by around 30%.
198174
199- - The /Ycfoo.h and /Yufoo.h flags can now be used without /FIfoo.h when
200- foo.h is instead included by an explicit `#include ` directive. This means
175+ - The `` /Ycfoo.h `` and `` /Yufoo.h `` flags can now be used without `` /FIfoo.h `` when
176+ foo.h is instead included by an explicit `` #include ` ` directive. This means
201177 Visual Studio's default stdafx.h setup now uses precompiled headers with
202178 clang-cl.
203179
@@ -207,36 +183,12 @@ Windows Support
207183 explicit specify ``extern "C" ``. (This was already the case for MSVC
208184 targets.)
209185
210- - ...
211-
212-
213- C Language Changes in Clang
214- ---------------------------
215-
216- - ...
217-
218- ...
219-
220- C11 Feature Support
221- ^^^^^^^^^^^^^^^^^^^
222-
223- ...
224-
225- C++ Language Changes in Clang
226- -----------------------------
227-
228- - ...
229-
230- C++1z Feature Support
231- ^^^^^^^^^^^^^^^^^^^^^
232-
233- ...
234186
235187Objective-C Language Changes in Clang
236188-------------------------------------
237189
238190Clang now supports the GNUstep Objective-C ABI v2 on ELF platforms. This is
239- enabled with the `-fobjc-runtime=gnustep-2.0 ` flag. The new ABI is incompatible
191+ enabled with the `` -fobjc-runtime=gnustep-2.0 ` ` flag. The new ABI is incompatible
240192with the older GNUstep ABIs, which were incremental changes on the old GCC ABI.
241193The new ABI provides richer reflection metadata and allows the linker to remove
242194duplicate selector and protocol definitions, giving smaller binaries. Windows
@@ -275,18 +227,19 @@ OpenMP Support in Clang
275227----------------------------------
276228
277229- Clang gained basic support for OpenMP 4.5 offloading for NVPTX target.
278- To compile your program for NVPTX target use the following options:
279- `-fopenmp -fopenmp-targets=nvptx64-nvidia-cuda ` for 64 bit platforms or
280- `-fopenmp -fopenmp-targets=nvptx-nvidia-cuda ` for 32 bit platform.
230+
231+ To compile your program for NVPTX target use the following options:
232+ ``-fopenmp -fopenmp-targets=nvptx64-nvidia-cuda `` for 64 bit platforms or
233+ ``-fopenmp -fopenmp-targets=nvptx-nvidia-cuda `` for 32 bit platform.
281234
282235- Passing options to the OpenMP device offloading toolchain can be done using
283- the `-Xopenmp-target=<triple> -opt=val ` flag. In this way the `-opt=val `
236+ the `` -Xopenmp-target=<triple> -opt=val `` flag. In this way the `` -opt=val ` `
284237 option will be forwarded to the respective OpenMP device offloading toolchain
285238 described by the triple. For example passing the compute capability to
286239 the OpenMP NVPTX offloading toolchain can be done as follows:
287- `-Xopenmp-target=nvptx64-nvidia-cuda -march=sm_60 `. For the case when only one
288- target offload toolchain is specified under the `-fopenmp-targets=<triples> `
289- option, then the triple can be skipped: `-Xopenmp-target -march=sm_60 `.
240+ `` -Xopenmp-target=nvptx64-nvidia-cuda -march=sm_60 ` `. For the case when only one
241+ target offload toolchain is specified under the `` -fopenmp-targets=<triples> ` `
242+ option, then the triple can be skipped: `` -Xopenmp-target -march=sm_60 ` `.
290243
291244- Other bugfixes.
292245
@@ -295,10 +248,10 @@ CUDA Support in Clang
295248
296249- Clang will now try to locate the CUDA installation next to :program: `ptxas `
297250 in the `PATH ` environment variable. This behavior can be turned off by passing
298- the new flag `--cuda-path-ignore-env `.
251+ the new flag `` --cuda-path-ignore-env ` `.
299252
300253- Clang now supports generating object files with relocatable device code. This
301- feature needs to be enabled with `-fcuda-rdc ` and my result in performance
254+ feature needs to be enabled with `` -fcuda-rdc `` and may result in performance
302255 penalties compared to whole program compilation. Please note that NVIDIA's
303256 :program: `nvcc ` must be used for linking.
304257
@@ -309,38 +262,22 @@ These are major API changes that have happened since the 6.0.0 release of
309262Clang. If upgrading an external codebase that uses Clang as a library,
310263this section should help get you past the largest hurdles of upgrading.
311264
312- - The methods ``getLocStart ``, ``getStartLoc `` and ``getLocEnd `` in the AST
313- classes are deprecated. New APIs ``getBeginLoc `` and ``getEndLoc `` should
314- be used instead. While the old methods remain in this release, they will
265+ - The methods ``getLocStart ``, ``getStartLoc `` and ``getLocEnd `` in the AST
266+ classes are deprecated. New APIs ``getBeginLoc `` and ``getEndLoc `` should
267+ be used instead. While the old methods remain in this release, they will
315268 not be present in the next release of Clang.
316269
317- AST Matchers
318- ------------
319-
320- - ...
321-
322270clang-format
323271------------
324272
325273- Clang-format will now support detecting and formatting code snippets in raw
326- string literals. This is configured through the `RawStringFormats ` style
274+ string literals. This is configured through the `` RawStringFormats ` ` style
327275 option.
328276
329- - ...
330-
331- libclang
332- --------
333-
334- ...
335-
336-
337277Static Analyzer
338278---------------
339279
340- - The new `MmapWriteExec ` checker had been introduced to detect attempts to map pages
341- both writable and executable.
342-
343- ...
280+ - The new `MmapWriteExec ` checker had been introduced to detect attempts to map pages both writable and executable.
344281
345282.. _release-notes-ubsan :
346283
@@ -373,22 +310,6 @@ Undefined Behavior Sanitizer (UBSan)
373310 but the ``-fsanitize=implicit-integer-truncation `` check
374311 is enabled by ``-fsanitize=integer ``.
375312
376- Core Analysis Improvements
377- ==========================
378-
379- - ...
380-
381- New Issues Found
382- ================
383-
384- - ...
385-
386- Python Binding Changes
387- ----------------------
388-
389- The following methods have been added:
390-
391- - ...
392313
393314libc++ Changes
394315==============
@@ -404,12 +325,12 @@ Additional Information
404325======================
405326
406327A wide variety of additional information is available on the `Clang web
407- page <http ://clang.llvm.org/> `_. The web page contains versions of the
328+ page <https ://clang.llvm.org/> `_. The web page contains versions of the
408329API documentation which are up-to-date with the Subversion version of
409330the source code. You can access versions of these documents specific to
410331this release by going into the "``clang/docs/ ``" directory in the Clang
411332tree.
412333
413334If you have any questions or comments about Clang, please feel free to
414335contact us via the `mailing
415- list <http ://lists.llvm.org/mailman/listinfo/cfe-dev> `_.
336+ list <https ://lists.llvm.org/mailman/listinfo/cfe-dev> `_.
0 commit comments