From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by sourceware.org (Postfix) with ESMTP id 120403857039 for ; Wed, 20 Jan 2021 16:20:57 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 120403857039 Received: from mail-qv1-f71.google.com (mail-qv1-f71.google.com [209.85.219.71]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-21-zCujolxINj-Or1QVaTeXRw-1; Wed, 20 Jan 2021 11:20:55 -0500 X-MC-Unique: zCujolxINj-Or1QVaTeXRw-1 Received: by mail-qv1-f71.google.com with SMTP id cc1so23650911qvb.3 for ; Wed, 20 Jan 2021 08:20:55 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:organization :message-id:date:user-agent:mime-version:in-reply-to :content-language:content-transfer-encoding; bh=MIT+aunXKrGC7SvODf1F7QLjkwf0LZX4juw3nUAwRnI=; b=NfZCiv+cp/jVm8eUKd74J1c41Jt7k8LYmghA8IZbis7LDKcuH3F9RYtJnw0bEfDQsk 5rMdcUSHFQ9CFoiMC7o8GqMrgjz9lFumEiNQZPRi6S+FZDskFfnYAwmGn2TUMqYS6b4T HZ0l+jRAyDWHkmgYwKtpAexKAajoJ3gKihPNxlL3UqMR9N/7K1ImgxwKLo5vIGsyC6li wEHhw4u5EbctrLI1sS7muNTqlMBfhXGVo+BJKPmIkm+SmXTVzMQdUgeR0WNktKY+4gKW WLPR8YTz3UllyB9AwBe6AWAWHRfjSvUCFiOYPD5oBib5dzGm7/B4yM+PqAmiJcf5OyMF Rdcw== X-Gm-Message-State: AOAM533fUQZHFOEl6SWM6HvTjEA23cnAK90v5DmPa3+U2V4yHSaAAquz 8KVA5XFCtHZhrn3RYxwIClfsvsxXdtLkvZyZF462x2FJNz8qVObKW2FRj1FRMfG7XGfw+RdaXkX ofb0aADd4QwZdQv71bDRPw5gghXdlD9jbWKfEty7s7Jyd7pgUxvash3d/fmjcWg2d0smb X-Received: by 2002:a37:bd84:: with SMTP id n126mr10051237qkf.54.1611159654361; Wed, 20 Jan 2021 08:20:54 -0800 (PST) X-Google-Smtp-Source: ABdhPJy2Ccb7bAKkbEhg5V4A/mXIx2PetCYRq3R0BcXJsdiK69rrbl0VPB7kdkgVtDmbC8hR9mCY6w== X-Received: by 2002:a37:bd84:: with SMTP id n126mr10051220qkf.54.1611159654128; Wed, 20 Jan 2021 08:20:54 -0800 (PST) Received: from [192.168.1.16] (198-84-214-74.cpe.teksavvy.com. [198.84.214.74]) by smtp.gmail.com with ESMTPSA id l191sm1650700qke.7.2021.01.20.08.20.53 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 20 Jan 2021 08:20:53 -0800 (PST) Subject: Re: Lightning talk notes on glibc To: Fangrui Song , libc-help@sourceware.org References: <20210120074815.k6km6cmhrt4aknpo@gmail.com> From: Carlos O'Donell Organization: Red Hat Message-ID: Date: Wed, 20 Jan 2021 11:20:52 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.6.0 MIME-Version: 1.0 In-Reply-To: <20210120074815.k6km6cmhrt4aknpo@gmail.com> X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-5.6 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, NICE_REPLY_A, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: libc-help@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-help mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 20 Jan 2021 16:21:01 -0000 On 1/20/21 2:48 AM, Fangrui Song wrote: > The `-O2` issue is probably related to (1) expected inlining and (2) avoiding dynamic relocations. Not "probably related to" but absolutely about (2). And (1) is directly related to (2). If a function is not inlined you will generate relocations that cannot be handled during the bootstrap. The core bootstrap must be free of relocations in this sense. As Adhemerval points out there is value in minimizing the bootstrap set to allow for more complex debugging tools be used *after* the bootstrap. Like being able to run with sanitizers turned on. -- Cheers, Carlos.