Jonathan Wakely 4ba94abf14 libstdc++: Add hint to compiler about vector invariants [PR106434]
The PR shows a bogus warning where jump threading generates code for the
undefined case that the insertion point is a value-initialized iterator
but _M_finish and _M_end_of_storage are unequal (so at least one must be
non-null). Using __builtin_unreachable() removes the bogus warning. Also
add an assertion to diagnose undefined misuses of a null iterator here,
so we don't just silently optimize that undefined code to something
unsafe.

libstdc++-v3/ChangeLog:

	PR c++/106434
	* include/bits/vector.tcc (insert(const_iterator, const T&)):
	Add assertion and optimization hint that the iterator for the
	insertion point must be non-null.
2022-12-06 21:33:29 +00:00
2022-11-24 00:17:47 +00:00
2022-11-24 00:17:47 +00:00
2022-12-06 20:27:25 +00:00
2022-11-24 00:17:47 +00:00
2022-11-24 00:17:47 +00:00
2022-11-24 00:17:47 +00:00
2022-11-24 00:17:47 +00:00
2022-11-30 12:21:15 -08:00
2022-11-24 00:17:47 +00:00
2022-12-05 00:17:24 +00:00
2022-11-24 00:17:47 +00:00
2022-12-01 00:17:51 +00:00
2022-11-24 00:17:47 +00:00
2022-11-26 00:17:08 +00:00

This directory contains the GNU Compiler Collection (GCC).

The GNU Compiler Collection is free software.  See the files whose
names start with COPYING for copying permission.  The manuals, and
some of the runtime libraries, are under different terms; see the
individual source files for details.

The directory INSTALL contains copies of the installation information
as HTML and plain text.  The source of this information is
gcc/doc/install.texi.  The installation information includes details
of what is included in the GCC sources and what files GCC installs.

See the file gcc/doc/gcc.texi (together with other files that it
includes) for usage and porting information.  An online readable
version of the manual is in the files gcc/doc/gcc.info*.

See http://gcc.gnu.org/bugs/ for how to report bugs usefully.

Copyright years on GCC source files may be listed using range
notation, e.g., 1987-2012, indicating that every year in the range,
inclusive, is a copyrightable year that could otherwise be listed
individually.
Description
No description provided
Readme 2.1 GiB
Languages
C++ 31.9%
C 31.3%
Ada 12%
D 6.5%
Go 6.4%
Other 11.5%