Re: oss-fuzz

2019-12-22 Thread Mark Wielaard
afl-fuzz or some other fuzzing framework, or simply as extra testcase. Please also see: https://sourceware.org/git/?p=elfutils.git;f=CONTRIBUTING;hb=HEAD Cheers, Mark

Re: oss-fuzz

2019-12-26 Thread Mark Wielaard
and/or -fsanitize-coverage=trace-cmp (which I believe is command line compatible with what clang uses). Cheers, Mark > On Mon, Dec 23, 2019 at 3:12 AM Mark Wielaard wrote: > > > Hi Berkeley, > > > > On Fri, 2019-12-20 at 17:21 +0200, Berkeley Churchill wrote: > >

Re: rfc/patch: debuginfod client $DEBUGINFOD_PROGRESS env var

2020-01-02 Thread Mark Wielaard
s > flowing - at all - the rest will follow as rapidly as the network > allows. > > That suggests one timeout could be sufficient - the progress timeout > you the one you found - just not too short and not too fast. How about the attached (untested) patch? Cheers, Mark>From 9b90be

Re: [PATCH] libebl: Don't install libebl.a, libebl.h and remove backends from spec.

2020-01-08 Thread Mark Wielaard
Hi Dmitry, On Thu, 2020-01-02 at 03:02 +0300, Dmitry V. Levin wrote: > On Thu, Aug 29, 2019 at 11:43:58PM +0200, Mark Wielaard wrote: > > All archive members from libebl.a are now in libdw.a. We don't generate > > separate backend shared libraries anymore. So

Re: [PATCH] Do not install libdebuginfod.pc unless debuginfod is enabled

2020-01-08 Thread Mark Wielaard
on DEBUGINFOD. That looks correct. Pushed to master. Thanks, Mark

Re: rfc/patch: user-agent distro-description for debuginfod http traffic

2020-01-08 Thread Mark Wielaard
quot; DEBUGINFOD_CLIENT_USERAGENT_2' >> $@ Eep. We really should pick up this info during runtime instead of during build time. We do want a reproducible build. And this will most likely produce wrong information if the package build server is on a different OS or release than the OS/release it is producing packages for. uname -sm might be "stable", but probably not when cross- compiling. But where does lsb_release come from? I don't have that on my systems. Cheers, Mark >

Re: rfc/patch: user-agent distro-description for debuginfod http traffic

2020-01-08 Thread Mark Wielaard
rings on a couple of my systems out of the box: Linux/i686 4.19.0-6-686-pae debian/10 Linux/x86_64 3.10.0-1062.9.1.el7.x86_64 rhel/7.7 Linux/x86_64 4.19.0-5-amd64 pureos/9.0 Maybe something like that is usable? Cheers, Mark#include #include #include #include int main () { struct uts

Re: rfc/patch: debuginfod client $DEBUGINFOD_PROGRESS env var

2020-01-09 Thread Mark Wielaard
and make it 90s. That is more than twice the worst delay I ever observed. Pushed the attached. Cheers, Mark From b8d85ed024a745cff05e56c6337d95d654d5294a Mon Sep 17 00:00:00 2001 From: Mark Wielaard Date: Thu, 2 Jan 2020 17:02:42 +0100 Subject: [PATCH] debuginfod: Use DEBUGINFOD_TIMEOUT as

Re: [PATCH] libebl: Don't install libebl.a, libebl.h and remove backends from spec.

2020-01-09 Thread Mark Wielaard
Hi Dmitry, On Thu, 2020-01-09 at 02:25 +0300, Dmitry V. Levin wrote: > On Wed, Jan 08, 2020 at 03:09:32PM +0100, Mark Wielaard wrote: > > Even if you could use libasm.h, linking with libasm always was kind > > of > > useless since there was no supported way to create an Ebl h

[PATCH] doc: Fix DEBUGINFOD_PROGRESS description to just mention output on stderr.

2020-01-10 Thread Mark Wielaard
An earlier variant of the default progress function could write to any file. Which is still in the documentation. But the actual implementation just uses stderr. Fix the documentation to match. Signed-off-by: Mark Wielaard --- doc/ChangeLog | 5 + doc

Re: [PATCH] libebl: Don't install libebl.a, libebl.h and remove backends from spec.

2020-01-13 Thread Mark Wielaard
On Fri, Jan 10, 2020 at 12:43:44AM +0100, Mark Wielaard wrote: > On Thu, 2020-01-09 at 02:25 +0300, Dmitry V. Levin wrote: > > On Wed, Jan 08, 2020 at 03:09:32PM +0100, Mark Wielaard wrote: > > > Short term I propose the attached patch. > > > > Thanks, it works: th

Re: [PATCH] doc: Fix DEBUGINFOD_PROGRESS description to just mention output on stderr.

2020-01-13 Thread Mark Wielaard
On Fri, Jan 10, 2020 at 03:50:49PM +0100, Mark Wielaard wrote: > An earlier variant of the default progress function could write to any > file. Which is still in the documentation. But the actual implementation > just uses stderr. Fix the documentation to match. I pushed this to master.

