From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12052 invoked by alias); 2 Apr 2014 21:12:36 -0000 Mailing-List: contact binutils-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: binutils-owner@sourceware.org Received: (qmail 12041 invoked by uid 89); 2 Apr 2014 21:12:35 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.9 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE,RP_MATCHES_RCVD,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mail-qg0-f51.google.com Received: from mail-qg0-f51.google.com (HELO mail-qg0-f51.google.com) (209.85.192.51) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-SHA encrypted) ESMTPS; Wed, 02 Apr 2014 21:12:33 +0000 Received: by mail-qg0-f51.google.com with SMTP id q108so848525qgd.10 for ; Wed, 02 Apr 2014 14:12:31 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=h2TKPTV4FdomT3IEyJGk5c7EZUxDAmc+cV4T7FfwiyA=; b=WJo/ZDlTJWd3xm9qBLkNHUjJ2WW9Q8qd4NcsyZeAU1fbf+9DhUN+VI0gk9VtDSFkbS aHLINbkyL//EI6kcy3z3rLc76IxEFr49xiyxYRJ2cXzN67D5wE8FXm86qscCkEzfrDCQ 0UlUfu2RB1pkfBQVhchIk3e6nCyAv3iZslXGcwzZhG+aQHy89wdvKt4P0qF9GPA7vKKC xqxmyuPqwpPO7P9s5rorTmlNwoDDZsSgfjJAeDgw8rPdJY6u8+mcjG092FH6walsoBrO 3jJXVt377YPsFrpL9CrLfhilSW7J5dVF6FaGbq580TQOij3NOjWQGmpxAoKY7WoVYILW Jykw== X-Gm-Message-State: ALoCoQmmuI4DfAN/jBsRYc+AN/KxzWZ4VmUbv5A8Me1DH4oQ5zONJUCC7tjFrucsf7J45z53WtFRNhP/YfiRFBRUxGkVRrP3DA6vkY+XMSYeFo1uIb5sF7DHDJooWyIXPnagC0MY47xpiZOfiyUJSFr84BSU2/7a7ClSrz5kTLONrhDY8L7Q+V8hjLkG8LmJaTOkmg3NsuwvAyPPnRd/tg2ZeYOFZ/mVrA== MIME-Version: 1.0 X-Received: by 10.229.81.71 with SMTP id w7mr3430052qck.8.1396473151554; Wed, 02 Apr 2014 14:12:31 -0700 (PDT) Received: by 10.140.98.130 with HTTP; Wed, 2 Apr 2014 14:12:31 -0700 (PDT) In-Reply-To: References: <20140402065443.GA18201@bubble.grove.modra.org> Date: Wed, 02 Apr 2014 21:12:00 -0000 Message-ID: Subject: Re: ICF on PowerPC Bug From: Cary Coutant To: Sriraman Tallam Cc: binutils , Ian Lance Taylor Content-Type: text/plain; charset=UTF-8 X-IsSubscribed: yes X-SW-Source: 2014-04/txt/msg00026.txt.bz2 > Attached patch to fix the PPC ICF problem by using references to the > reloc info vectors. Ok to commit? - Icf::Sections_reachable_info v = + Icf::Sections_reachable_info &v = (it_reloc_info_list->second).section_info; // Stores the information of the symbol pointed to by the reloc. - Icf::Symbol_info s = (it_reloc_info_list->second).symbol_info; + Icf::Symbol_info &s = (it_reloc_info_list->second).symbol_info; // Stores the addend and the symbol value. - Icf::Addend_info a = (it_reloc_info_list->second).addend_info; + Icf::Addend_info &a = (it_reloc_info_list->second).addend_info; // Stores the offset of the reloc. - Icf::Offset_info o = (it_reloc_info_list->second).offset_info; - Icf::Reloc_addend_size_info reloc_addend_size_info = + Icf::Offset_info &o = (it_reloc_info_list->second).offset_info; + Icf::Reloc_addend_size_info &reloc_addend_size_info = (it_reloc_info_list->second).reloc_addend_size_info; Icf::Sections_reachable_info::iterator it_v = v.begin(); Icf::Symbol_info::iterator it_s = s.begin(); Except for v and a, I think these can all be const, and their iterators can be const_iterators. OK with those changes. Thanks! -cary