From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-qv1-xf34.google.com (mail-qv1-xf34.google.com [IPv6:2607:f8b0:4864:20::f34]) by sourceware.org (Postfix) with ESMTPS id 671B43858D1E for ; Sat, 11 Mar 2023 14:48:56 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 671B43858D1E 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-qv1-xf34.google.com with SMTP id op8so5497381qvb.11 for ; Sat, 11 Mar 2023 06:48:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1678546136; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:from:to :cc:subject:date:message-id:reply-to; bh=li4orFLaglAub8IuYcmHoyek9X9SX5tlNozQp0TKP4A=; b=FG/4elCeiHF3ba3Rgt19pij5fifP+ng0MWVQYhtYCUzmoIiZ6yJNzCckIVitvB+YUz hGQAp2ecrmWEehOWrSn8pdrGF146O846h5NbCzeIXy4jhQXsBFTAYTAZEy935Xpn00+E etNDiwmWhPdQ1svOyWcFOwHGqOlwerFHS7Je+YXeT0k6qMw7V651T+3uODgJnllpNlZf Qz5ps0hwfXOyVytn/W5cl6/unmY9X9RkMtYmNep3hppADFPRWgsL03J9RqaZbpCAo6Vw DKkkKOIwcajD3bsWgdaZJgBYxo3B8kOO/0BPU4xLm5GQEgp4zTzwQ9hTacdEdSn0sTSi S53g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1678546136; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=li4orFLaglAub8IuYcmHoyek9X9SX5tlNozQp0TKP4A=; b=RZQB9Ba4oWlJKko3QarOhDrclLGbaR19dYI87agZ/fAM+eRHYQjjYup7V6AREk0ApF x3055uisqh7LRmhMNR5ujUj06OQQVKgy5vCkCFO0a6VQhONxvaqGs3HuWnILZkwaxXG5 vWM21fQUkAdeJifhFI0CM4vmyaveSwBMzs8PazPhY3gIM/GGilzmdBjan6QmlrydN978 tAoHp+hBfPYoSjEs8ypyeJAKWCxRwdpIDHSRM9twtuhojVM2yvcmeJHD0zdslXipRjkM sc7bTS+y0rvTNzni0N6CQDQc92NTbczpNQI1Qd+0MPI6S9IwiBRiQbeTNCPh92BuHd36 0RAg== X-Gm-Message-State: AO0yUKUH06iY3wXZvKBZfx7rztJlm40+SC/BQ5FTnPVn4VHcPsXCm6TJ OAd3iWjjdt4Twj3AaSHyXlc= X-Google-Smtp-Source: AK7set8VNUZ6txL9COW19jQBFllnbMrgbFKoG7Lug95HnfwYWgfmGiEPBDvu7bU2VC9ofGilVmKYKw== X-Received: by 2002:ad4:5c45:0:b0:56c:1574:6538 with SMTP id a5-20020ad45c45000000b0056c15746538mr4463518qva.42.1678546135406; Sat, 11 Mar 2023 06:48:55 -0800 (PST) Received: from spruce (c-71-206-142-238.hsd1.va.comcast.net. [71.206.142.238]) by smtp.gmail.com with ESMTPSA id d126-20020a37b484000000b007419f1561fesm1875547qkf.112.2023.03.11.06.48.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 11 Mar 2023 06:48:54 -0800 (PST) Date: Sat, 11 Mar 2023 09:48:53 -0500 From: Joe Simmons-Talbott To: Girish Joshi Cc: Florian Weimer , Girish Joshi via Libc-alpha Subject: Re: [PATCH] manual: scripts/documented.sh updated Message-ID: References: <877cw3kn65.fsf@oldenburg.str.redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Spam-Status: No, score=-9.8 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,GIT_PATCH_0,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP,URIBL_BLACK 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: On Sun, Mar 05, 2023 at 11:44:22AM +0530, Girish Joshi via Libc-alpha wrote: > Hi Florian, > Thanks for the review. > Turns out `diff` was not working with the given input files, this > patch fixes that. > I'm not sure if there is a list of people who volunteered to document > some specific functions. > So that comment from the output html is removed. > > Thanks! > Girish Joshi > > On Mon, Feb 27, 2023 at 11:26 PM Florian Weimer wrote: > > > > * Girish Joshi via Libc-alpha: > > > > > Hello, > > > As per the Missing Functions section of master Todo list[1], > > > scripts/documented.sh needs to be updated. > > > > > > Could someone please review this patch? > > > It removes the reference to linuxthreads/*.taxi files from the script > > > and removes the individual email address from the output. > > > > The script still doesn't seem to work, probably because the symbol names > > are not extract properly: > > > > 43120 T _dl_mcount_wrapper 43140 T _dl_mcount_wrapper_c 43320 W clogf 43320 W clogf32 > > 435c0 T _dl_find_object 43740 T realpath 43770 T quick_exit 43790 T _IO_vfscanf > > 437c0 T _pthread_cleanup_pus 437d0 T _pthread_cleanup_pop 437d0 W cprojf 437d0 W cprojf32 > > > > _dl_find_object is documented. > > > > _IO_vfscanf should be recognized as an alias of vfscanf, but this is > > more of an RFE than a bug fix. > > > > Thanks, > > Florian > > > From 5148c65ac07688dc5c3ee79a9b0f054232d64df3 Mon Sep 17 00:00:00 2001 > From: Girish Joshi > Date: Sun, 5 Mar 2023 11:15:00 +0530 > Subject: [PATCH] manual: scripts/documented.sh updated > > References for linuxthreads are removed from scripts/documented.sh. > Also removed the individual email address from the html output. > > Fixed the steps to retrive undocumented functions > --- > scripts/documented.sh | 44 +++++++++++++++++++++++++++++++------------ > 1 file changed, 32 insertions(+), 12 deletions(-) > mode change 100644 => 100755 scripts/documented.sh > > diff --git a/scripts/documented.sh b/scripts/documented.sh > old mode 100644 > new mode 100755 > index 7d1ffd4a92..dda6a32283 > --- a/scripts/documented.sh > +++ b/scripts/documented.sh > @@ -1,9 +1,15 @@ > #!/bin/sh > bindir=$1 > > -VERSION=1.0 > +# usage: scripts/documented.sh > +# for example: > +# scripts/documented.sh $HOME/build/glibc > > -grep -E -h @deftypefu?nx? *.texi ../linuxthreads/*.texi | > +VERSION=1.1 > + > +# Collect the documented functions from manual/*.texi files. > + > +grep -E -h @deftypefu?nx? manual/*.texi | > sed -e 's/@deftypefunx*[[:space:]]*\({[^{]*}\|[[:alnum:]_]*\)[[:space:]]*\([[:alnum:]_]*\).*/\2/' -e 's/@deftypefn {[^}]*function}*[[:space:]]*\({[^{]*}\|[[:alnum:]_]*\)[[:space:]]*\([[:alnum:]_]*\).*/\2/' -e '/^@/d' | > sed -e '/^obstack_/d' -e '/^\([lf]\|\)stat\(\|64\)$/d' -e '/^mknod$/d' | > sed -e '/^signbit$/d' -e '/^sigsetjmp$/d' | > @@ -12,9 +18,12 @@ sed -e '/^__fwriting$/d' -e '/^__fwritable$/d' -e '/^__fsetlocking$/d' | > sed -e '/^__freading$/d' -e '/^__freadable$/d' -e '/^__fpurge$/d' | > sed -e '/^__fpending$/d' -e '/^__flbf$/d' -e '/^__fbufsize$/d' | > sed -e '/^alloca$/d' | > +sed -r '/^\s*$/d' | > sort -u > DOCUMENTED > > -nm --extern --define $bindir/libc.so $bindir/math/libm.so $bindir/rt/librt.so $bindir/linuxthreads/libpthread.so $bindir/dlfcn/libdl.so $bindir/crypt/libcrypt.so $bindir/login/libutil.so | > + > +# extract the exported symbols from the libraries. > +nm --extern --define $bindir/libc.so $bindir/math/libm.so $bindir/rt/librt.so $bindir/nptl/libpthread.so $bindir/dlfcn/libdl.so $bindir/crypt/libcrypt.so $bindir/login/libutil.so | > grep -E " [TW] ([[:alpha:]]|_[[:alpha:]])" | > sed 's/\(@.*\)//' | > cut -b 12- | You can change this to 'cut -v 20-' and avoid the extra AVAILABLE_WITHOUT_OFFSET part. Thanks, Joe > @@ -25,6 +34,9 @@ sed -e '/^_mcleanup$/d' -e '/^_rpc_dtablesize$/d' -e '/^_seterr_reply$/d' | > sed -e '/^_nss/d' -e '/^_setjmp$/d' | > sort -u > AVAILABLE > > +# remove offset details from nm output > +cat AVAILABLE | cut -b 9- | sort -u > AVAILABLE_WITHOUT_OFFSET > + > cat < > > @@ -39,9 +51,7 @@ cat < which are not yet documented in the manual. This list is > automatically created and therefore might contain errors. Please > check the latest manual (available from the CVS archive) before > - starting to work. It might also be good to let me know in > - advanace on which functions you intend to work to avoid > - duplication.