Spurious run-debuginfod-find.sh failure on ppc64le (Was: Buildbot failure in Wildebeest Builder on whole buildset)

2020-01-17 Thread Mark Wielaard
h (exit status: 1) Full test-suite.log is at: https://builder.wildebeest.org/buildbot/#/builders/11/builds/412/steps/8/logs/test-suite_log Anyone a guess what is going on in this case? Thanks, Mark

Re: PR25394 patch: debuginfod groom vs. scan race condition

2020-01-20 Thread Mark Wielaard
I guess the comment "release the hounds" gets me confused. I don't know precisely what that means. Is this needed for correctness, or is it simply to have an hint that the scanners have ran because you register as an idler and so at this point you could only run if no scanner is running? But given you immediately tell them you are done a scanner could in theory start their work up again while you are doing your own traversal? Thanks, Mark

Re: PR25394 patch: debuginfod groom vs. scan race condition

2020-01-20 Thread Mark Wielaard
Yes, because that's ideal for concurrency: while one thread fts(3)'s > and enumerates the results, the scanner threads can process the > already enumerated files. OK. And if any idlers (grooming) would wake up that is no problem, because that simply means the work queue was empty and adding work to the queue can be done whether either the grooming thread (x)or scanner threads are running concurrently. Please do push if you feel confident about it being correct. I think it is now that I understand how it actually works. Thanks, Mark

[PATCH] libdwfl: Fix some GCC10 -Wnull-dereference issues.

2020-01-24 Thread Mark Wielaard
GCC10 on some arches will warn about possible NULL derefences. In the libdwfl linux-kernel-modules.c cases it might be caught already by earlier calls to get_release (). But it is hard to see that will really always happen. So do an explicit NULL check just in case. Signed-off-by: Mark Wielaard

Re: [PATCH] libdwfl: Fix some GCC10 -Wnull-dereference issues.

2020-02-06 Thread Mark Wielaard
On Fri, 2020-01-24 at 23:28 +0100, Mark Wielaard wrote: > GCC10 on some arches will warn about possible NULL derefences. > In the libdwfl linux-kernel-modules.c cases it might be caught already > by earlier calls to get_release (). But it is hard to see that will > really always happ

Re: contrasting elfutils debuginfod and clr-debug-info server

2020-02-07 Thread Mark Wielaard
no problem > multi-distroreq. separate servers one server ok One of the use cases of debuginfod is working with local/team builds for binaries not packaged by a distro. How does clear-linux handle that? Cheers, Mark

Re: contrasting elfutils debuginfod and clr-debug-info server

2020-02-07 Thread Mark Wielaard
which you could provide through the Fuse file system. On Fedora those are symlinks to the binaries installed, but you could provide the actual binaries instead. That would be somewhat similar to the debuginfod /buildid/BUILDID/executable request then. Cheers, Mark

Re: patch rfc: debuginfod -Z (generalized archive) support

