From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-yw1-x1133.google.com (mail-yw1-x1133.google.com [IPv6:2607:f8b0:4864:20::1133]) by sourceware.org (Postfix) with ESMTPS id 1F77738582B0 for ; Fri, 17 Mar 2023 13:37:18 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 1F77738582B0 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-yw1-x1133.google.com with SMTP id 00721157ae682-544787916d9so93959317b3.13 for ; Fri, 17 Mar 2023 06:37:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1679060237; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=Ahhed/HVCsVg33v2eX9FfQIwyPZ9qlh37Uriqr8j/wc=; b=SB53RuUz6KKp4XbWcUN3lLwuCMI768LPeMMOihx4CF58z5vvgtXkggu5Wr/fbwuTMQ EsQUjH4qF53sJWwN3V/H4/mP0SLhpf03uGaqXTO/n+JZ5mJogNtYTekUtTbNNkmklbk7 YaAbsgpODm2vqQTrN0iECqyIXefO+fF//UNpYBODGPiBdK8Kce0mKHw1Sq5uA9VJ0dy+ KI+5rmqtmc0bR2aj5o1B+jHsXzEzzPITDR31GZD1WaaQaE35syl1cKQfzSWlAVqeE6KP kWugAUQTo/04ss6f/HzGRvd0fS5Z7QaGDHM4/h0yv/XCU2K7KhNRpL2RQz7wayIGNTmE S4Tg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679060237; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=Ahhed/HVCsVg33v2eX9FfQIwyPZ9qlh37Uriqr8j/wc=; b=n75d/oROnpBj4xhZRLzP3kMCrp1X1lE2dvwlrmoYqI51scRAj3n/koJcMvhyDxm6kT iqoyi2BIGivBWaM783pvumZtZDDcMMAhRAAcBMMIr1O/Zi5khvGqryTt4zvjJaII4oTQ QypkB464MV3Oz4krrxbCtGtAezbe9nRnfdjCk9K+39s0l7r+dJgdBWekHYm13rJ3KLBh abqdGvgpsOPAfqwyJkMaBaXA+PZ7cxK7ZAxy+MqYPZ0iCZ8GS2JyZCSZ3vd4irG8O1Io 4w0xevqKQkUmSVnpQ39Nh4zhRqw9WIBNdTXUHphOXJw3c1wlCf7eTRBKMj3PSyny0qxO VrJQ== X-Gm-Message-State: AO0yUKV+ZcR1A4SS1ZVvaYIu77WW7yVkJPiGdp5H9yf4LMUk+79Qcv3f rxoGojQVPYoC6FfuHIfq6n/1XEmtNpEvRCiqkAI= X-Google-Smtp-Source: AK7set8CZdmsRbuayI4+umhfakdvkuZ5qZ/mr56/vNa61wJNRuUw2LV1NBIZWrx+EU/VCnOiV/tDG3BqSHAjVCkGovY= X-Received: by 2002:a81:af4d:0:b0:52e:ac97:115f with SMTP id x13-20020a81af4d000000b0052eac97115fmr1920712ywj.5.1679060237366; Fri, 17 Mar 2023 06:37:17 -0700 (PDT) MIME-Version: 1.0 References: <6c8e0fc6-9e86-6fc7-433f-cf5df16a6b03@linaro.org> <87jzzi14fx.fsf@oldenburg.str.redhat.com> <7d1b9611-13d1-65f0-9b47-0f7d01cec66c@linaro.org> In-Reply-To: From: Abhijit Ray Chaudhury Date: Fri, 17 Mar 2023 19:07:05 +0530 Message-ID: Subject: Re: compiling glibc using -fasynchronous-unwind-tables for arm To: Adhemerval Zanella Netto Cc: Florian Weimer , Adhemerval Zanella Netto via Libc-help Content-Type: multipart/alternative; boundary="000000000000013b6b05f718adad" X-Spam-Status: No, score=-0.2 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: --000000000000013b6b05f718adad Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hello Adhemerval, I could compile glibc with -funwind-table instead of -fasynchronous-unwind-table. I noticed glibc uses one of the flags for different files. As far as stack unwinding is concerned , what is the difference between -fasynchronous-unwind-table and -funwind-table ? Thanking You, -Abhijit On Thu, Mar 16, 2023 at 4:29=E2=80=AFPM Abhijit Ray Chaudhury < abhijit.ray.chaudhury@gmail.com> wrote: > Hi, > > I think the problem lies with the precedence of seemingly conflicting > CFLAGS "-fasynchronous-unwind-tables -fno-unwind-tables" supplied to my > cross toolchain gcc. I compiled a simple C file with " > -fasynchronous-unwind-tables" , it generated an undefined symbol " > `__aeabi_unwind_cpp_pr0'" although compilation was successful without > -static flag. Then I compiled with " -fasynchronous-unwind-tables > -fno-unwind-tables", it still generated the undefined symbol " > `__aeabi_unwind_cpp_pr0'". It suggests " -fno-unwind-tables" does not > stop unwind information in the ELF when I have " > -fasynchronous-unwind-tables" . I then compiled with " -funwind-tables > -fno-unwind-table", I did not find undefined symbol " > `__aeabi_unwind_cpp_pr0'"in the generated ELF. > > So I will compile glibc with " -funwind-table" instead of " -fasynchronou= s-unwind-table" > and let you know the result. > > Do you see any problem with this approach ? > > Thanking You, > -Abhijit > > On Thu, Mar 16, 2023 at 1:22=E2=80=AFAM Adhemerval Zanella Netto < > adhemerval.zanella@linaro.org> wrote: > >> >> >> On 15/03/23 11:20, Florian Weimer wrote: >> > * Adhemerval Zanella Netto via Libc-help: >> > >> >> And I have tested with both: >> >> >> >> CC=3D"arm-glibc-linux-gnueabihf-gcc -fasynchronous-unwind-tables" >> >> >> >> and >> >> >> >> CC=3Darm-glibc-linux-gnueabihf-gcc CFLAGS=3D"-O2 >> -fasynchronous-unwind-tables" >> >> >> >> I also tested with gcc from ubuntu22 to check if this might something >> >> I haven't enabled on my toolchain (since I don't build all languages), >> >> but again I did not see any issue. >> > >> > It probably depends on whether libgcc.a has been built with >> > optimizations or not. >> >> Indeed this looks like >> https://sourceware.org/bugzilla/show_bug.cgi?id=3D29621 . >> Does the build work if you manually adds the -fasynchronous-unwind-tables >> on config.make? >> > --000000000000013b6b05f718adad--