Optimize filesystem::path::parent_path()
authorJonathan Wakely <jwakely@redhat.com>
Wed, 29 May 2019 22:00:45 +0000 (23:00 +0100)
committerJonathan Wakely <redi@gcc.gnu.org>
Wed, 29 May 2019 22:00:45 +0000 (23:00 +0100)
commite5ccb10ad04e5cc1c44ea4d50a501840927ad70e
treed0b2dd96111966903022c5a8936a2ab2a4297fcf
parente800d6dc2cb329a1b64bb3af136164910778a40c
Optimize filesystem::path::parent_path()

Parsing a complete string is more efficient than appending each
component one-by-one.

* src/c++17/fs_path.cc (path::parent_path()): Create whole path at
once instead of building it iteratively.

From-SVN: r271754
libstdc++-v3/ChangeLog
libstdc++-v3/src/c++17/fs_path.cc