2020-02-07 Thread Mark Wielaard
just pass the file with the given extension to libarchive directly (then you also don't need the zstdcat conversion). And letting libarchive handle it directly might be more efficient. Cheers, Mark

Re: patch rfc: debuginfod -Z (generalized archive) support

2020-02-07 Thread Mark Wielaard
in the code to get the FILE* to pass to archive_read_open_FILE? Or even just open and archive_read_open_fd? Cheers, Mark

[PATCH] elflint: Check sh_info for symtab isn't too big.

2020-02-07 Thread Mark Wielaard
The sh_info field of the symtab says how many symbols are in the section. Make sure at least that many symbols fit in the section. Reported-by: Ulrich Drepper Signed-off-by: Mark Wielaard --- src/ChangeLog | 4 src/elflint.c | 4 2 files changed, 8 insertions(+) diff --git a/src

Re: patch rfc: debuginfod -Z (generalized archive) support

2020-02-07 Thread Mark Wielaard
// "e" O_CLOEXEC? + dfn = pclose; + if (fp == NULL) +throw libc_exception (errno, string("popen ") + popen_cmd); +} + else +{ + fp = fopen (b_source0.c_str(), "r"); + dfn = fclose; + if (fp == NULL) +throw libc_exception (errno, string("fopen ") + b_source0); +} + defer_dtor fp_closer (fp, dfn); struct archive *a; a = archive_read_new(); Cheers, Mark

Re: contrasting elfutils debuginfod and clr-debug-info server

2020-02-07 Thread Mark Wielaard
Hi Arjan, On Fri, 2020-02-07 at 06:47 -0800, Arjan van de Ven wrote: > On 2/7/2020 1:13 AM, Mark Wielaard wrote: > > On Wed, Feb 05, 2020 at 02:05:42PM -0800, Arjan van de Ven wrote: > > > On 2/5/2020 11:14 AM, Frank Ch. Eigler wrote: > > > > AIUI that works by us

Re: [PATCH] elflint: Check sh_info for symtab isn't too big.

2020-02-18 Thread Mark Wielaard
On Fri, 2020-02-07 at 18:20 +0100, Mark Wielaard wrote: > The sh_info field of the symtab says how many symbols are in the > section. Make sure at least that many symbols fit in the section. I pushed this to master.

Re: Buildbot failure in Wildebeest Builder on whole buildset

2020-02-21 Thread Mark Wielaard
On Mon, 2020-02-10 at 22:34 +, build...@builder.wildebeest.org wrote: > The Buildbot has detected a failed build on builder whole buildset > while building elfutils. > Full details are available at: > https://builder.wildebeest.org/buildbot/#builders/15/builds/269 This is a somewhat older

[PATCH] tests: Explicitly unset DEBUGINFOD_URLS.

2020-02-21 Thread Mark Wielaard
infod server, unless they test (and set) one themselves. Signed-off-by: Mark Wielaard --- tests/ChangeLog | 5 + tests/Makefile.am | 2 ++ 2 files changed, 7 insertions(+) diff --git a/tests/ChangeLog b/tests/ChangeLog index 01e4a083..32ca1ce0 100644 --- a/tests/ChangeLog +++ b/tests/Chan

Re: [PATCH] debuginfod-client: default to XDG cache.

2020-02-21 Thread Mark Wielaard
eriodically as this > -program is reexecuted. The default is $HOME/.debuginfod_client_cache. > +program is reexecuted. If XDG_CACHE_HOME is set then > +$XDG_CACHE_HOME/debuginfod_client is the default location, otherwise > +$HOME/.cache/debuginfod_client is used. > + > > .S

Re: [PATCH] debuginfod-client: default to XDG cache.

2020-02-21 Thread Mark Wielaard
Hi Aaron, On Fri, 2020-02-21 at 12:21 -0500, Aaron Merey wrote: > On Fri, Feb 21, 2020 at 11:13 AM Mark Wielaard wrote: > > On Wed, 2020-02-19 at 16:04 -0500, Aaron Merey wrote: > > > + /* Create XDG cache directory if it doesn't exist. */ > > > +

Re: [PATCH] tests: Explicitly unset DEBUGINFOD_URLS.

2020-02-24 Thread Mark Wielaard
On Fri, 2020-02-21 at 13:49 +0100, Mark Wielaard wrote: > If DEBUGINFOD_URLS is set various tests will try to query the debuginfod > server which can stall the tests a bit. If other evironment variables > like DEBUGINFOD_PROGRESS are set it will make various tests fail because >

Re: patch to commit soon: PR25375 debuginfod prefetching

2020-02-25 Thread Mark Wielaard
t it to the user supplied value (if any). Is that intentional? Cheers, Mark

Re: PR25369 rfc: debuginfod client api extension for progressfn prettying etc.

2020-02-25 Thread Mark Wielaard
27;t really see the point of how they are used. Is the only use case to pass the string "Progress"? If there are no real users for this then I think we should not add these at this time. Or is some other client using them? I am not really against it, but would prefer if we add them separately to keep the patches concise. Thanks, Mark

Re: PR25369 rfc: debuginfod client api extension for progressfn prettying etc.

2020-02-25 Thread Mark Wielaard
s for this then I think we should not add > > these at this time. Or is some other client using them? I am not > > really > > against it, but would prefer if we add them separately to keep the > > patches concise. > > GDB would use them pretty much immediately, to be able to prepare a > more informative progress notification (like the file name whose > debuginfo is being sought, instead of its buildid). OK. Yes, that seems like a good use case. But can we add this as a separate feature in a separate commit? Thanks, Mark

Re: [PATCH] Bug 25600 - debuginfo-client should handle file:// URLs

2020-02-26 Thread Mark Wielaard
id=25600 Perfect patch, nice testcase. Thanks for the ChangeLog entries. I did tweak a few whitespace issues, but the file itself wasn't really consistent to begin with. Pushed to master. Cheers, Mark

Re: Buildbot failure in Wildebeest Builder on whole buildset

2020-02-26 Thread Mark Wielaard
gment(&nsegments[i]) --18155:0: aspacem at m_aspacemgr/aspacemgr-linux.c:728 (preen_nsegments) --18155:0: aspacem Exiting now. I'll try to replicate it and figure this out. But I think it doesn't have to do anything with the elfutils code. Cheers, Mark

Re: Build without .so files

2020-02-27 Thread Mark Wielaard
f > builds. Would it make sense to take —disable-shared here ? Yes, that might make sense. It isn't really tested much though. So someone would have to carefully audit the build files to see if it really works as intended. Cheers, Mark

Re: [PATCH] debuginfod-client: default to XDG cache.

2020-02-28 Thread Mark Wielaard
Hi Aaron, On Thu, 2020-02-27 at 19:00 -0500, Aaron Merey wrote: > On Fri, Feb 21, 2020 at 3:09 PM Mark Wielaard wrote: > > But I think that means we should only create the cachedir (either > > $XDG_CACHE_HOME or $HOME/.cache). Which is what we are doing here. But > >

[COMMITTED] config: Remove rpm, add dpkg as Requires for debuginfod package in spec.

2020-03-04 Thread Mark Wielaard
We no longer require rpm2cpio to unpack rpms. We do now require dpkg-deb to unpack debs. https://sourceware.org/bugzilla/show_bug.cgi?id=25583 Signed-off-by: Mark Wielaard --- config/ChangeLog| 5 + config/elfutils.spec.in | 5 +++-- 2 files changed, 8 insertions(+), 2 deletions

Re: [PATCH] debuginfod-client: update cache_path when new default path exists

2020-03-04 Thread Mark Wielaard
ath was updated only when > creating the new default directory and would otherwise be set to the > old default path. Nice catch and nice testcase. Looks good. Pushed to master. Cheers, Mark

Re: Buildbot failure in Wildebeest Builder on whole buildset

2020-03-04 Thread Mark Wielaard
04) ==27438==by 0x100318B: process_file (elfcompress.c:778) ==27438==by 0x100318B: main (elfcompress.c:1359) Luckily upstream valgrind already has a patch. But that will need to be backported and then a new package should be installed on the s390x buildbot worker. Cheers, Mark

