Re: patchworks and sourcehut for elfutils

2021-10-06 Thread Mark Wielaard
Hi, On Wed, Oct 06, 2021 at 06:25:04PM +0200, Mark Wielaard wrote: > To make patch tracking slighly easier there is now a patchwork instance > on sourceware that should show the status of all outstanding patches > sent to the mailinglist: > https://patchwork.sourceware.org/project/e

patchworks and sourcehut for elfutils

2021-10-06 Thread Mark Wielaard
Hi, To make patch tracking slighly easier there is now a patchwork instance on sourceware that should show the status of all outstanding patches sent to the mailinglist: https://patchwork.sourceware.org/project/elfutils/list/ It is a bit experimental and doesn't really come with documentation

Re: [PATCH] debuginfod: PR28242 - extend server http-response metrics

2021-10-06 Thread Mark Wielaard
Hi, On Fri, 2021-10-01 at 22:05 +0800, Di Chen via Elfutils-devel wrote: > From a574dfaf5d5636cbb7159a0118eb30e2c4aaa301 Mon Sep 17 00:00:00 > 2001 > From: Di Chen > Date: Fri, 1 Oct 2021 22:03:41 +0800 > Subject: [PATCH] debuginfod: PR28242 - extend server http-response > metrics BTW. If

Re: patch resend updated: PR28240, debuginfod cache for root

