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 [170.10.129.124]) by sourceware.org (Postfix) with ESMTPS id 6F03E3858D1E for ; Mon, 24 Apr 2023 15:16:43 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 6F03E3858D1E Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1682349403; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=bpFSNTP/duFg4yV7QJZJ9V41gOwLEkE0iSQ+8dTNzHg=; b=ZMfd0O7ocZYT6GwWQinrpPalw2gZ4vdA0/06Q22+zF4O//VyqYxiuDTqwOrVlBXvdIweXR O5K2ahnR3TM6EwbeipgBNow5LKtxUwezgE6nCzrIe2Nhg0IlN71hCIn9pF1TqJK95anOcB 0CIGKWz3S7hR51Sx+WhF+JLHUm12Y1Y= Received: from mail-qt1-f200.google.com (mail-qt1-f200.google.com [209.85.160.200]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-161-YaRrO8uMO9O_TMcUzW3eCg-1; Mon, 24 Apr 2023 11:16:41 -0400 X-MC-Unique: YaRrO8uMO9O_TMcUzW3eCg-1 Received: by mail-qt1-f200.google.com with SMTP id d75a77b69052e-3ef4f29c9d1so12548181cf.0 for ; Mon, 24 Apr 2023 08:16:41 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682349400; x=1684941400; h=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=bpFSNTP/duFg4yV7QJZJ9V41gOwLEkE0iSQ+8dTNzHg=; b=csWNtUtfe6yRdh87nQkCb8aArrs7DHx57t3pHKYVv2Z+6Ss0ZoSWTSehcrCTa9owNL RAjkjIFgz69MNGh1p0QW3NkGvqxjnsNUifJygg/h9YdVS8yjKz9n/gd1Dp8YdICiTkwr KBqbmuaejHgHDC0Yd+QyuOKXK4eNFnNiMozjoGcI780a2wACN67TBnPPL/1ZX+z/7a2P 12NqzIy5BLi8o54OvK7H7nu0+N5qhw0yK9q0jR60EhP+ZXhVVbscTmgDS66zeld2ZlmZ dig0ozTrl4yaub9pGpwXhOHaWWafKMleqyL/kgc7nVtbbJ/DFbRPB1YTgKnAHerW+R4R f2Ng== X-Gm-Message-State: AAQBX9fMLjDDIxblUuQlOKgbEqpYpEkPbE773BIZqIFqhksmfWjT67ZV ZfztlfcmoZEzZXMKnYDYKWK34wrQHbOL/6sE/rbKs+/CFZGRyUmjQct/9bzYJw/nwhmQpu3zepF LyOXgeJAulEgUuehpsFeUSt1Pv5Z2m4fWAXi9Tww= X-Received: by 2002:a05:622a:1898:b0:3e6:707e:d3b1 with SMTP id v24-20020a05622a189800b003e6707ed3b1mr21493135qtc.0.1682349400625; Mon, 24 Apr 2023 08:16:40 -0700 (PDT) X-Google-Smtp-Source: AKy350bRxPKK3wl+Jl0GBhzYOz0VYR3+PMDPiT9h/ilZUOtnNT44XtMIkDlrw/5qPBTFBNgvY1RM20r7Dy6w5l3Oxks= X-Received: by 2002:a05:622a:1898:b0:3e6:707e:d3b1 with SMTP id v24-20020a05622a189800b003e6707ed3b1mr21493111qtc.0.1682349400322; Mon, 24 Apr 2023 08:16:40 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Jeff Johnston Date: Mon, 24 Apr 2023 11:16:29 -0400 Message-ID: Subject: Re: Placement of signgam in libc instead of libm To: newlib@sourceware.org X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: multipart/alternative; boundary="00000000000065728705fa167e86" X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE,TXREP,T_SCC_BODY_TEXT_LINE 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: --00000000000065728705fa167e86 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable I looked at this. I think it would ok to move as the method requires math.h and I would assume any users would have -lm specified. -- Jeff J. On Mon, Apr 24, 2023 at 4:52=E2=80=AFAM Corinna Vinschen wrote: > On Apr 20 16:20, Joel Sherrill wrote: > > Hi > > > > While double some checking that all references used by the long double > math > > routines Jennifer are resolved when linking, we have found a small > oddity. > > > > The file libc/reent/signgam.c is implemented as follows: > > > > int * > > __signgam (void) > > { > > return &_REENT_SIGNGAM(_REENT); > > } > > > > When TLS is enabled, the macro _REENT_SIGNGAM resolves to > > _tls_gamma_signgam which is in the file libm/math/w_lgamma.c. This > creates > > the first reference from libc to libm that I have ever seen and requires > > explicitly linking with -lm -lc when using lgamma(). > > > > Would anyone be opposed to moving this method to libm/math? > > Not me, but Jeff added this to libc for a reason, I guess...? > > > Corinna > > --00000000000065728705fa167e86--