Re: [PATCH] libelf: decompress: ensure zlib resource cleanup

2020-03-15 Thread Mark Wielaard
er inflateEnd() failed, which might cause it to call inflateEnd() twice (which might be fine, I dunno). Should we maybe ignore the error if inflateEnd() and just call it unconditionally before (ignoring its return code)? So, replace: if (... Z_OK) zrc = inflateEnd (&z); with unconditionally ending the stream: (void)inflateEnd(&z); What do you think? Cheers, Mark

Re: [PATCH] libelf: decompress: ensure zlib resource cleanup

2020-03-16 Thread Mark Wielaard
@ __libelf_decompress (void *buf_in, size_t size_in, size_t size_out) } zrc = inflateReset (&z); } - if (likely (zrc == Z_OK)) -zrc = inflateEnd (&z); + inflateEnd (&z); if (unlikely (zrc != Z_OK) || unlikely (z.avail_out != 0)) { Thanks, Mark

Re: [PATCH] libelf: decompress: ensure zlib resource cleanup

2020-03-16 Thread Mark Wielaard
Hi, On Mon, Mar 16, 2020 at 01:05:26PM +0100, Mark Wielaard wrote: > Thanks for looking into this so closely. I think it is best to just do > as the example code does. Always call inflateEnd (), ignoring the > return code and not care whether (in an error case) it might be called > t

Re: [PATCH v2] libelf: {de,}compress: ensure zlib resource cleanup

2020-03-20 Thread Mark Wielaard
return > Z_STREAM_END to indicate we are done. Hence change the condition. It was that last condition I had missed. Added a ChangeLog entry and pushed to master. Thanks, Mark

Re: [PATCH] libelf: handle PN_XNUM in elf_getphdrnum before shdr 0 is cached

2020-03-20 Thread Mark Wielaard
PN_XNUM and for some reason the scns cache wasn't initialized. Do you happen to have a testcase? Thanks, Mark

Re: PR25369 rfc slice 1: debuginfod_get/set_user_data

2020-03-22 Thread Mark Wielaard
ter location for that note. > +.SS "USER DATA POINTER" > + > +A single \fIvoid *\fP pointer associated with the connection handle > +may be set any time via > +.BR \%debuginfod_set_user_data () , > +and retrieved via > +.BR \%debuginfod_get_user_data () . > +The value may be NULL. So, if we decide that the initial value is NULL then this would be where we would document that or say that the value is undefined unless debuginfod_set_user_data () has never been called. Thanks, Mark

Re: PR25369 rfc slice 2: debuginfod get_url

2020-03-22 Thread Mark Wielaard
have to check for the empty string, just for NULL. Cheers, Mark

Re: [PATCH] libelf: handle PN_XNUM in elf_getphdrnum before shdr 0 is cached

2020-03-22 Thread Mark Wielaard
|| (((uintptr_t) ((char *) ehdr + e_shoff) > & (__alignof__ (Elf64_Shdr) - 1)) == 0))) I had missed that part. So it is actually common to not have the phdrs cache. Thanks, Mark From 28734adeb8cd51c7124330f88c1dc49c9c187865 Mon Sep 17 00:00:00 2001 From: Mark Wielaard

Re: [PATCH] libelf: handle PN_XNUM in elf_getphdrnum before shdr 0 is cached

2020-03-23 Thread Mark Wielaard
for > > adding the attached to the testsuite? It fails before, and passes > > after > > your fix. > > Sure thing, feel free to add > > Signed-off-by: Omar Sandoval Done and pushed your original fix, plus this testcase. Thanks, Mark

Re: PR25369 rfc slice 2: debuginfod get_url

2020-03-23 Thread Mark Wielaard
check for the empty string, just > > for NULL. > > OK. Looks good. Thanks for updating and pushing. But please do sent the final patch also to the list when the code changed. So people can track which version eventually gets in. Thanks, Mark

Re: Buildbot failure in Wildebeest Builder on whole buildset