2021-10-05 Thread Mark Wielaard
Hi Frank, On Thu, 2021-09-30 at 14:36 -0400, Frank Ch. Eigler via Elfutils-devel wrote: > @@ -766,24 +766,14 @@ debuginfod_query_server (debuginfod_client *c, >if (rc != 0) > goto out; > > - /* If the target is already in the cache then we are done. */ > - int fd = open

Re: PATCH: testsuite debuginfod

2021-10-05 Thread Mark Wielaard
Hi Frank, On Thu, 2021-09-30 at 10:50 -0400, Frank Ch. Eigler via Elfutils-devel wrote: > commit 85602ff68179053f19a2005df4fc653a69757584 (HEAD -> master) > Author: Frank Ch. Eigler > Date: Thu Sep 30 10:48:00 2021 -0400 > > debuginfod testsuite: Use ! CMD syntax. > > Previously,

Re: [Bug debuginfod/27277] Describe retrieved files when verbose

2021-10-05 Thread Mark Wielaard
Hi Frank, On Wed, 2021-09-29 at 17:28 -0400, Frank Ch. Eigler wrote: > The problem with what we have now, with $DEBUGINFOD_VERBOSE, is that > the amount of output is huge. It is a debugging level trace. It's > not consumable by non-expert users OR by software. OK, but that seem two separate

Re: [Bug debuginfod/27277] Describe retrieved files when verbose

2021-09-29 Thread Mark Wielaard
Hi Frank, On Wed, 2021-09-22 at 16:33 -0400, Frank Ch. Eigler via Elfutils-devel wrote: > > from providing an interface to query what needs to be done to get > > some file (is it in cache, can it be retieved from a remote server, > > how > > big is it?) I don't think providing raw http headers is

Re: dwarf_aggregate_size doesn't work with arrays in partial CUs

2021-09-29 Thread Mark Wielaard
Hi KJ, On Sat, 2021-09-25 at 17:21 +1000, KJ Tsanaktsidis via Elfutils-devel wrote: > I'm writing a program that uses ptrace to poke at internal OpenSSL > data structures for another process. I'm using libdw to parse the > DWARF data for the copy of OpenSSL actually linked in to the target >

Re: debuginfod: Query debuginfod servers before printing response

2021-09-17 Thread Mark Wielaard
Hi Noah, On Fri, Sep 17, 2021 at 01:38:50PM -0400, Noah Sanci via Elfutils-devel wrote: > Here is an updated patch, removing checks for http response headers > which debuginfod is not guaranteed > to respond with. These headers caused tests to fail despite receiving > sufficient headers to

Re: debuginfod: Query debuginfod servers before printing response

2021-09-17 Thread Mark Wielaard
Hi Noah, On Fri, 2021-09-17 at 10:55 -0400, Noah Sanci via Elfutils-devel wrote: > While checking PR27277 on some buildbots, greping would fail in > run-debuginfod-response-headers.sh. This was because querying the > debuginfod server occurs after checking if the response headers had > arrived,

Re: Buildbot failure in Wildebeest Builder on whole buildset

2021-09-16 Thread Mark Wielaard
Hi, On Thu, 2021-09-16 at 15:00 +, build...@builder.wildebeest.org wrote: > The Buildbot has detected a new failure on builder elfutils-centos- > x86_64 while building elfutils. > Full details are available at: > https://builder.wildebeest.org/buildbot/#builders/1/builds/839 > > Buildbot

Re: [Bug debuginfod/27277] Describe retrieved files when verbose

2021-09-16 Thread Mark Wielaard
Hi Noah, On Mon, 2021-09-13 at 16:07 -0400, Noah Sanci via Elfutils-devel wrote: > On Sun, Sep 12, 2021 at 3:08 PM Mark Wielaard wrote: > > > run-debuginfod-fd-prefetch-caches.sh was updated so that it doesn't > > > trip and fail as previously greping for a value t

Re: [Bug debuginfod/28034] client-side %-escape url characters

2021-09-16 Thread Mark Wielaard
Hi Noah, On Mon, 2021-09-13 at 14:11 -0400, Noah Sanci via Elfutils-devel wrote: > Quick arithmetic change to the original patch with an updated commit > message. Thanks for commenting this, it is easy to make an off-by-one (or two) error. > Previously, urls containing '/', so most urls, would

Re: Buildbot failure in Wildebeest Builder on whole buildset

2021-09-14 Thread Mark Wielaard
Hi, On Mon, 2021-09-13 at 11:06 +0200, Mark Wielaard wrote: > On Sun, Sep 12, 2021 at 11:16:09PM +, > build...@builder.wildebeest.org wrote: > > The Buildbot has detected a new failure on builder elfutils-fedora- > > s390x while building elfutils. > > Fu

Re: Buildbot failure in Wildebeest Builder on whole buildset

2021-09-13 Thread Mark Wielaard
On Sun, Sep 12, 2021 at 11:16:09PM +, build...@builder.wildebeest.org wrote: > The Buildbot has detected a new failure on builder elfutils-fedora-s390x > while building elfutils. > Full details are available at: > https://builder.wildebeest.org/buildbot/#builders/10/builds/795 > >

[COMMITTED] debuginfod: Add endl after "fdcache emergency flush for filling tmpdir" log

2021-09-12 Thread Mark Wielaard
Without the endl the next log message will not start on its own line. Signed-off-by: Mark Wielaard --- debuginfod/ChangeLog | 5 + debuginfod/debuginfod.cxx | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/debuginfod/ChangeLog b/debuginfod/ChangeLog index 7e221f54

Re: Buildbot failure in Wildebeest Builder on whole buildset

2021-09-12 Thread Mark Wielaard
Hi, On Sun, Sep 12, 2021 at 09:56:39PM +, build...@builder.wildebeest.org wrote: > The Buildbot has detected a new failure on builder elfutils-centos-x86_64 > while building elfutils. > Full details are available at: > https://builder.wildebeest.org/buildbot/#builders/1/builds/835 > >

Re: [PATCH] lib: Make error.c more like error(3)

2021-09-12 Thread Mark Wielaard
Hi Colin, On Fri, Sep 10, 2021 at 11:07:16AM -0700, Colin Cross via Elfutils-devel wrote: > Fix some issues with the error reimplementation to make it match > the specification for error(3). > > Flush stdout before printing to stderr. Also flush stderr afterwards, > which is not specified in

Re: [PATCH] libdw: set address size, offset size and version on fake CUs

2021-09-12 Thread Mark Wielaard
Hi, On Wed, Sep 08, 2021 at 10:14:02PM +0200, Mark Wielaard wrote: > There are three "fake CUs" that are associated with .debug_loc, > .debug_loclist and .debug_addr. These fake CUs are used for "fake > attributes" to provide values that are store

Re: [Bug debuginfod/27277] Describe retrieved files when verbose

2021-09-12 Thread Mark Wielaard
Hi Noah, On Fri, Sep 10, 2021 at 02:22:00PM -0400, Noah Sanci via Elfutils-devel wrote: > From 979f19eb4fd7a35ace4ddafed103922559b93120 Mon Sep 17 00:00:00 2001 > From: Noah Sanci > Date: Wed, 28 Jul 2021 14:46:05 -0400 > Subject: [PATCH 2/2] debuginfod: PR27277 - Describe retrieved files when >

Re: [Bug debuginfod/28034] client-side %-escape url characters

2021-09-12 Thread Mark Wielaard
andler_cb. > https://sourceware.org/bugzilla/show_bug.cgi?id=28034. > > On Wed, Sep 8, 2021 at 9:38 AM Mark Wielaard wrote: > > /* Initialize each handle. */ > > for (int i = 0; i < num_urls; i++) > > > > So you only need to escape once. You of course then need

Re: [PATCH] read inlining info in an NVIDIA extended line map (was: Extension ...)

2021-09-10 Thread Mark Wielaard
Hi John, On Fri, 2021-09-10 at 10:49 -0500, John Mellor-Crummey via Elfutils- devel wrote: > My previous patch submission seems to have been overlooked as > buildbot issues consumed several days this week. However, discussion > in the mailing list now seems to have moved on beyond my submission >

buildbot status

2021-09-10 Thread Mark Wielaard
Hi, Since the splitting of the mega debuginfod tests into separate testcases we have seen some instability of the buildbot. I believe that is mostly solved now. I do sometimes see one of the run-debuginfod-federation- {link,metric,sqlite}.sh tests fail when they are testing propagating of a

Re: [COMMITTED] tests: Cleanup error handling and don't share cache between servers/client

2021-09-09 Thread Mark Wielaard
Hi, On Thu, Sep 09, 2021 at 06:58:10PM +0200, Mark Wielaard wrote: > Also the error handler for debuginfod tests wasn't called when a > command inside a function failed. Since testrun is a function, there > would be no metrics or error log files listed if the testrun command > fa

[COMMITTED] tests: Cleanup error handling and don't share cache between servers/client

2021-09-09 Thread Mark Wielaard
or error log files listed if the testrun command failed. Making it hard to see what went wrong. Fix this by using set -o errtrace Signed-off-by: Mark Wielaard --- tests/ChangeLog| 11 +++ tests/debuginfod-subr.sh | 14 - tests/run

Re: [PATCH v2] findtextrel: do not use unbound alloca

2021-09-09 Thread Mark Wielaard
Hi Dmitry, On Thu, 2021-09-09 at 14:31 +0300, Dmitry V. Levin wrote: > This fixes the following compilation warning: > > findtextrel.c:184:1: warning: stack usage might be unbounded [- > Wstack-usage=] > > Signed-off-by: Dmitry V. Levin > --- > > v1 introduced a memory leak, so in v2 I

Re: [PATCH] findtextrel: do not use unbound alloca

2021-09-08 Thread Mark Wielaard
Hi Dmitry, On Mon, Sep 06, 2021 at 06:00:00PM +, Dmitry V. Levin wrote: > This fixes the following compilation warning: > > findtextrel.c:184:1: warning: stack usage might be unbounded [-Wstack-usage=] And it simplifies the code a lot IMHO. Looks good, please apply. Thanks, Mark

Re: [PATCH 2/2] Use xasprintf instead of asprintf followed by error(EXIT_FAILURE)

2021-09-08 Thread Mark Wielaard
Hi Dmitry, On Mon, Sep 06, 2021 at 10:00:00AM +, Dmitry V. Levin wrote: > + * color.c (parse_opt): Replace asprintf followed by error(EXIT_FAILURE) > + with xasprintf. > + * objdump.c (show_disasm): Replace asprintf followed by > + error(EXIT_FAILURE) with xasprintf. > +

Re: [PATCH 1/2] Introduce xasprintf

2021-09-08 Thread Mark Wielaard
Hi Dmitry, On Mon, Sep 06, 2021 at 10:00:00AM +, Dmitry V. Levin wrote: > Similar to other x* functions, xasprintf is like asprintf except that > it dies in case of an error. Looks useful and the implementation seems correct. Please apply. Thanks, Mark

Re: [PATCH] Remove redundant casts of memory allocating functions returning void *

2021-09-08 Thread Mark Wielaard
Hi Dmitry, On Mon, Sep 06, 2021 at 08:00:00AM +, Dmitry V. Levin wrote: > Return values of functions returning "void *", e.g. calloc, malloc, > realloc, xcalloc, xmalloc, and xrealloc, do not need explicit casts. This does make the code slightly more readable. And the cast doesn't really add

Re: [PATCH] src: add -Wno-error=stack-usage= to AM_LDFLAGS

2021-09-08 Thread Mark Wielaard
Hi Dmitry, On Mon, Sep 06, 2021 at 03:59:05AM +0300, Dmitry V. Levin wrote: > While -Wstack-usage= is already excluded from AM_CFLAGS for various > tools in src using *_no_Wstack_usage variables, this obviously does not > help when LTO is enabled, so add -Wno-error=stack-usage= to AM_LDFLAGS >

Re: Adding a new section to an ELF file aborts with Assertion `shdr != NULL'

2021-09-08 Thread Mark Wielaard
Hi Alex, On Sat, Sep 04, 2021 at 08:38:51AM +, Alexander Egorenkov via Elfutils-devel wrote: > i'm facing an issue with libelf when i try to add a new section to an > ELF file. > > How to reproduce the issue: > 1. Create a simple ELF file with libelf containing only 2 sections, NULL and > a

Re: [Bug debuginfod/27277] Describe retrieved files when verbose

2021-09-08 Thread Mark Wielaard
Hi Noah, Looks like I reviewed a slightly older version earlier. Could you merge the reviewes/changes for both version in a new version of this patch? On Fri, Aug 27, 2021 at 02:38:27PM -0400, Noah Sanci via Elfutils-devel wrote: > From ed7638571f188e346dd466c195b9ebda028d1c65 Mon Sep 17

[PATCH] libdw: set address size, offset size and version on fake CUs

2021-09-08 Thread Mark Wielaard
be retrieved for gcc/clang, DWARF4/5 and 32/64 bits objects. https://sourceware.org/bugzilla/show_bug.cgi?id=28220 Signed-off-by: Mark Wielaard --- libdw/dwarf_begin_elf.c | 32 ++-- tests/Makefile.am | 13 ++- tests/run-varlocs-vars.sh

Re: [Bug debuginfod/27277] Describe retrieved files when verbose

2021-09-08 Thread Mark Wielaard
Hi Noah, On Wed, 2021-08-25 at 14:08 -0400, Noah Sanci via Elfutils-devel wrote: > There appear to exist use cases that intend to simply check for the > existence of content in a debuginfod server, without actually > downloading it. In HTTP land, the HEAD operation is the natural > expression of

Re: [Bug debuginfod/28034] client-side %-escape url characters

2021-09-08 Thread Mark Wielaard
Hi Noah, This looks good, but the description is not really what the patch does. It is part of the PR28034 fix, but repeating that problem statement doesn't really make clear what this patch is about. Could explain in the commit message that curl_easy_escape () also escapes '/' to '%2F' and that

Re: Buildbot failure in Wildebeest Builder on whole buildset

2021-09-07 Thread Mark Wielaard
Hi, On Tue, Sep 07, 2021 at 11:34:16AM +0300, Dmitry V. Levin wrote: > On Tue, Sep 07, 2021 at 02:12:18AM +0200, Mark Wielaard wrote: > [...] > > Subject: [PATCH] tests: Make sure to wait for initial scan and groom cycle > > > > At startup the debuginfod server does a sc

Re: Buildbot failure in Wildebeest Builder on whole buildset

2021-09-06 Thread Mark Wielaard
Hi, On Mon, Sep 06, 2021 at 10:02:11PM +0200, Mark Wielaard wrote: > Still looking for explanations of the other FAILS (which I cannot > reproduce locally). I think I finally got it. The thing that all the tests that are (sometimes) failing have in commen is that they use SIGUSR1 or S

[COMMITTED] tests: Only export DEBUGINFOD_URLS when necessary

2021-09-06 Thread Mark Wielaard
-debuginfod-federation-sqlite.sh | 1 - 6 files changed, 15 insertions(+), 5 deletions(-) diff --git a/tests/ChangeLog b/tests/ChangeLog index 14eb4d98..436a1c45 100644 --- a/tests/ChangeLog +++ b/tests/ChangeLog @@ -1,3 +1,13 @@ +2021-09-06 Mark Wielaard + + * run-debuginfod-archive-groom.sh

Re: Buildbot failure in Wildebeest Builder on whole buildset

2021-09-06 Thread Mark Wielaard
On Mon, Sep 06, 2021 at 10:02:11PM +0200, Mark Wielaard wrote: > This doesn't really explain the above failures, but there were still > two tests that didn't use their own debuginfod client cache. Also one > set a useless, but confusing DEBUGINFOD_URLS. > > Still looking f

Re: Buildbot failure in Wildebeest Builder on whole buildset

2021-09-06 Thread Mark Wielaard
Hi, On Mon, Sep 06, 2021 at 05:07:50PM +0200, Mark Wielaard wrote: > On Sat, 2021-09-04 at 01:47 +0200, Mark Wielaard wrote: > > On Fri, Sep 03, 2021 at 02:08:40PM +, > > build...@builder.wildebeest.org wrote: > > > The Buildbot has detected a new failure on

Re: Buildbot failure in Wildebeest Builder on whole buildset

2021-09-06 Thread Mark Wielaard
On Sat, 2021-09-04 at 01:47 +0200, Mark Wielaard wrote: > On Fri, Sep 03, 2021 at 02:08:40PM +, > build...@builder.wildebeest.org wrote: > > The Buildbot has detected a new failure on builder elfutils-debian- > > armhf while building elfutils. > > Full details are ava

Re: Buildbot failure in Wildebeest Builder on whole buildset

2021-09-03 Thread Mark Wielaard
5/builds/603 > > Buildbot URL: https://builder.wildebeest.org/buildbot/ > > Worker for this Build: debian-armhf > > Build Reason: > Blamelist: Mark Wielaard > > BUILD FAILED: failed test (failure) So some of the builders did pass without any failures. But some had errors

Re: Buildbot failure in Wildebeest Builder on whole buildset

2021-09-03 Thread Mark Wielaard
le. Forgot to to add that to EXTRA_DIST. Hopefully fixed by: commit 70f36e32cfd83bdaf8a255613acff9ec2b0c0cde Author: Mark Wielaard Date: Fri Sep 3 13:10:43 2021 +0200 tests: Add debuginfod-subr.sh to EXTRA_DIST Signed-off-by: Mark Wielaard diff --git a/tests/ChangeLog b/tests/Ch

Re: debuginfod: Fracture tests/run-debuginfod-find.sh into specific tests

2021-09-03 Thread Mark Wielaard
r.sh: Added some general functions for above tests + 2021-08-04 Mark Wielaard PR28190 diff --git a/tests/Makefile.am b/tests/Makefile.am index 429649f4..3c302e72 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -211,7 +211,27 @@ if DEBUGINFOD check_PROGRAMS += debuginfod_build_i

Re: debuginfod: Fracture tests/run-debuginfod-find.sh into specific tests

2021-09-02 Thread Mark Wielaard
> + > 2021-07-28 Mark Wielaard > > * configure.ac (AC_CHECK_DECLS): Add reallocarray check. > diff --git a/Makefile.am b/Makefile.am > index 9c47afa9..3dfefa9f 100644 > --- a/Makefile.am > +++ b/Makefile.am > @@ -45,7 +45,7 @@ distcheck-hook: > chmod -R

Re: [PATCH v2] configure.ac: rework gnu99 ext check to allow clang

2021-08-31 Thread Mark Wielaard
Hi Adrian, On Mon, 2021-08-30 at 18:43 +0300, Adrian Ratiu wrote: > It is true that Clang does not support all gnu99 extensions [1], > but not all of them are used in the codebase and over time there > have been code cleanup efforts to improve Clang support. > > For example after commit 779c57ea

Using in-memory database (Was: Buildbot failure in Wildebeest Builder on whole buildset)

2021-08-28 Thread Mark Wielaard
o you think of the attached patch to implement this? Thanks, Mark>From 61554a292f753032490c349fedf47c4fb461e3ea Mon Sep 17 00:00:00 2001 From: Mark Wielaard Date: Sat, 28 Aug 2021 20:25:56 +0200 Subject: [PATCH] debuginfod: Turn -d ":memory:" into -d "file::memory:?cache=shared&

Re: Buildbot failure in Wildebeest Builder on whole buildset

2021-08-28 Thread Mark Wielaard
at. It opens the database twice in read/write and read-only mode. But :memory: is special and isn't always a new database, so the read-only copy doesn't see what is in the read/write copy. Cheers, Mark >From 17a9b1303e533c13aac6550844bdd68c669091bf Mon Sep 17 00:00:00 2001 From: Mark Wielaard Dat

Re: Buildbot failure in Wildebeest Builder on whole buildset

2021-08-28 Thread Mark Wielaard
tly and forgot to include a file. Fixed by: commit 610623458b7e98ed3e912e4b7ca8050f6ce4c698 Author: Mark Wielaard Date: Fri Aug 27 18:47:30 2021 +0200 Add lib/error.c This new file was supposed to be part of 4d6dd0e5a "lib: avoid potential problems with `-fno-common`". Signed-off-by: Mark Wielaard Cheers, Mark

Re: [PATCH] debuginfod: PR27917 - protect against federation loops

2021-08-27 Thread Mark Wielaard
Hi dichen, On Fri, 2021-08-20 at 20:44 +0800, Di Chen via Elfutils-devel wrote: > 1) moved the XFF check to handle_buildid. > 2) replace "livelock" with "deadlock" in the commit message. This looks very good, thanks not just for the code but for also including documentation and a testcase. I

Re: [PATCH] lib: avoid potential problems with `-fno-common`

2021-08-27 Thread Mark Wielaard
tra inode. I applied this, but messed up, sorry. I somehow dropped the lib/error.c file from the commit. When the buildbot yells and screams about a broken build that wasn't your fault. I pushed a followup commit to fix it: commit 610623458b7e98ed3e912e4b7ca8050f6ce4c698 (HEAD -> master) Author: Ma

Re: [PATCH] lib: remove unused `STROF` definition (NFC)

2021-08-27 Thread Mark Wielaard
Hi Saleem, On Fri, 2021-08-27 at 15:20 +, Saleem Abdulrasool via Elfutils-devel wrote: > This definition was in the fallback path, where `sys/cdefs.h` is not > available. Now that we have a single path through here, this macro gets > defined, though is unused. Remove the unused macro

Re: [PATCH v2] handle libc implemntations which do not provide `error.h`

2021-08-27 Thread Mark Wielaard
Hi Saleem, On Fri, 2021-08-27 at 08:24 -0700, Saleem Abdulrasool via Elfutils-devel wrote: > I think that this is not exactly ideal, as it will introduce a local > error_message_count in each translation unit, rather than giving it > vague linkage as I had hoped. I think it may be better to

Re: [PATCH] debuginfod, elfclassify: remove unnecessary header inclusion

2021-08-27 Thread Mark Wielaard
Hi Saleem, On Fri, 2021-08-20 at 18:21 +, Saleem Abdulrasool via Elfutils-devel wrote: > `error.h`'s inclusion was centralised into the `system.h` header. As > the implementation currently includes `system.h` already, the inclusion > of `error.h` is unnecessary. This prepares for a future

Re: [PATCH] lib: remove usage of `sys/cdefs.h`

2021-08-27 Thread Mark Wielaard
Hi Saleem, On Mon, 2021-08-23 at 08:23 -0700, Saleem Abdulrasool via Elfutils- devel wrote: > Yes, it seems that `STROF` can be removed as well. However, I'd > prefer to do that in a separate change. This way the change is a > separate clean up rather than just happens to come along with the >

Re: PR28240 patch: debuginfod-client negative-hit caching for root user

2021-08-26 Thread Mark Wielaard
Hi Frank, On Wed, Aug 18, 2021 at 06:39:07PM -0400, Frank Ch. Eigler via Elfutils-devel wrote: > commit d2cbc610a9e6552f663e29136d19597b8fdcf832 (HEAD -> master) > Author: Frank Ch. Eigler > Date: Wed Aug 18 18:29:34 2021 -0400 > > PR28240: debuginfod client root-safe negative caching >

Re: [Bug debuginfod/27277] Describe retrieved files when verbose

2021-08-24 Thread Mark Wielaard
Hi Noah, On Mon, 2021-08-23 at 11:11 -0400, Noah Sanci wrote: > I'm back to working on this patch, thanks for your patience and > comments. > > On Mon, Aug 9, 2021 at 5:27 AM Mark Wielaard wrote: > > Yes, separate the verbose printing of http headers (which I really do > &

Re: Using dwarf_getfuncs to get function from object stored in memory

2021-08-23 Thread Mark Wielaard
Hi Jeff, On Tue, Aug 17, 2021 at 03:40:08AM +, Jeff Lin via Elfutils-devel wrote: > I’ve written code to extract function from a shared object with > dwarf_begin api that finds the dwarf objects with the file > descriptor using dwarf_getfuncs. However, when I tried to parse the > same object

Re: Buildbot failure in Wildebeest Builder on whole buildset

2021-08-23 Thread Mark Wielaard
Hi, On Wed, Aug 11, 2021 at 11:16:18PM +, build...@builder.wildebeest.org wrote: > The Buildbot has detected a new failure on builder elfutils-centos-x86_64 > while building elfutils. > Full details are available at: > https://builder.wildebeest.org/buildbot/#builders/1/builds/799 Just

Re: [PATCH] configure.ac: drop unnecessary gnu99 extension checks

2021-08-23 Thread Mark Wielaard
Hi Adrian, On Tue, Aug 10, 2021 at 03:56:51PM +0300, Adrian Ratiu via Elfutils-devel wrote: > So in the interest of enabling Clang builds we remove the only > remaining blocker: the configure checks for nested functions and > variable length arrays which are also unused. Can we just remove the

Re: [Bug debuginfod/27277] Describe retrieved files when verbose

2021-08-09 Thread Mark Wielaard
Hi Frank, On Fri, 2021-08-06 at 14:54 -0400, Frank Ch. Eigler wrote: > > Yes, since the actual download might take a bit, it is nice to see > > the > > headers at the moment we commit to a server/download. aka here in > > the > > source: > > > > if (vfd >= 0 && !verbose_reported &&

Re: [Bug debuginfod/27277] Describe retrieved files when verbose

2021-08-06 Thread Mark Wielaard
Hi, On Thu, 2021-08-05 at 12:54 -0400, Frank Ch. Eigler wrote: > > I like the verbose http header output, but wish it was done earlier > > instead of after the download. Maybe when we commit to an url, if > > the > > info is available then. > > What do you mean "done"? Printed? Yes, since the

Re: [PATCH] debuginfod-doc: PR27950 - Remove redanduncies in man page.

2021-08-05 Thread Mark Wielaard
Hi Alice, (adding elfutils-devel back to CC so other know what we discussed) On Wed, 2021-08-04 at 17:36 -0400, Alice Zhang wrote: > Hi Mark, I made debuginfod-client-config.7 a relatively complete man page > and include only the part we need into other files by using > $.if \n(zZ=1 .ig zZ > ...

Re: [Bug debuginfod/27277] Describe retrieved files when verbose

2021-08-05 Thread Mark Wielaard
Hi Noah, On Wed, 2021-08-04 at 14:54 -0400, Noah Sanci via Elfutils-devel wrote: > The attached patch dumps the http headers retrieved from the > debuginfod server which a file was downloaded from. Some custom > headers are now returned such as X-FILE, X-FILE-SIZE, and X-ARCHIVE > to give some

Re: Buildbot failure in Wildebeest Builder on whole buildset

2021-08-05 Thread Mark Wielaard
On Wed, 2021-08-04 at 15:13 +, build...@builder.wildebeest.org wrote: > The Buildbot has detected a new failure on builder elfutils-centos- > x86_64 while building elfutils. > Full details are available at: > https://builder.wildebeest.org/buildbot/#builders/1/builds/796 > > Buildbot URL:

[PATCHv2] tests: Allow an extra pthread_kill frame in backtrace tests

2021-08-05 Thread Mark Wielaard
://sourceware.org/bugzilla/show_bug.cgi?id=28190 Signed-off-by: Mark Wielaard --- v2 Turns out some arches (aarch64) use __pthread_kill_internal instead of pthread_kill@... so use strstr instead of strncmp to determine whether the first frame is "pthread_kill". tests/ChangeLog | 6 ++

[PATCH] tests: Allow an extra pthread_kill frame in backtrace tests

2021-08-04 Thread Mark Wielaard
://sourceware.org/bugzilla/show_bug.cgi?id=28190 Signed-off-by: Mark Wielaard --- tests/ChangeLog | 6 + tests/backtrace.c | 62 +-- 2 files changed, 61 insertions(+), 7 deletions(-) diff --git a/tests/ChangeLog b/tests/ChangeLog index 3409..3bfd1ca2

Re: [Bug debuginfod/27982] added DEBUGINFOD_MAXSIZE and DEBUGINFOD_MAXTIME

2021-08-04 Thread Mark Wielaard
On Fri, 2021-07-30 at 09:39 -0400, Noah Sanci wrote: > Here is the real patch :). Looks good. Pushed. Thanks, Mark

Re: [PATCH] debuginfod-doc: PR27950 - Remove redanduncies in man page.

2021-08-04 Thread Mark Wielaard
Hi Frank, On Fri, 2021-07-30 at 08:47 -0400, Frank Ch. Eigler wrote: > > aha, ok, I understand now. This makes testing in-tree a bit more > > difficult. So the .so ./debuginfod-client-config.7 does work if you > > got > > into the doc/ subdirectory, then man ./debuginfod-find.1 does show > > the

Re: [PATCH] debuginfod-doc: PR27950 - Remove redanduncies in man page.

2021-07-30 Thread Mark Wielaard
Hi Frank, On Thu, 2021-07-29 at 10:36 -0400, Frank Ch. Eigler via Elfutils-devel wrote: > Is debuginfod-client-config.7 intended to be installed? If so it should > > be added to notrans_dist_man7_MANS in doc/Makefile.am, [...] > > Yeah. > > > If it isn't intended to be installed, maybe give it

Re: [Bug debuginfod/27982] added DEBUGINFOD_MAXSIZE and DEBUGINFOD_MAXTIME

2021-07-30 Thread Mark Wielaard
Hi Noah, On Thu, 2021-07-29 at 16:29 -0400, Noah Sanci wrote: > Why have MAXTIME default to LONG_MAX? Which is long, but different > > on > > different arches 32/64bit. If MAXSIZE == 0 means infinite, why not make > > MAXTIME=0 the same for consistency? > > Fixed. > > > The bug suggests to

Re: [PATCH] debuginfod-doc: PR27950 - Remove redanduncies in man page.

2021-07-29 Thread Mark Wielaard
Hi Alice, On Wed, 2021-07-28 at 15:42 -0400, Alice Zhang via Elfutils-devel wrote: > Create a new file, debuginfod-client-config.7, that holds all environment > variables and cache control files related info. Get rid of repetitive > definitions in three other files, instead, those files will

Re: [Bug debuginfod/27982] added DEBUGINFOD_MAXSIZE and DEBUGINFOD_MAXTIME

2021-07-29 Thread Mark Wielaard
Hi Noah, On Mon, 2021-07-26 at 14:56 -0400, Noah Sanci via Elfutils-devel wrote: > Please find the attached patch for pr 27982. DEBUGINFOD_MAXSIZE and > MAXTIME were added in this patch to allow users to use more > constraints when downloading debuginfo. This looks good. Some high level comments

Re: [Bug debuginfod/27983] ignore duplicate urls

2021-07-29 Thread Mark Wielaard
Hi Noah, On Wed, 2021-07-28 at 12:23 -0400, Noah Sanci via Elfutils-devel wrote: > This patch fixes a memory leak and slightly alters the PR27983 test, > isolating where its DEBUGINFO_URLS's duplicates are accessible, which > fixes a case of test failure on some systems. Great. I pushed my patch

Re: [Bug debuginfod/27983] ignore duplicate urls

2021-07-28 Thread Mark Wielaard
ouldn't add more and more interacting tests to it. But if we do maybe we should use the env DEBUGINFOD_URLS=... trick to minimize changing other tests in the same file. If you agree with the above two changes, could you resubmit the patch with those? Thanks, Mark From 61210f91afa4084a46bd0f84d12aa6d3

Re: [Bug debuginfod/27983] ignore duplicate urls

2021-07-23 Thread Mark Wielaard
Hi Noah, On Thu, 2021-07-22 at 15:22 -0400, Noah Sanci via Elfutils-devel wrote: > PR27983 improvements attached Please do mention the improvements you made. It really does help others see what you thought of. So in this case use asprintf instead of calloc plus sprintf, and (re)use tmpurl

Re: Buildbot failure in Wildebeest Builder on whole buildset

2021-07-22 Thread Mark Wielaard
On Thu, 2021-07-22 at 14:24 +, build...@builder.wildebeest.org wrote: > BUILD FAILED: failed update (failure) So this was some issue at sourceware, the git update broke for some builders. I have restarted the builds on the buildbot and things seems to be green again (s390x, amd64, i386 are

Re: [Bug debuginfod/28034] %-escape url characters

2021-07-22 Thread Mark Wielaard
Hi Noah, On Wed, 2021-07-21 at 15:44 -0400, Noah Sanci via Elfutils-devel wrote: > Here is a quick error fix. Thanks, looks good. Failure results should indeed be negative. For the record the actual fix was: diff --git a/debuginfod/debuginfod-client.c b/debuginfod/debuginfod-client.c index

Re: [Bug debuginfod/28034] %-escape url characters

2021-07-22 Thread Mark Wielaard
Hi Noah, On Wed, 2021-07-21 at 14:18 -0400, Noah Sanci via Elfutils-devel wrote: > > > > +Note: the client should %-escape characters in /SOURCE/FILE that > > > are not shown as "unreserved" in section 2.3 of RFC3986. > > Please read the new note just to ensure that it's reasonable, as my >

Re: [debuginfod] Minor run-debuginfod-find.sh test fixes

2021-07-22 Thread Mark Wielaard
Hi Noah, On Wed, 2021-07-21 at 15:26 -0400, Noah Sanci via Elfutils-devel wrote: > Updated ChangeLog > On Wed, Jul 21, 2021 at 3:06 PM Noah Sanci wrote: > > Here are some small fixes for run-debuginfod-find.sh. Looks good. Pushed. Thanks, Mark

Re: [Bug debuginfod/28034] %-escape url characters

2021-07-20 Thread Mark Wielaard
Hi Noah, On Tue, Jul 20, 2021 at 07:50:11PM +0200, Mark Wielaard wrote: > > + * run-debuginfod-find.sh: Added a test case ensuring files with % > > + escapable characters in their paths are accessible. > > There are also a couple of changes (fixes?) to the testcases. >

Re: [Bug debuginfod/28034] %-escape url characters

2021-07-20 Thread Mark Wielaard
Hi Noah, On Mon, Jul 19, 2021 at 10:53:17AM -0400, Noah Sanci via Elfutils-devel wrote: > When requesting some source files, some URL-inconvenient chars > sometimes pop up. Example from f33 libstdc++: > /buildid/44d8485cb75512c2ca5c8f70afbd475cae30af4f/source/usr/src/debug/ >

Re: [Bug debuginfod/27983] ignore duplicate urls

2021-07-20 Thread Mark Wielaard
Hi Noah, On Mon, Jul 19, 2021 at 09:31:17AM -0400, Noah Sanci wrote: > On Wed, Jul 14, 2021 at 12:36 PM Mark Wielaard wrote: > > You deduplicate the full URLs after they are fully constructed. Would > > it make sense to do the deduplication on server_url, maybe even as > &

Re: [PATCH] readelf: allow build with LLVM/clang

2021-07-15 Thread Mark Wielaard
Hi Timm, On Thu, Jul 15, 2021 at 07:46:15AM +0200, Timm Baeder via Elfutils-devel wrote: > FWIW, there is a different version of this patch at > https://sourceware.org/pipermail/elfutils-devel/2021q1/003674.html > that doesn't have those problems as far as I remember. Indeed, that looks more

Re: [PATCH] readelf: allow build with LLVM/clang

2021-07-14 Thread Mark Wielaard
Hi Tomasz, On Mon, Jul 12, 2021 at 11:59:41AM +0200, Tomasz Paweł Gajc via Elfutils-devel wrote: > convert last nested function to allow build with > LLVM/clang. Original patch comes from > https://github.com/OpenMandrivaAssociation/elfutils/blob/master/elfutils-0.185-clang.patch > Tested with

Re: [Bug debuginfod/27983] ignore duplicate urls

2021-07-14 Thread Mark Wielaard
Hi Noah, On Fri, Jul 09, 2021 at 03:12:18PM -0400, Noah Sanci via Elfutils-devel wrote: > From e37f49a0fd5f27907584b19336cd250d825acc98 Mon Sep 17 00:00:00 2001 > From: Noah Sanci > Date: Fri, 9 Jul 2021 14:53:10 -0400 > Subject: [PATCH] debuginfod: PR27983 - ignore duplicate urls > > Gazing

Re: [debuginfod/25978]

2021-07-14 Thread Mark Wielaard
Hi Noah, On Fri, Jul 09, 2021 at 01:05:39PM -0400, Noah Sanci via Elfutils-devel wrote: > That entire 'if' statement is a relic remaining from some ideas I had > about testing. I am resending the patch. Patch looks fine. Pushed. Thanks, Mark

Re: [debuginfod/25978]

2021-07-09 Thread Mark Wielaard
Hi Noah, On Thu, 2021-07-08 at 15:22 -0400, Noah Sanci via Elfutils-devel wrote: > Please find the patch information for pr25978 attached. Thanks for allowing zero as fd and mb size, updating the documentation and adding comments for where I misunderstood what the code was doing in the previous

Re: Working with ELF already loaded in memory

2021-07-09 Thread Mark Wielaard
Hi Sonal, On Fri, 2021-07-09 at 05:34 +, Sonal Santan wrote: > > Thanks for the pointer. I was looking for APIs inside > /usr/include/elfutils directory and > did not realize elfutils also places header files under /usr/include > directory. I am working > with this API now. Ah, yes, the

Re: [PATCH] PR27531: retry within default retry_limit will be supported. In debuginfod-client.c (debuginfod_query_server), insert a goto statement for jumping back to the beginning of curl handles set

2021-07-09 Thread Mark Wielaard
Hi Alice (adding elfutils-devel back to CC), On Thu, 2021-07-08 at 16:34 -0400, Alice Zhang wrote: > Hi, Mark, I made modifications as you suggested. I relocated the goto > statement and now the resources will be reused. That rearrangement is better than what I suggested with the free and

Re: PR27711

2021-07-08 Thread Mark Wielaard
Hi Noah, On Thu, 2021-07-08 at 10:48 -0400, Noah Sanci via Elfutils-devel wrote: > Find the patch information for pr27711 attached . Looks good. Pushed. Thanks, Mark

Re: PR: 25978

2021-07-08 Thread Mark Wielaard
Hi, On Thu, 2021-07-08 at 09:12 -0400, Frank Ch. Eigler wrote: > > If they are portions of the full fdcache shouldn't there be a check > > in the code that the specified fdcache_prefetch_fds and > > fdcache_prefetch_mbs aren't larger than fdcache_fds and fdcache_mbs? Or > > maybe they should be

Re: Working with ELF already loaded in memory

2021-07-08 Thread Mark Wielaard
Hi Sinal, On Thu, 2021-07-08 at 05:02 +, Sonal Santan via Elfutils-devel wrote: > Going through the libdw it appears that all APIs require either a > file handle or a file name of the ELF object to create a session. > Since we do not have access to the ELF file -- but rather the ELF > file

Re: [PATCH] PR27531: retry within default retry_limit will be supported. In debuginfod-client.c (debuginfod_query_server), insert a goto statement for jumping back to the beginning of curl handles set

2021-07-08 Thread Mark Wielaard
Hi Alice, On Tue, 2021-07-06 at 16:15 -0400, Alice Zhang via Elfutils-devel wrote: > Also introduced DEBUGINFOD_RETRY_LIMIT_ENV_VAR and default > DEBUGINFOD_RETRY_LIMIT(which is 2). > > Correponding test has been added to tests/run-debuginfod-find.sh > > Signed-off-by: Alice Zhang Nice. But

Re: PR: 25978

2021-07-08 Thread Mark Wielaard
Hi Noah, Like the other patch this really needs a commit message. If I understand the code correctly you are introducing another cache just for prefetches separate from the fdcache. But this new cache is a part of larger libarchive_fdcache so access to it is shared with the existing one, it is

Re: Buildbot failure in Wildebeest Builder on whole buildset

2021-07-08 Thread Mark Wielaard
tcheck. Fixed with the attached commit. Cheers, Mark From cdcd7dc3d20a002abe1ce318f9b9d0895eee1810 Mon Sep 17 00:00:00 2001 From: Mark Wielaard Date: Thu, 8 Jul 2021 11:44:26 +0200 Subject: [PATCH] tests: Fix EXTRA_DIST typo in testfile-largealign.o.bz2 Signed-off-by: Mark Wielaard --- tests/C

Re: [PATCH] libelf: Fix unaligned d_off offsets for input sections with large alignments

2021-07-08 Thread Mark Wielaard
Hi Andrei, On Wed, 2021-07-07 at 13:24 -0700, Andrei Homescu wrote: > I wrote this patch on behalf of someone else, so the copyright line > should be: > Copyright (C) 2021 Runsafe Security, Inc. OK, changed. > > The testcase already fails before the patch and succeeds after, but > > it would be

Re: PR27711

2021-07-07 Thread Mark Wielaard
Hi Noah, If possible please add a commit message and sent the patch using git send-email or git format-patch. Feel free to use the description of https://sourceware.org/bugzilla/show_bug.cgi?id=27711#c0 that Frank wrote as commit message. It clearly explains the intention. On Thu, 2021-07-01 at

Re: [PATCH] libelf: Fix unaligned d_off offsets for input sections with large alignments

2021-07-07 Thread Mark Wielaard
Hi Andrei, On Mon, 2021-06-28 at 18:26 -0700, Andrei Homescu wrote: > The mkl_memory_patched.o object inside the libmkl_core.a library from > the Intel Math Kernel Library version 2018.2.199 has this section > with an alignment of 4096 and offset of 0xb68: > [ 2] .data PROGBITS

<    4   5   6   7   8   9   10   11   12   13   >