diff options
author | Jonathan Wakely <jwakely@redhat.com> | 2022-11-29 15:19:33 +0000 |
---|---|---|
committer | Jonathan Wakely <jwakely@redhat.com> | 2022-11-29 16:01:08 +0000 |
commit | 81cf0354d5f81f2c7600a3bc7ae4600757286995 (patch) | |
tree | fa96fc6258e2224bec647c6c0b6a6ddff53fc89b /libgcc | |
parent | 0ded30b361d2b1e43048b640e9ad6fef161fe9a9 (diff) | |
download | gcc-81cf0354d5f81f2c7600a3bc7ae4600757286995.zip gcc-81cf0354d5f81f2c7600a3bc7ae4600757286995.tar.gz gcc-81cf0354d5f81f2c7600a3bc7ae4600757286995.tar.bz2 |
libstdc++: Remove unnecessary tag dispatching in std::vector
There's no need to call a _M_xxx_dispatch function with a
statically-known __false_type tag, we can just directly call the
function that should be dispatched to. This will compile a tiny bit
faster and save a function call with optimization or inlining turned
off.
Also add the always_inline attribute to the __iterator_category helper
used for dispatching on the iterator category.
libstdc++-v3/ChangeLog:
* include/bits/stl_iterator_base_types.h (__iterator_category):
Add always_inline attribute.
* include/bits/stl_vector.h (assign(Iter, Iter)): Call
_M_assign_aux directly, instead of _M_assign_dispatch.
(insert(const_iterator, Iter, Iter)): Call _M_range_insert
directly instead of _M_insert_dispatch.
Diffstat (limited to 'libgcc')
0 files changed, 0 insertions, 0 deletions