2020-03-23 Thread Mark Wielaard
s-debian-i386/build/tests/getphdrnum contains non-lfs symbols: open FAIL run-lfs-symbols.sh (exit status: 1) The backends shared libraries don't exist anymore and should be removed from the testcase. But I don't immediately see what/where I forgot which flags to make the new getphdrnum check program picks up the wrong "open". Investigating... Mark

Re: Buildbot failure in Wildebeest Builder on whole buildset

2020-03-23 Thread Mark Wielaard
Hi, On Mon, 2020-03-23 at 15:08 +0100, Mark Wielaard wrote: > Well, that is odd. Both are 32bit arches. The failure is the same in > run-lfs-symbols.sh > >FAIL: run-lfs-symbols.sh > >./testfile-nolfs contains non-lfs symbols: fopen >

Re: PR25369 rfc slice 2: debuginfod get_url

2020-03-23 Thread Mark Wielaard
ode got pushed and why. Then I also know whether I can expect some patch to show up when I do a git pull and whether it is (subtly) different from what was posted to the list earlier. Cheers, Mark

elfutils 0.179 release end of the week?

2020-03-24 Thread Mark Wielaard
the missing CURLOPT_PATH_AS_IS from comment #4 probably should be resolved also. Are there any other "urgent" bug fixes pending? Cheers, Mark

Re: elfutils 0.179 release end of the week?

2020-03-25 Thread Mark Wielaard
t not be that simple to get things to compile and run correctly against it. Thanks, Mark

[Committed] Update mailinglist subscription information

2020-03-25 Thread Mark Wielaard
Hi, I pushed the following 2 commits to the code and htdocs repositories. sourceware updated the mailinglist software recently. Update our documentation (README and CONTRIBUTING) and the webpages to point to the new subscription form. Cheers, Mark From a344b8ce0bbe4f50fa2ace5fdfdcaccdee81d0e5

Re: Buildbot failure in Wildebeest Builder on whole buildset

2020-03-26 Thread Mark Wielaard
remove 'test-5124': Directory not empty FAIL run-backtrace-native-core-biarch.sh (exit status: 1) But I cannot replicate it. And it was caused by a change to the README file. Rebuilding on the same buildbot worker also made it PASS... Sigh. Don't know what to do about it, except watch whether it happens again or not. Cheers, Mark

Re: patch PR25548: debuginfod canonicalized source paths

2020-03-26 Thread Mark Wielaard
/tests/debuginfod-rpms/hello3.spec. > b/tests/debuginfod-rpms/hello3.spec. > new file mode 100644 > index ..ffb95134e2b6 > --- /dev/null > +++ b/tests/debuginfod-rpms/hello3.spec. > @@ -0,0 +1,60 @@ > +Summary: hello3 -- double hello, world rpm > +Name: hello3 &

Re: PR25267: debuginfod status logging improvements

2020-03-26 Thread Mark Wielaard
_start.tv_sec) + (tv_end.tv_usec - > tv_start.tv_usec)*0.01; > + obatched(clog) << conninfo(connection) > + << ' ' << method << ' ' << url > + << ' ' << http_code << '

Re: PR25548 followup

2020-03-26 Thread Mark Wielaard
On Thu, 2020-03-26 at 11:24 -0400, Frank Ch. Eigler via Elfutils-devel wrote: > Ah but that would be too easy. :) Also make sure the new test rpms are added to EXTRA_DIST. Pushed the attached. Cheers, Mark From 12305ff528ad9365b4d4e5ebcd307373cdd5bf83 Mon Sep 17 00:00:00 2001 From: M

Re: PR25369 slice 3/3: debuginfod header relay

2020-03-26 Thread Mark Wielaard
> .SH DESCRIPTION > > @@ -159,6 +161,21 @@ The resulting string is owned by the library, and must > not be modified > or freed. The caller should copy it if it is needed beyond the release > of the client object. > > +.SS "HTTP HEADER" > + > +Before a lo

Re: patch PR25583: debuginfod bsdtar for deb

2020-03-26 Thread Mark Wielaard
stalled on the s390x and ppc64[le] workers. I am not against this patch, but I do wonder if it should not try to fall back on dpkg if bsdtar isn't installed. Cheers, Mark

Re: PR25369 slice 3/3: debuginfod header relay

2020-03-27 Thread Mark Wielaard
;", &alt_fd); > > > } > > > > 0 instead of NULL? > > I believe we went over this before, 0 is more C++? > > Yes. OK. I guess I got stuck in C language mindset. > > > +/* Add an outgoing HTTP request "Header: Value". Copies string. */ > > > +int debuginfod_add_http_header (debuginfod_client *client, const char* > > > header); > > > > So here at least add "optional header" or something. A warning that > > this is a hint only and might be ignored depending on backend/transport > > used. > > Adding a http header to a non-http transport URL is obviously > meaningless and harmless. I don't see why we should belabour it or > give people any concern about it. I just like the documentation to be clear and precise. Cheers, Mark

Re: patch PR25722: /path/name based debuginfod-find & API lookups