> + starting to work.

> >

A few comments:

> > @@ -52,15 +62,23 @@ cat <
  • Similarly for the LFS functions (those ending in 64).
  • > > > -

    The function sombody already volunteered to document are marked > - with a reference to the person.

    > >
    > EOF > > n=0 > -diff -y --width=60 --suppress-common-lines DOCUMENTED AVAILABLE | > -expand | cut -b 33- | sed '/^[[:space:]]*$/d' | > + > +# get the list of undocumented functions > +grep -Fvx -f DOCUMENTED AVAILABLE_WITHOUT_OFFSET > UNDOCUMENTED_WITHOUT_OFFSET > + > +# get undocumented functions with offset info > +for func in `cat UNDOCUMENTED_WITHOUT_OFFSET` > +do > + grep " $func$" AVAILABLE >> UNDOCUMENTED > +done > + > +diff -y --width=120 --suppress-common-lines DOCUMENTED UNDOCUMENTED | > +expand | cut -b 61- | sed '/^[[:space:]]*$/d' | > while read name; do > line="$line > " > @@ -95,8 +113,10 @@ cat <
    $name
    > >
    > -
    Ulrich Drepper
    > -Generated on $(date) with documented.sh version $VERSION > + Generated on $(date) with documented.sh version $VERSION > > > EOF > + > +# cleanup the files > +rm -rf UNDOCUMENTED_WITHOUT_OFFSET AVAILABLE_WITHOUT_OFFSET AVAILABLE > -- > 2.39.2 >