--- a/chrome/browser/ui/webui/history/browsing_history_handler.cc
+++ b/chrome/browser/ui/webui/history/browsing_history_handler.cc
@@ -145,7 +145,7 @@ std::pair<std::string, std::string> SetH
     title_to_set.resize(kShortTitleLength);
   }
 
-  return std::make_tuple(entry.url.spec(), base::UTF16ToUTF8(title_to_set));
+  return std::make_pair(entry.url.spec(), base::UTF16ToUTF8(title_to_set));
 }
 
 // Helper function to check if entry is present in local database (local-side
--- a/components/viz/service/display/surface_aggregator.cc
+++ b/components/viz/service/display/surface_aggregator.cc
@@ -2210,7 +2210,7 @@ AggregatedFrame SurfaceAggregator::Aggre
   root_surface_id_ = surface_id;
 
   // Start recording new stats for this aggregation.
-  stats_.emplace();
+  stats_.emplace(AggregateStatistics{});
 
   base::ElapsedTimer prewalk_timer;
   ResolvedFrameData* resolved_frame = GetResolvedFrame(surface_id);
--- a/mojo/public/cpp/bindings/lib/multiplex_router.cc
+++ b/mojo/public/cpp/bindings/lib/multiplex_router.cc
@@ -893,7 +893,7 @@ bool MultiplexRouter::ExclusiveSyncWaitF
   DCHECK(!exclusive_sync_wait_);
 
   scoped_refptr<MultiplexRouter> keep_alive(this);