2020-03-27 Thread Mark Wielaard
s is just into debuginfo-find and experiment a bit with it before adding it as a public API to the debuginfod-client API. In debuginfod-find the code would also be slightly simpler since it doesn't have to convert to a hex-string first, it can just pass the build-id bytes as is. Cheers, Mark

Re: patch PR25448: more debuginfod prometheus metrics

2020-03-27 Thread Mark Wielaard
s and data amounts. This looks nice. Do we have to document these anywhere, or are prometheus metrics "self documenting"? I assume tools just take what they can get from the json export and create graphs based on the name count/sum patterns? Thanks, Mark

[PATCH] debuginfod: Disallow --port=0.

2020-03-27 Thread Mark Wielaard
-by: Mark Wielaard --- debuginfod/ChangeLog | 4 debuginfod/debuginfod.cxx | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/debuginfod/ChangeLog b/debuginfod/ChangeLog index 58ba85cf..018d62f6 100644 --- a/debuginfod/ChangeLog +++ b/debuginfod/ChangeLog @@ -1,3 +1,7

Re: elfutils 0.179 release end of the week?

2020-03-27 Thread Mark Wielaard
er testers some time to digest and do a release on Monday or Tuesday? Cheers, Mark

Re: PR25369 slice 3/3: debuginfod header relay

2020-03-29 Thread Mark Wielaard
correct. I added a simple check to the function to see it is at least somewhat plausible, so that a user won't be surprised if a wrongly formatted string accidentally removes a header instead of adding one. Cheers, Mark From 7ddceee2b6b0a3fe752a2e8cc5d5cfd0f45d6897 Mon Sep 17 00:00:00 2001 Fr

Re: patch PR25722: /path/name based debuginfod-find & API lookups

2020-03-29 Thread Mark Wielaard
to disambiguate files by using ./ Thanks, Mark

[COMMITTED] Prepare for 0.179

