perf: prefer absl::flat_hash_set
over std::set
when sorted order is not needed (#46410)
* perf: use an absl::flat_hash_set for UsbChooserContext::ephemeral_devices_ * perf: use an absl::flat_hash_set for GlobalMenuBarRegistrarX11::live_windows_ * perf: use an absl::flat_hash_set for NativeWindowViews::forwarding_windows_ * perf: use an absl::flat_hash_set for OffScreenRenderWidgetHostView::guest_host_views_ perf: use an absl::flat_hash_set for OffScreenRenderWidgetHostView::proxy_views_ * perf: use an absl::flat_hash_set for NativeWindow::injected_frames_ * perf: use an absl::flat_hash_set for NativeWindow::background_throttling_sources_
This commit is contained in:
parent
36e233797c
commit
6f24dbaab4
7 changed files with 14 additions and 15 deletions
|
@ -7,10 +7,9 @@
|
|||
|
||||
#include <gio/gio.h>
|
||||
|
||||
#include <set>
|
||||
|
||||
#include "base/memory/raw_ptr.h"
|
||||
#include "base/memory/singleton.h"
|
||||
#include "third_party/abseil-cpp/absl/container/flat_hash_set.h"
|
||||
#include "ui/base/glib/scoped_gsignal.h"
|
||||
#include "ui/gfx/x/xproto.h"
|
||||
|
||||
|
@ -52,7 +51,7 @@ class GlobalMenuBarRegistrarX11 {
|
|||
|
||||
// x11::Window which want to be registered, but haven't yet been because
|
||||
// we're waiting for the proxy to become available.
|
||||
std::set<x11::Window> live_windows_;
|
||||
absl::flat_hash_set<x11::Window> live_windows_;
|
||||
ScopedGSignal signal_;
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue