From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id C5/yDFRkvmqt2yMAWB0awg (envelope-from ) for ; Thu, 01 Oct 2026 09:47:00 -0400 Authentication-Results: simark.ca; dkim=pass (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=RO2Afhq7; dkim-atps=neutral Received: by simark.ca (Postfix, from userid 112) id 207071E033; Thu, 01 Oct 2026 09:47:00 -0400 (EDT) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-3.4 required=5.0 tests=ARC_SIGNED,ARC_VALID,BAYES_00, DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED,RCVD_IN_VALIDITY_CERTIFIED_BLOCKED, RCVD_IN_VALIDITY_RPBL_BLOCKED,RCVD_IN_VALIDITY_SAFE_BLOCKED autolearn=ham autolearn_force=no version=4.0.1 Received: from vm01.sourceware.org (vm01.sourceware.org [38.145.34.32]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id 90F891E033 for ; Thu, 01 Oct 2026 09:46:59 -0400 (EDT) Received: from vm01.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 671344BB5900 for ; Thu, 1 Oct 2026 13:46:58 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 671344BB5900 Authentication-Results: sourceware.org; dkim=pass (1024-bit key, unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=RO2Afhq7 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by sourceware.org (Postfix) with ESMTP id 8EB714BB3B85 for ; Thu, 1 Oct 2026 13:46:34 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 8EB714BB3B85 Authentication-Results: sourceware.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 8EB714BB3B85 Authentication-Results: sourceware.org; arc=none smtp.remote-ip=170.10.129.124 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1790862394; cv=none; b=cKRkZlU6OkHasZ+mKWap+uzulm6iTGCJEhGcBDcI3/6i+hEjXvSWwOviMwT1SZMa3RZzMDyLTGWkhI6j0n2OYvIotVHqZNBPdbgNMdJPi8Lp+rBk7ERrFAv1DdMcP/1yLmS+OW2FORqFa6RijO75H9Of1i0PHsahjYtVymYkm/Q= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1790862394; c=relaxed/simple; bh=4cXsrXm5TeyGaE4eneSCdlBVl3PjIbLK9XRLrmlGfSQ=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=JY5oX4TTAsiCKxe7/3Mcdl/rnm1fDqHm9xa9LBreWflHodEWSyr/Ou3NMKad6H6tDnIUYILT3pVYu0ClQ4W/Qoq56ExIDT6o+pivTdYYn7ta+nVm4t4ZZiIkXiGmFjZsZe4YxdOmwRDRUykq25PA7KxS/YgNqv8s9JJQ6bXgXSE= ARC-Authentication-Results: i=1; sourceware.org; dkim=pass (1024-bit key, unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=RO2Afhq7 DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 8EB714BB3B85 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1790862393; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=jR6l8zSyoDucebEvZfe6uwR4SggQ0J3m7cZBcAfLUSg=; b=RO2Afhq7U+0bmuoFiy3afJoGFfuifnyVnQs0GamydKfXEta3o5piPI7UmtY7wbfYAZQZnJ 1ysp9bMdpmBFiQnszQcpY+TNkwQRHvdaAM4DTP1DuHflGpN96eCO4rzm1N4Acmjr6Ns9Im lygj3P8dfn3ca4NtPVWi5gdfNsD6Fh0= Received: from mail-wm1-f69.google.com (mail-wm1-f69.google.com [209.85.128.69]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-393-E0Airq_6PxGOxS6esklBZA-1; Thu, 01 Oct 2026 09:46:31 -0400 X-MC-Unique: E0Airq_6PxGOxS6esklBZA-1 X-Mimecast-MFC-AGG-ID: E0Airq_6PxGOxS6esklBZA_1790862390 Received: by mail-wm1-f69.google.com with SMTP id 5b1f17b1804b1-49953abe51fso42866965e9.1 for ; Thu, 01 Oct 2026 06:46:31 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1790862390; x=1791467190; h=content-type:mime-version:message-id:date:references:in-reply-to :subject:cc:to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject :date:message-id:reply-to:content-type; bh=jR6l8zSyoDucebEvZfe6uwR4SggQ0J3m7cZBcAfLUSg=; b=IHhcTOQe9uOHbVtiy+lEcdO8rMRIF6+ty5gXh8MQbDfazNLPaD6R2lq5sW7jeA+SBW Kd0wtyfzha0BWJD7h7vvU/13DzUuQPZQ8ojCvTRv91QXo71oMkpHbBUqzBMPOzZpwRXj 9+tZI31ivu9mpVjPecOUUp1E2rJsfq0ByNd92WlgqHSfE8MkRd/iWRBIWGg3zmipUn+V cjkcvHMhYoM3s4wzRD5Dt7iGjKt2gScmuIwrgVUz1HESELfe5fxYe9w9tb1Dij+Slj0e jUtaUzd/ZgTuOvFrKHrO6YyHoCjkGcmzjwTEBH+arB6y+pAPipzZZHjzvJHYXuRCpQ0W RUdg== X-Forwarded-Encrypted: i=1; AKwUvBw96+1R8w/TyTc/binQPFEybjO4BsVVq0Bm1lqPxhiH5IINhUiURgg0x57XsfgFJ6w9P7vzFTr6/pfsVw==@sourceware.org X-Gm-Message-State: AFuF++ksSNI8ZT3dSGBxr47uMt0tMlC4Z4oUKFLdmoUFWeWNhLfYGJTO pEpu58AoY6PQN70w0VtLHyizSG4Nn7qzue61AjitCPZxrlyX31EhpB9+++k8hY23xl6CplZ1URI BYamtG59xQuYZ85wmxkTdJ/PxtKMxn12A65ggbgCqqZmM8zAwGSMQ9sBVoPzaPqU= X-Gm-Gg: AYBFou2i87BQXG461ckr4/8YV7IcUmnqrfa/hIgsl34vg+kPUXpEr8kjHlbo/AIKsqX CkDxazFHjtesGgklQkctZ4Y6NtdSErcRnRRSIbLQynmUJT3wc0XS0dr3L9CU6A6a9a9KLpkTHHl Wemt+FwlUwnplzqsbZwm8N9oYOps8MUUyHUo4yA+h4Lq/D950hH6kR3Bj568IDTVJAR0Mpuf9A9 W8iqxbaKxW0OGaWN3UAwdKruiqD3/MbIHgt1UwQs4MSeLvKizu4Wlj8vctVyD20me/EhNsdGpXg OrFP5A4b/nEX+Lt60Yy/t4n+WEpebq1oT1FNQHhNRMZWHkLMBLPM2bn+shJUX/XT8//U X-Received: by 2002:a05:600c:45d3:b0:4a0:53e:b7d6 with SMTP id 5b1f17b1804b1-4a01aff8082mr73378335e9.16.1790862390291; Thu, 01 Oct 2026 06:46:30 -0700 (PDT) X-Received: by 2002:a05:600c:45d3:b0:4a0:53e:b7d6 with SMTP id 5b1f17b1804b1-4a01aff8082mr73377995e9.16.1790862389786; Thu, 01 Oct 2026 06:46:29 -0700 (PDT) Received: from localhost ([213.31.44.29]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-4a01f9482cdsm67651025e9.11.2026.10.01.06.46.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 01 Oct 2026 06:46:29 -0700 (PDT) From: Andrew Burgess To: simon.marchi@polymtl.ca, gdb-patches@sourceware.org Cc: Simon Marchi , "Rohr, Stephan" Subject: Re: [PATCH v2 05/11] gdb: simplify insertion in global_symbol_searcher::add_matching_symbols In-Reply-To: <20261001020952.698419-6-simon.marchi@polymtl.ca> References: <20260929194119.155169-1-simon.marchi@efficios.com> <20261001020952.698419-6-simon.marchi@polymtl.ca> Date: Thu, 01 Oct 2026 14:46:28 +0100 Message-ID: <871pa9zg7f.fsf@redhat.com> MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: _CXfKTVwYQsSOglCYU8Ax7u7IH-FzO1HvDShA9lRdtc_1790862390 X-Mimecast-Originator: redhat.com Content-Type: text/plain X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces~public-inbox=simark.ca@sourceware.org simon.marchi@polymtl.ca writes: > From: Simon Marchi > > std::set::insert does nothing if an equivalent element is already > in the set, so checking with find first is redundant. Replace find+insert > with emplace. LGTM. Approved-By: Andrew Burgess Thanks, Andrew