2020-03-30 Thread Mark Wielaard
Set version to 0.179. Update NEWS and elfutils.spec.in. Regenerate po/*.po files. Signed-off-by: Mark Wielaard --- ChangeLog | 5 + NEWS| 35 +++ config/ChangeLog| 4 + config/elfutils.spec.in | 25 ++ configure.ac| 2 +- po

elfutils 0.179 released

2020-03-30 Thread Mark Wielaard
ine (3): debuginfod.h: fix typo in comment: legnth -> length debuginfod/doc: Fix typo debuginfo_progressfn_t -> debuginfod_progressfn_t debuginfod: file:// URLs: handle curl resp. code Mark Wielaard (27): config: versioned libdebuginfod libraries should not be in

[COMMITTED] config: chmod uploaded dir and files to make them readable.

2020-03-30 Thread Mark Wielaard
Default file permissions on sourceware have changed. Make sure that the upload-release.sh script sets the permissions right. Signed-off-by: Mark Wielaard --- config/ChangeLog | 5 + config/upload-release.sh | 2 ++ 2 files changed, 7 insertions(+) diff --git a/config/ChangeLog b

Re: [PATCH] libelf: remove usage of sys/cdefs

2020-04-05 Thread Mark Wielaard
Hi, Thanks for the patch, but elf.h comes from glibc. So please get your fix accepted upstream (sent it to libc-al...@sourceware.org) and we'll pick it up next time we sync with the glibc code. Thanks, Mark

[PATCH] lib: Use attribute symver when available to define symbol versioning.

2020-04-10 Thread Mark Wielaard
function names. And avoid defining symbols in asm statements. Signed-off-by: Mark Wielaard --- ChangeLog | 4 configure.ac| 13 + lib/ChangeLog | 5 + lib/eu-config.h | 20 ++-- 4 files changed, 40 insertions(+), 2 deletions(-) diff --git a

Re: [PATCH] lib: Use attribute symver when available to define symbol versioning.

2020-04-14 Thread Mark Wielaard
Hi, On Fri, 2020-04-10 at 21:42 +0200, Mark Wielaard wrote: > GCC 10 introduces a function attribute to define symbol versioning. > Add a configure check to see if __attribute__((symver)) is supported. > If it is then define the OLD_VERSION, NEW_VERSION, COMPAT_VERS

Re: [PATCH] lib: Use attribute symver when available to define symbol versioning.

2020-04-14 Thread Mark Wielaard
On Tue, 2020-04-14 at 17:25 +0200, Mark Wielaard wrote: > On Fri, 2020-04-10 at 21:42 +0200, Mark Wielaard wrote: > > GCC 10 introduces a function attribute to define symbol versioning. > > Add a configure check to see if __attribute__((symver)) is supported. > > If

[PATCH] libcpu: Replace assert with goto invalid_op for bad prefix.

2020-04-16 Thread Mark Wielaard
https://sourceware.org/bugzilla/show_bug.cgi?id=25831 Signed-off-by: Mark Wielaard --- libcpu/ChangeLog | 5 + libcpu/i386_disasm.c | 11 +++ 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/libcpu/ChangeLog b/libcpu/ChangeLog index 70796514..a8b2b951 100644

[COMMITTED] libdwfl: Initialize bits to NULL in dwfl_standard_find_debuginfo for LTO.

2020-04-16 Thread Mark Wielaard
d use. If the callchain I am inlining is so deep that I cannot figure out maybe-uninitialized variables anymore I should stop inlining. For now just help GCC out and initialize bits to NULL. Signed-off-by: Mark Wielaard --- libdwfl/ChangeLog| 5 + libdwfl/find-debuginfo.c | 2 +- 2

[PATCH] elflint: Allow SHF_EXCLUDE as generic section flag when --gnu is given.

2020-04-16 Thread Mark Wielaard
Strictly speaking SHF_EXCLUDE is a processor specific section flag, but it is used generically in the GNU toolchain. For example when adding .gnu.lto_ sections. Signed-off-by: Mark Wielaard --- src/ChangeLog | 5 + src/elflint.c | 5 + 2 files changed, 10 insertions(+) diff --git a/src

[PATCH] libdw, readelf: Handle GCC LTO .gnu.debuglto_ prefix.

2020-04-17 Thread Mark Wielaard
GCC puts (partial) DWARF debuginfo into sections prefixed with .gnu.debuglto_. Handle those sections as if they are normal .debug sections (which they are). This allows showing the DWARF that gcc puts into ET_REL files compiled with -flto. Signed-off-by: Mark Wielaard --- libdw/ChangeLog

[PATCH] tests: Build test-nlist with minimal CFLAGS to guarantee symbol order.

2020-04-17 Thread Mark Wielaard
test_nlist checks its own symbol table, and expects various symbols to be in the order as specified in the source file. Explicitly set minimal CFLAGS. Signed-off-by: Mark Wielaard --- tests/ChangeLog | 5 + tests/Makefile.am | 9 + 2 files changed, 14 insertions(+) diff --git a

[PATCH] tests: Run run-varlocs-self.sh for object files with --exprlocs.

2020-04-17 Thread Mark Wielaard
files with --exprlocs to test that output too (and not require addresses). Signed-off-by: Mark Wielaard --- tests/ChangeLog | 7 +++ tests/run-varlocs-self.sh | 4 +++- tests/test-subr.sh| 13 + 3 files changed, 23 insertions(+), 1 deletion(-) diff --git a

Re: [PATCH] elflint: Allow SHF_EXCLUDE as generic section flag when --gnu is given.

2020-04-21 Thread Mark Wielaard
On Thu, Apr 16, 2020 at 06:53:41PM +0200, Mark Wielaard wrote: > Strictly speaking SHF_EXCLUDE is a processor specific section flag, > but it is used generically in the GNU toolchain. For example when > adding .gnu.lto_ sections. I pushed this to master.

Re: rfc: debuginfod service: add rh satellite rpm repo dir

2020-04-21 Thread Mark Wielaard
g root path is almost no cost. So it seems fine to add. The default sysconfig is somewhat rpm/fedora/rh specific. Hopefully now that we support other archive formats we can trick some contributor into adding some sysconfig that is is optimal for other setups. Cheers, Mark

Re: [PATCH] libdw, readelf: Handle GCC LTO .gnu.debuglto_ prefix.

2020-04-21 Thread Mark Wielaard
On Fri, Apr 17, 2020 at 11:35:37AM +0200, Mark Wielaard wrote: > GCC puts (partial) DWARF debuginfo into sections prefixed with > .gnu.debuglto_. Handle those sections as if they are normal .debug > sections (which they are). This allows showing the DWARF that gcc > puts into ET_REL fi

Re: [PATCH] tests: Build test-nlist with minimal CFLAGS to guarantee symbol order.

2020-04-21 Thread Mark Wielaard
On Fri, Apr 17, 2020 at 12:22:39PM +0200, Mark Wielaard wrote: > test_nlist checks its own symbol table, and expects various symbols > to be in the order as specified in the source file. Explicitly set > minimal CFLAGS. Pushed to master.

Re: [PATCH] tests: Run run-varlocs-self.sh for object files with --exprlocs.

2020-04-21 Thread Mark Wielaard
On Fri, Apr 17, 2020 at 12:34:17PM +0200, Mark Wielaard wrote: > The varlocs test relies on finding addresses for the CUs, even in > object files. This might not be true (for example when building with > gcc -flto, which only emits partial, type only, debuginfo). Split > running the s

Re: [PATCH v2] libelf: {de,}compress: ensure zlib resource cleanup

2020-04-24 Thread Mark Wielaard
| | | | | (8) ...to here | | (9) first ‘free’ here | Fixed by removing the free (out_buf) on line 116 as attached. Cheers, Mark >From 0b2fc95c46dabf85d053b2f0c6aab217b9c5a9b8 Mon Sep 17 00:00:00 2001 From: Mark Wielaard Date: Sa

[COMMITTED] libasm: Fix double fclose in asm_end.

2020-04-25 Thread Mark Wielaard
would if something went wrong writing out the file. Signed-off-by: Mark Wielaard --- libasm/ChangeLog | 4 libasm/asm_end.c | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/libasm/ChangeLog b/libasm/ChangeLog index 7b0d3df3..2c092abe 100644 --- a/libasm/ChangeLog +++ b/l

[COMMITTED] libdw: Call Dwarf oom_handler() when malloc fails in __libdw_alloc_tail.

2020-04-25 Thread Mark Wielaard
GCC10 -fanalyzer found a possibly-NULL dereference after a failed malloc in __libdw_alloc_tail. In this case we should call the Dwarf oom_handler as is done in other places where an essential malloc call fails. The oom_handler cannot return and will likely just abort. Signed-off-by: Mark Wielaard

[COMMITTED] libdwfl: Fix double free on failure path in gzip.c.

2020-04-25 Thread Mark Wielaard
ned. Signed-off-by: Mark Wielaard --- libdwfl/ChangeLog | 5 + libdwfl/gzip.c| 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/libdwfl/ChangeLog b/libdwfl/ChangeLog index 4ddc9ad4..daedaed8 100644 --- a/libdwfl/ChangeLog +++ b/libdwfl/ChangeLog @@ -1,3 +1,8 @@ +2020-04

[PATCH] libdwfl: Handle debugaltlink in dwfl_standard_find_debuginfo.

2020-04-30 Thread Mark Wielaard
... Signed-off-by: Mark Wielaard --- libdwfl/ChangeLog| 5 + libdwfl/find-debuginfo.c | 23 +-- 2 files changed, 26 insertions(+), 2 deletions(-) diff --git a/libdwfl/ChangeLog b/libdwfl/ChangeLog index daedaed8..3f9cd665 100644 --- a/libdwfl/ChangeLog +++ b/li

Re: [PATCH] libdwfl: Handle debugaltlink in dwfl_standard_find_debuginfo.

2020-05-06 Thread Mark Wielaard
Hi, On Fri, 2020-05-01 at 00:07 +0200, Mark Wielaard wrote: > When we fall back to the debuginfod client then we need to do the > same trick we do for local lookups in dwfl_build_id_find_debuginfo. > If the debug file (dw) is already set, then we must be looking for > the altfile. B

[PATCH 1/2] libdw: Use correct CU to resolve file names in dwarf_decl_file.

2020-05-08 Thread Mark Wielaard
to dwarf_attr_integrate explaining that the attribute returned might come from a different CU (and even different Dwarf). Signed-off-by: Mark Wielaard --- libdw/ChangeLog | 7 + libdw/dwarf_decl_file.c | 2 +- libdw/dwarf_ranges.c | 5 libdw/libdw.h

[PATCH 2/2] libdw: Skip imported compiler_units in libdw_visit_scopes walking DIE tree

2020-05-08 Thread Mark Wielaard
d-off-by: Mark Wielaard --- libdw/ChangeLog | 5 + libdw/libdw_visit_scopes.c | 6 +- tests/ChangeLog | 9 + tests/Makefile.am | 1 + tests/run-allfcts.sh| 27 +++ tests/testfile-lto-gcc8.bz2 | Bin 0 -&

Some more GCC10 -fanalyzer inspired patches

2020-05-10 Thread Mark Wielaard
probably fairly hard to trigger. All are somewhat trivial and I intent to check them in soon. Cheers, Mark

[PATCH 1/7] libdwfl: Cleanup user_core resources on failure in dwfl_core_file_report.

2020-05-10 Thread Mark Wielaard
GCC10 -fanalyzer noticed that we allocate, but don't always cleanup the dwfl->user_core if it wasn't set yet on error. In theory dwfl_module_end should take care of it, but it is cleaner and less confusing to just do it here. Signed-off-by: Mark Wielaard --- libdwfl/Cha

[PATCH 2/7] tests: Make sure to not call memcmp with NULL arguments.

2020-05-10 Thread Mark Wielaard
d->d_buf, orig_size) == 0) orig_buf can only be NULL when orig_size is zero, but it might still be undefined behaviour. So don't try to be too smart and just check whether we actually have an buffer. Signed-off-by: Mark Wielaard --- tests/ChangeLog | 5 + tests/el

[PATCH 4/7] libelf: Check for NULL shdr in elf_strptr.

2020-05-10 Thread Mark Wielaard
GCC10 -fanalyzer with -flto notices __elf64_getshdr_rdlock can fail and because the result isn't checked in elf_strptr it can cause a dereference of NULL. Signed-off-by: Mark Wielaard --- libelf/ChangeLog| 4 libelf/elf_strptr.c | 2 +- 2 files changed, 5 insertions(+), 1 del

[PATCH 3/7] libelf: Check __gelf_getehdr_rdlock call doesn't fail in elf_getdata.

2020-05-10 Thread Mark Wielaard
GCC10 -fanalyzer with -flto notices __gelf_getehdr_rdlock can fail and that the result of the call in __libelf_set_rawdata_wrlock isn't checked, which can cause a dereference of NULL. Signed-off-by: Mark Wielaard --- libelf/ChangeLog | 5 + libelf/elf_getdata.c | 2 ++ 2 files ch

<    12   13   14   15   16   17   18   19   20   21   >