-  exclusive_sync_wait_.emplace();
+  exclusive_sync_wait_.emplace(ExclusiveSyncWaitInfo{});
   exclusive_sync_wait_->interface_id = interface_id;
   exclusive_sync_wait_->request_id = request_id;
   while (!exclusive_sync_wait_->finished) {
--- a/third_party/blink/common/interest_group/auction_config_mojom_traits.cc
+++ b/third_party/blink/common/interest_group/auction_config_mojom_traits.cc
@@ -227,8 +227,6 @@ bool StructTraits<blink::mojom::AuctionA
       !data.ReadAllBuyersPrioritySignals(&out->all_buyers_priority_signals) ||
       !data.ReadAuctionReportBuyerKeys(&out->auction_report_buyer_keys) ||
       !data.ReadAuctionReportBuyers(&out->auction_report_buyers) ||
-      !data.ReadAuctionReportBuyerDebugModeConfig(
-          &out->auction_report_buyer_debug_mode_config) ||
       !data.ReadRequiredSellerCapabilities(
           &out->required_seller_capabilities) ||
       !data.ReadRequestedSize(&out->requested_size) ||
--- a/third_party/blink/renderer/core/layout/inline/line_breaker.cc
+++ b/third_party/blink/renderer/core/layout/inline/line_breaker.cc
@@ -2728,7 +2728,7 @@ bool LineBreaker::ComputeTrailingCollaps
       if (!trailing_collapsible_space_.has_value() ||
           trailing_collapsible_space_->item_results != results ||
           trailing_collapsible_space_->item_result_index != index) {
-        trailing_collapsible_space_.emplace();
+        trailing_collapsible_space_.emplace(TrailingCollapsibleSpace{});
         trailing_collapsible_space_->item_results = results;
         trailing_collapsible_space_->item_result_index = index;
         if (item_result.EndOffset() - 1 > item_result.StartOffset()) {
--- a/third_party/blink/renderer/core/paint/paint_layer_scrollable_area.h
+++ b/third_party/blink/renderer/core/paint/paint_layer_scrollable_area.h
@@ -604,7 +604,7 @@ class CORE_EXPORT PaintLayerScrollableAr
       mojom::blink::ScrollBehavior scroll_behavior) override {
     if (!should_restore_scroll)
       return;
-    pending_view_state_.emplace();
+    pending_view_state_.emplace(PendingViewState{});
     pending_view_state_->state = view_state;
     pending_view_state_->scroll_behavior = scroll_behavior;
   }
--- a/third_party/webrtc/call/rtp_config.cc
+++ b/third_party/webrtc/call/rtp_config.cc
@@ -258,7 +258,7 @@ RtpStreamConfig RtpConfig::GetStreamConf
   stream_config.raw_payload = raw_payload;
   if (!rtx.ssrcs.empty()) {
     RTC_DCHECK_EQ(ssrcs.size(), rtx.ssrcs.size());
-    auto& stream_config_rtx = stream_config.rtx.emplace();
+    auto& stream_config_rtx = stream_config.rtx.emplace(RtpStreamConfig::Rtx{});
     stream_config_rtx.ssrc = rtx.ssrcs[index];
     stream_config_rtx.payload_type = rtx.payload_type;
   }
--- a/components/compose/core/browser/config.cc
+++ b/components/compose/core/browser/config.cc
@@ -46,11 +46,11 @@
 }
 
 constexpr auto DEFAULT_COMPOSE_ENABLED_COUNTRIES =
-    base::MakeFixedFlatSet<std::string>({"bd", "ca", "gh", "in", "ke", "my",
+    base::MakeFixedFlatSet<std::string_view>({"bd", "ca", "gh", "in", "ke", "my",
                                          "ng", "ph", "pk", "sg", "tz", "ug",
                                          "us", "zm", "zw"});
 constexpr auto DEFAULT_PROACTIVE_NUDGE_ENABLED_COUNTRIES =
-    base::MakeFixedFlatSet<std::string>({"us"});
+    base::MakeFixedFlatSet<std::string_view>({"us"});
 
 }  // namespace
 
--- a/chrome/browser/actor/tools/navigate_tool.cc
+++ b/chrome/browser/actor/tools/navigate_tool.cc
@@ -72,7 +72,7 @@
       return;
     }
 
-    post_navigation_state_.emplace();
+    post_navigation_state_.emplace(PostNavigationState{});
     content::GetUIThreadTaskRunner()->PostDelayedTask(
         FROM_HERE,
         base::BindOnce(&NavigateTool::Timeout, weak_ptr_factory_.GetWeakPtr()),
--- a/third_party/blink/renderer/platform/wtf/text/string_view.h
+++ b/third_party/blink/renderer/platform/wtf/text/string_view.h
@@ -20,6 +20,7 @@
 #include "third_party/blink/renderer/platform/wtf/allocator/allocator.h"
 #include "third_party/blink/renderer/platform/wtf/get_ptr.h"
 #include "third_party/blink/renderer/platform/wtf/text/string_impl.h"
+#include "third_party/blink/renderer/platform/wtf/text/code_point_iterator.h"
 
 #if DCHECK_IS_ON()
 #include "base/memory/scoped_refptr.h"
--- a/base/synchronization/lock_impl_posix.cc
+++ b/base/synchronization/lock_impl_posix.cc
@@ -20,6 +20,7 @@
 #include "base/system/sys_info.h"
 #include "build/build_config.h"
 
+#if BUILDFLAG(IS_ANDROID)
 // On Android, `pthread_mutexattr_setprotocol()` is only defined in bionic
 // starting with API level 28. Make it a weak import, so that we can compile.
 extern "C" {
@@ -27,6 +28,7 @@ int __attribute__((weak)) pthread_mutexa
     pthread_mutexattr_t* _Nonnull __attr,
     int __protocol);
 }
+#endif
 
 namespace base {
 
--- a/build/config/compiler/BUILD.gn
+++ b/build/config/compiler/BUILD.gn
@@ -2000,6 +2000,11 @@ config("default_warnings") {
   ldflags = []
   configs = []
 
+  if (!is_clang) {
+    # Disable warnings that are known to fail 'gcc' build.
+    cflags += [ "-Wno-changes-meaning" ]
+  }
+
   if (is_win) {
     if (fatal_linker_warnings) {
       arflags = [ "/WX" ]
--- a/chrome/browser/ui/views/frame/contents_web_view.h
+++ b/chrome/browser/ui/views/frame/contents_web_view.h
@@ -14,6 +14,8 @@
 #include "ui/base/metadata/metadata_header_macros.h"
 #include "ui/gfx/geometry/rounded_corners_f.h"
 #include "ui/views/controls/webview/webview.h"
+#include "chrome/browser/ui/views/status_bubble_views.h"
+#include "chrome/browser/ui/views/frame/web_contents_close_handler.h"
 
 class StatusBubbleViews;
 class WebContentsCloseHandler;
--- a/content/browser/webid/federated_auth_request_impl.cc
+++ b/content/browser/webid/federated_auth_request_impl.cc
@@ -1063,7 +1063,7 @@ void FederatedAuthRequestImpl::MaybeShow
       accounts_ = {auto_reauthn_account};
       idp_data_for_display_ = {auto_reauthn_idp};
       new_accounts_.clear();
-      accounts_[0]->identity_provider = idp_data_for_display_[0];
+      accounts_[0]->identity_provider = idp_data_for_display_[0].get();
     }
   }
 
--- a/content/public/browser/content_browser_client.cc
+++ b/content/public/browser/content_browser_client.cc
@@ -93,6 +93,7 @@
 #include "ui/shell_dialogs/select_file_policy.h"
 #include "url/gurl.h"
 #include "url/origin.h"
+#include "content/public/browser/web_ui_controller.h"
 
 #if BUILDFLAG(IS_ANDROID)
 #include "content/public/browser/tts_environment_android.h"
--- a/content/public/browser/identity_request_account.h
+++ b/content/public/browser/identity_request_account.h
@@ -70,7 +70,7 @@ class CONTENT_EXPORT IdentityRequestAcco
 
   // The identity provider to which the account belongs to. This is not set in
   // the constructor but instead set later.
-  scoped_refptr<IdentityProviderData> identity_provider = nullptr;
+  IdentityProviderData* identity_provider = nullptr;
 
   std::string id;
   // E.g. email or phone number
--- a/device/fido/cable/cable_discovery_data.cc
+++ b/device/fido/cable/cable_discovery_data.cc
@@ -118,8 +118,8 @@ Pairing::~Pairing() = default;
 std::optional<std::unique_ptr<Pairing>> Pairing::Parse(
     const cbor::Value& cbor,
     tunnelserver::KnownDomainID domain,
-    base::span<const uint8_t, kQRSeedSize> local_identity_seed,
-    base::span<const uint8_t, 32> handshake_hash) {
+    std::span<const uint8_t, kQRSeedSize> local_identity_seed,
+    std::span<const uint8_t, 32> handshake_hash) {
   if (!cbor.is_map()) {
     return std::nullopt;
   }
--- a/device/fido/cable/cable_discovery_data.h
+++ b/device/fido/cable/cable_discovery_data.h
@@ -141,8 +141,8 @@ struct COMPONENT_EXPORT(DEVICE_FIDO) Pai
   static std::optional<std::unique_ptr<Pairing>> Parse(
       const cbor::Value& cbor,
       tunnelserver::KnownDomainID domain,
-      base::span<const uint8_t, kQRSeedSize> local_identity_seed,
-      base::span<const uint8_t, 32> handshake_hash);
+      std::span<const uint8_t, kQRSeedSize> local_identity_seed,
+      std::span<const uint8_t, 32> handshake_hash);
 
   static bool CompareByMostRecentFirst(const std::unique_ptr<Pairing>&,
                                        const std::unique_ptr<Pairing>&);
--- a/extensions/browser/api/extensions_api_client.cc
+++ b/extensions/browser/api/extensions_api_client.cc
@@ -6,6 +6,18 @@
 
 #include "build/build_config.h"
 #include "extensions/browser/api/messaging/native_message_host.h"
+#include "extensions/browser/guest_view/app_view/app_view_guest_delegate.h"
+#include "extensions/browser/guest_view/extension_options/extension_options_guest_delegate.h"
+#include "extensions/browser/guest_view/extensions_guest_view_manager_delegate.h"
+#include "extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest_delegate.h"
+#include "extensions/browser/guest_view/web_view/web_view_guest_delegate.h"
+#include "extensions/browser/guest_view/web_view/web_view_permission_helper_delegate.h"
+#include "extensions/browser/api/declarative_content/content_rules_registry.h"
+#include "extensions/browser/api/device_permissions_prompt.h"
+#include "extensions/browser/api/virtual_keyboard_private/virtual_keyboard_delegate.h"
+#include "extensions/browser/supervised_user_extensions_delegate.h"
+#include "extensions/browser/api/system_display/display_info_provider.h"
+#include "extensions/browser/api/messaging/native_message_port_dispatcher.h"
 
 namespace extensions {
 
--- a/net/base/pickle_traits.h
+++ b/net/base/pickle_traits.h
@@ -563,7 +563,7 @@ struct PickleTraits<T> {
   }
 
   static constexpr std::make_index_sequence<std::tuple_size_v<T>>
-      kIndexSequence;
+      kIndexSequence{};
 };
 
 // bool is treated specially by base::Pickle.
--- a/services/network/public/cpp/ad_auction/event_record.cc
+++ b/services/network/public/cpp/ad_auction/event_record.cc
@@ -47,16 +47,16 @@ std::optional<std::string> ParseEventTyp
 std::optional<std::vector<url::Origin>> ParseEligibleOrigins(
     const net::structured_headers::Dictionary& dict) {
   const auto it = dict.find("eligible-origins");
+  std::vector<url::Origin> result;
   if (it == dict.end()) {
     // "eligible-origins" is optional, so just return an empty list.
-    return {{}};
+    return {result};
   }
   const net::structured_headers::ParameterizedMember& parameterized_member =
       it->second;
   if (!parameterized_member.member_is_inner_list) {
     return std::nullopt;
   }
-  std::vector<url::Origin> result;
   for (const net::structured_headers::ParameterizedItem& parameterized_item :
        parameterized_member.member) {
     if (!parameterized_item.item.is_string()) {
--- a/third_party/angle/src/libANGLE/renderer/vulkan/vk_cache_utils.h
+++ b/third_party/angle/src/libANGLE/renderer/vulkan/vk_cache_utils.h
@@ -3011,7 +3011,7 @@ class UpdateDescriptorSetsBuilder final
             mCurrentVector = mDescriptorInfos.begin();
             mTotalSize     = 0;
         }
-        T *allocate(uint32_t count);
+        __attribute__((__used__)) T *allocate(uint32_t count);
 
         bool empty() const { return mTotalSize == 0; }
 
--- a/third_party/blink/renderer/core/dom/node.h
+++ b/third_party/blink/renderer/core/dom/node.h
@@ -1259,9 +1259,9 @@ class CORE_EXPORT Node : public EventTar
 
  private:
   static constexpr struct ParentNodeTag {
-  } kParentNodeTag;
+  } kParentNodeTag{};
   static constexpr struct ShadowHostTag {
-  } kShadowHostTag;
+  } kShadowHostTag{};
 
   using TaggedParentOrShadowHostNode =
       subtle::TaggedUncompressedMember<Node, ParentNodeTag, ShadowHostTag>;
--- a/third_party/blink/renderer/core/layout/physical_box_fragment.h
+++ b/third_party/blink/renderer/core/layout/physical_box_fragment.h
@@ -167,7 +167,7 @@ class CORE_EXPORT PhysicalBoxFragment fi
            !Style().ShouldIgnoreOverflowPropertyForInlineBlockBaseline();
   }
 
-  const GapGeometry* GetGapGeometry() const {
+  const blink::GapGeometry* GetGapGeometry() const {
     return rare_data_ ? rare_data_->gap_geometry_.Get() : nullptr;
   }
 
--- a/third_party/blink/renderer/core/offscreencanvas/offscreen_canvas.h
+++ b/third_party/blink/renderer/core/offscreencanvas/offscreen_canvas.h
@@ -24,6 +24,7 @@
 #include "third_party/blink/renderer/platform/heap/garbage_collected.h"
 #include "third_party/blink/renderer/platform/heap/prefinalizer.h"
 #include "ui/gfx/geometry/size.h"
+#include "third_party/blink/renderer/platform/text/layout_locale.h"
 
 namespace blink {
 
--- a/third_party/blink/renderer/modules/xr/xr_webgl_swap_chain.h
+++ b/third_party/blink/renderer/modules/xr/xr_webgl_swap_chain.h
@@ -10,6 +10,7 @@
 #include "third_party/blink/renderer/modules/xr/xr_swap_chain.h"
 #include "third_party/blink/renderer/platform/heap/garbage_collected.h"
 #include "third_party/blink/renderer/platform/heap/member.h"
+#include "third_party/blink/renderer/platform/graphics/static_bitmap_image.h"
 
 namespace blink {
 
--- a/third_party/blink/renderer/platform/fonts/string_truncator.cc
+++ b/third_party/blink/renderer/platform/fonts/string_truncator.cc
@@ -126,7 +126,7 @@ static String TruncateString(const Strin
   if (string.length() > STRING_BUFFER_SIZE) {
     keep_count = STRING_BUFFER_SIZE - 1;  // need 1 character for the ellipsis
     truncated_string =
-        CenterTruncateToBuffer(string, keep_count, string_buffer);
+        CenterTruncateToBuffer(string, keep_count, base::span(string_buffer));
   } else {
     keep_count = string.length();
     auto string_buffer_piece = base::span(string_buffer).first(keep_count);
--- a/third_party/blink/renderer/platform/graphics/filters/fe_color_matrix.cc
+++ b/third_party/blink/renderer/platform/graphics/filters/fe_color_matrix.cc
@@ -123,7 +123,7 @@ static sk_sp<cc::ColorFilter> CreateColo
       break;
     case FECOLORMATRIX_TYPE_MATRIX: {
       if (values.size() == kColorMatrixSize) {
-        base::span(matrix).copy_from(values);
+        base::span(std::span(matrix)).copy_from(values);
       }
       break;
     }
--- a/third_party/blink/renderer/platform/wtf/text/string_concatenate.h
+++ b/third_party/blink/renderer/platform/wtf/text/string_concatenate.h
@@ -45,7 +45,7 @@ class StringTypeAdapter<char> {
   DISALLOW_NEW();
 
  public:
-  explicit StringTypeAdapter<char>(char buffer) : buffer_(buffer) {}
+  explicit StringTypeAdapter(char buffer) : buffer_(buffer) {}
 
   size_t length() const { return 1; }
   bool Is8Bit() const { return true; }
@@ -64,7 +64,7 @@ class StringTypeAdapter<char> {
 template <>
 class StringTypeAdapter<LChar> : public StringTypeAdapter<char> {
  public:
-  explicit StringTypeAdapter<LChar>(LChar buffer)
+  explicit StringTypeAdapter(LChar buffer)
       : StringTypeAdapter<char>(buffer) {}
 };
 
@@ -73,7 +73,7 @@ class StringTypeAdapter<UChar> {
   DISALLOW_NEW();
 
  public:
-  explicit StringTypeAdapter<UChar>(UChar buffer) : buffer_(buffer) {}
+  explicit StringTypeAdapter(UChar buffer) : buffer_(buffer) {}
 
   size_t length() const { return 1; }
   bool Is8Bit() const { return buffer_ <= 0xff; }
@@ -96,7 +96,7 @@ class WTF_EXPORT StringTypeAdapter<const
   DISALLOW_NEW();
 
  public:
-  explicit StringTypeAdapter<const char*>(const char* buffer)
+  explicit StringTypeAdapter(const char* buffer)
       : buffer_(base::as_byte_span(std::string_view(buffer))) {}
 
   size_t length() const { return buffer_.size(); }
@@ -113,7 +113,7 @@ template <>
 class WTF_EXPORT StringTypeAdapter<const LChar*>
     : StringTypeAdapter<const char*> {
  public:
-  explicit StringTypeAdapter<const LChar*>(const LChar* buffer)
+  explicit StringTypeAdapter(const LChar* buffer)
       : StringTypeAdapter<const char*>(reinterpret_cast<const char*>(buffer)) {}
 };
 
@@ -121,7 +121,7 @@ template <>
 class WTF_EXPORT StringTypeAdapter<char*>
     : public StringTypeAdapter<const char*> {
  public:
-  explicit StringTypeAdapter<char*>(char* buffer)
+  explicit StringTypeAdapter(char* buffer)
       : StringTypeAdapter<const char*>(buffer) {}
 };
 
@@ -129,7 +129,7 @@ template <>
 class WTF_EXPORT StringTypeAdapter<LChar*>
     : public StringTypeAdapter<const LChar*> {
  public:
-  explicit StringTypeAdapter<LChar*>(LChar* buffer)
+  explicit StringTypeAdapter(LChar* buffer)
       : StringTypeAdapter<const LChar*>(buffer) {}
 };
 
--- a/tools/json_to_struct/aggregation.py
+++ b/tools/json_to_struct/aggregation.py
@@ -134,7 +134,7 @@ def _GenerateCCArray(type_name: str, agg
     Returns:
         str: The generated C++ array aggregation code.
     """
-  res = f'\nconst auto {aggregation.name} =\n'
+  res = f'\nconst std::array<const {type_name}*, {len(aggregation.elements)}> {aggregation.name} =\n'
   res += f'    std::array<const {type_name}*, {len(aggregation.elements)}>'
 
   res += '({{\n'
@@ -157,7 +157,7 @@ def _GenerateCCMap(type_name: str, aggre
     """
   key_type = aggregation.map_key_type
 
-  res = f'\nconst auto {aggregation.name} =\n'
+  res = f'\nconst base::fixed_flat_map<{key_type}, const {type_name}*, {len(aggregation.GetSortedMapElements())}> {aggregation.name} =\n'
   res += f'    base::MakeFixedFlatMap<{key_type}, const {type_name}*>'
 
   res += '({\n'
--- a/ui/accessibility/platform/ax_platform_node_id.h
+++ b/ui/accessibility/platform/ax_platform_node_id.h
@@ -57,7 +57,7 @@ class AXPlatformNodeId
 
 namespace std {
 template <>
-struct std::hash<ui::AXPlatformNodeId>
-    : std::hash<base::StrongAlias<class ui::AXPlatformNodeIdTag, int32_t>> {};
+struct hash<ui::AXPlatformNodeId>
+    : hash<base::StrongAlias<class ui::AXPlatformNodeIdTag, int32_t>> {};
 }  // namespace std
 #endif  // UI_ACCESSIBILITY_PLATFORM_AX_PLATFORM_NODE_ID_H_
--- a/build/config/compiler/BUILD.gn
+++ b/build/config/compiler/BUILD.gn
@@ -1818,7 +1818,10 @@

   if (!is_clang) {
     # Disable warnings that are known to fail 'gcc' build.
-    cflags += [ "-Wno-changes-meaning" ]
+    cflags_cc += [ "-Wno-changes-meaning" ]
+
+    # Reduce g++ memory usage at the cost of less verbose error messages.
+    cflags_cc += [ "-ftrack-macro-expansion=0" ]
   }

   if (is_win) {
--- a/chrome/browser/privacy_sandbox/notice/desktop_view_manager_interface.h
+++ b/chrome/browser/privacy_sandbox/notice/desktop_view_manager_interface.h
@@ -3,6 +3,8 @@
 // found in the LICENSE file.
 #ifndef CHROME_BROWSER_PRIVACY_SANDBOX_NOTICE_DESKTOP_VIEW_MANAGER_INTERFACE_H_
 #define CHROME_BROWSER_PRIVACY_SANDBOX_NOTICE_DESKTOP_VIEW_MANAGER_INTERFACE_H_
+
+#include <optional>
 #include <vector>

 #include "base/memory/raw_ptr.h"
--- a/content/browser/webid/fedcm_accounts_fetcher.cc
+++ b/content/browser/webid/fedcm_accounts_fetcher.cc
@@ -450,7 +450,7 @@
   idp_info->client_matches_top_frame_origin =
       client_metadata.client_matches_top_frame_origin;
   for (auto& account : accounts) {
-    account->identity_provider = idp_info->data;
+    account->identity_provider = idp_info->data.get();
   }

   federated_auth_request_impl_->OnFetchDataForIdpSucceeded(std::move(accounts),
--- a/sql/sandboxed_vfs.h
+++ b/sql/sandboxed_vfs.h
@@ -5,6 +5,7 @@
 #ifndef SQL_SANDBOXED_VFS_H_
 #define SQL_SANDBOXED_VFS_H_

+#include <cstring>
 #include <memory>
 #include <optional>

--- a/third_party/blink/renderer/platform/graphics/canvas_resource.h
+++ b/third_party/blink/renderer/platform/graphics/canvas_resource.h
@@ -29,6 +29,7 @@
 #include "third_party/skia/include/core/SkRefCnt.h"
 #include "ui/gfx/buffer_types.h"
 #include "ui/gfx/geometry/size.h"
+#include "third_party/blink/renderer/platform/graphics/static_bitmap_image.h"

 class GrBackendTexture;
 class SkSurface;
--- a/third_party/pdfium/xfa/fde/cfde_texteditengine.cpp
+++ b/third_party/pdfium/xfa/fde/cfde_texteditengine.cpp
@@ -19,6 +19,7 @@
 #include "xfa/fde/cfde_textout.h"
 #include "xfa/fde/cfde_wordbreak_data.h"
 #include "xfa/fgas/font/cfgas_gefont.h"
+#include "core/fxcrt/fx_string.h"

 namespace pdfium {

@@ -880,8 +881,8 @@
   length = std::min(length, text_length_ - start_idx);
   AdjustGap(start_idx + length, 0);

-  WideString ret(
-      WideStringView(pdfium::span(content_).subspan(start_idx, length)));
+  WideString ret;
+  ret = WideStringView(pdfium::span(content_).subspan(start_idx, length));

   if (add_operation == RecordOperation::kInsertRecord) {
     AddOperationRecord(std::make_unique<DeleteOperation>(this, start_idx, ret));
diff '--color=auto' -Naur --exclude out '--exclude=*.pyc' a/base/containers/fixed_flat_set.h chromium-138.0.7204.49/base/containers/fixed_flat_set.h
--- a/base/containers/fixed_flat_set.h
+++ b/base/containers/fixed_flat_set.h
@@ -88,7 +88,7 @@
 //   constexpr auto kSet = base::MakeFixedFlatSet<std::string_view>(
 //       base::sorted_unique, {"bar", "baz", "foo", "qux"});
 template <class Key, size_t N, class Compare = std::less<>>
-consteval fixed_flat_set<Key, N, Compare> MakeFixedFlatSet(
+constexpr fixed_flat_set<Key, N, Compare> MakeFixedFlatSet(
     sorted_unique_t,
     std::common_type_t<Key> (&&data)[N],
     const Compare& comp = Compare()) {
@@ -117,7 +117,7 @@
 // Note: Wrapping `Key` in `std::common_type_t` below requires callers to
 // explicitly specify `Key`, which is desired here.
 template <class Key, class Compare = std::less<>, size_t N>
-consteval fixed_flat_set<Key, N, Compare> MakeFixedFlatSet(
+constexpr fixed_flat_set<Key, N, Compare> MakeFixedFlatSet(
     std::common_type_t<Key> (&&data)[N],
     const Compare& comp = Compare()) {
   std::ranges::sort(data, comp);
diff '--color=auto' -Naur --exclude out '--exclude=*.pyc' a/cc/tiles/gpu_image_decode_cache.cc chromium-138.0.7204.49/cc/tiles/gpu_image_decode_cache.cc
--- a/cc/tiles/gpu_image_decode_cache.cc
+++ b/cc/tiles/gpu_image_decode_cache.cc
@@ -1131,7 +1131,7 @@
     last_use = base::TimeTicks::Now();
   }
   if (speculative_decode) {
-    speculative_decode_usage_stats_.emplace();
+    speculative_decode_usage_stats_.emplace(SpeculativeDecodeUsageStats{});
     speculative_decode_usage_stats_->speculative_decode_mip_level =
         upload_scale_mip_level;
     TRACE_EVENT_INSTANT2(TRACE_DISABLED_BY_DEFAULT("loading"),
