Landing: b71686db1fdc

Project / Subsystem

gcc / libstdc++

Date

2026-07-26

Author

Patrick Palka

Commit

b71686db1fdc589da34f80460f054407c1f54990

Source

github

Perf win

No

Breaking

No

All attributes

project
gcc
subsystem
libstdc++
patch_id
commit_hash
b71686db1fdc589da34f80460f054407c1f54990
source_type
github
headline
libstdc++: Robustify flat_map::insert_range move counter test
tldr
Makes a libstdc++ test for `flat_map::insert_range` more reliable by ensuring sufficient capacity.
author
Patrick Palka
outcome
committed
performance_win
false
breaking_change
false
series_id
series_parts
[]
tags
  • libstdc++
  • test
  • container
  • flat_map
discussion_id_link
bugzilla_pr
date
2026-07-26T00:00:00.000Z

This commit improves the robustness of a test case for libstdc++’s flat_map::insert_range method. The test, which verifies the move counter, was found to be unreliable due to potential reallocations in the underlying std::vector during insert_range operations. The fix ensures that the test reserves enough capacity upfront to prevent these reallocations, thus guaranteeing accurate move counter measurements.