[Bug general/29767] run-backtrace-native-core{,-biarch}.sh Tests Fail
https://sourceware.org/bugzilla/show_bug.cgi?id=29767 --- Comment #7 from Shahab --- $$ TL;DR; $$___ Please close the issue. $$ $$ Rumbling $$_ $$ I just tried it on: 9c136cb3 -- libdwfl: Read no more than required in dwfl_segment_report_module and the tests don't fail anymore: $ tail tests/test-suite.log == elfutils 0.188: tests/test-suite.log == # TOTAL: 236 # PASS: 235 # SKIP: 1 # XFAIL: 0 # FAIL: 0 # XPASS: 0 # ERROR: 0 .. contents:: :depth: 2 SKIP: run-lfs-symbols.sh LFS testing is irrelevant on this system SKIP run-lfs-symbols.sh (exit status: 77) $ cat tests/run-backtrace-native-core.sh.log 0x7ffda79b 0x7ffda79b1000 linux-vdso.so.1 0x7fe4927a7000 0x7fe4927d3198 ld-linux-x86-64.so.2 0x7fe4925a6000 0x7fe49276b2a0 libc.so.6 0x7fe49276c000 0x7fe49278c1b0 libpthread.so.0 0x55f411477000 0x55f41147b0a8 backtrace-child TID 20602: # 0 0x7fe49277f7a1 raise # 1 0x55f41147842d - 1 sigusr2 # 2 0x55f4114784fa - 1 stdarg # 3 0x55f411478510 - 1 backtracegen # 4 0x55f411478519 - 1 start # 5 0x7fe492774eae - 1 start_thread # 6 0x7fe4926a42ff - 1 __clone TID 20601: # 0 0x7fe492776447 __pthread_clockjoin_ex # 1 0x55f41147825c - 1 main # 2 0x7fe4925cde0a - 1 __libc_start_main # 3 0x55f41147833a - 1 _start # 1 0x55f41147825c - 1 main PASS run-backtrace-native-core.sh (exit status: 0) $ cat tests/run-backtrace-native-core-biarch.sh.log 0xf7edd000 0xf7edf000 linux-gate.so.1 0xf7edf000 0xf7f0c978 ld-linux.so.2 0xf7cb 0xf7e9ded8 libc.so.6 0xf7e9e000 0xf7ebe100 libpthread.so.0 0x5657c000 0x56580058 backtrace-child-biarch TID 20630: # 0 0xf7edd549 __kernel_vsyscall # 1 0xf7eb2fb9 - 1 raise # 2 0x5657d4ba - 1 sigusr2 # 3 0x5657d594 - 1 stdarg # 4 0x5657d5aa - 1 backtracegen # 5 0x5657d5b8 - 1 start # 6 0xf7ea6501 - 1 start_thread # 7 0xf7dcadb6 - 1 __clone TID 20629: # 0 0xf7edd549 __kernel_vsyscall # 1 0xf7ea7d47 - 1 __pthread_clockjoin_ex # 2 0xf7ea7a3c - 1 pthread_join # 3 0x5657d288 - 1 main # 4 0xf7ccef1a - 1 __libc_start_main # 5 0x5657d371 - 1 _start # 3 0x5657d288 - 1 main PASS run-backtrace-native-core-biarch.sh (exit status: 0) Relevant diff between the 2 config files: --- /old/config.log +++ /new/config.log @@ -4,7 +4,7 @@ It was created by elfutils configure 0.188, which was generated by GNU Autoconf 2.71. Invocation command line was - $ ../configure --disable-debuginfod --disable-libdebuginfod --prefix=/usr --enable-maintainer-mode + $ ../configure --disable-debuginfod --disable-libdebuginfod --enable-maintainer-mode --prefix=/usr ## - ## ## Platform. ## @@ -12,9 +12,9 @@ hostname = sourceware uname -m = x86_64 -uname -r = 5.19.17_1 +uname -r = 6.0.11_1 uname -s = Linux -uname -v = #1 SMP PREEMPT_DYNAMIC Mon Oct 31 14:24:17 UTC 2022 +uname -v = #1 SMP PREEMPT_DYNAMIC Wed Dec 7 02:03:34 UTC 2022 /usr/bin/uname -p = unknown /bin/uname -X = unknown @@ -39,6 +39,7 @@ PATH: /sbin/ PATH: /home/user/.rvm/bin/ PATH: /home/user/.rvm/bin/ +PATH: /home/user/.rvm/bin/ ## --- ## @@ -1605,3 +1606,24 @@ #define HAVE_PTHREAD_SETNAME_NP 1 configure: exit 0 + +## -- ## +## Running config.status. ## +## -- ## + +This file was extended by elfutils config.status 0.188, which was +generated by GNU Autoconf 2.71. Invocation command line was + + CONFIG_FILES= + CONFIG_HEADERS = + CONFIG_LINKS= + CONFIG_COMMANDS = + $ ./config.status backends/Makefile depfiles + +on sourceware + +config.status:1055: creating backends/Makefile +config.status:1269: executing depfiles commands +config.status:1344: cd backends && sed -e '/# am--include-marker/d' Makefile | make -f - am--depfiles +make[3]: Nothing to be done for 'am--depfiles'. +config.status:1351: $? = 0 -- You are receiving this mail because: You are on the CC list for the bug.
Re: [PATCH 6/7] Fixes building with msvc/clang mingw/gcc
I am not able running test-suite on windows yet, just getting it compiled at the very first step On Mon, Oct 17, 2022 at 5:21 AM Mark Wielaard wrote: > > Hi, > > I find this hard to review. I have no experienc with msvc and don't > know when/what _MSC_VER implies or how to verify system_win32.c. I am > also a bit worried that the various ifdefs will be hard to keep > correct. > > If we don't have HAVE_DECL_MMAP does the testsuite still work? > > Maybe this patch can be split up is separate concerns. But I have to > admit I am a litle afraid this will be hard to keep working. > > Cheers, > > Mark -- 此致 礼 罗勇刚 Yours sincerely, Yonggang Luo
Re: [PATCH 7/7] Add CMake build files
Using cmake building with msvc-clang will be easier, anyway I'll drop it first On Mon, Oct 17, 2022 at 5:23 AM Mark Wielaard wrote: > > Hi, > > I rather not have multiple build systems in the tree. Are the > autotools not available on your system? > > Cheers, > > Mark -- 此致 礼 罗勇刚 Yours sincerely, Yonggang Luo
Re: [PATCH 02/25] ignore build directory
It's a common step to configure and make under build directory, so that the IDE won't affect by it On Thu, Oct 27, 2022 at 9:03 PM Mark Wielaard wrote: > On Fri, 2022-10-21 at 02:25 +0800, Yonggang Luo via Elfutils-devel > wrote: > > Signed-off-by: Yonggang Luo > > --- > > .gitignore | 1 + > > 1 file changed, 1 insertion(+) > > > > diff --git a/.gitignore b/.gitignore > > index 8bcd88d7..ca06 100644 > > --- a/.gitignore > > +++ b/.gitignore > > @@ -21,6 +21,7 @@ Makefile.in > > /INSTALL > > /aclocal.m4 > > /autom4te.* > > +/build > > /config.cache > > /config.h > > /config.h.in > > Why is this necessary? > > Thanks, > > Mark > -- 此致 礼 罗勇刚 Yours sincerely, Yonggang Luo
Re: [PATCH 06/25] move platform depended include into system.h of libebl
On Fri, Oct 28, 2022 at 7:35 PM Mark Wielaard wrote: > > On Fri, 2022-10-21 at 02:25 +0800, Yonggang Luo via Elfutils-devel > wrote: > > Because all source in libebl #include , so #include > > in > > libeblP.h is enough, there is multiple memory-access.h file, so use > > relative path to > > include it properly, > > I am not a fan of the relative path trick, especially if there it is > clear only one is every needed. You also use it for other files, why? > I am respect the original code looks at https://github.com/sourceware-org/elfutils/blob/master/libdwfl/core-file.c#L31 > Cheers, > > Mark -- 此致 礼 罗勇刚 Yours sincerely, Yonggang Luo
Re: [PATCH 08/25] Use configure to detect HAVE_DECL_MMAP and use it for system doesn't provide sys/mman.h
On Fri, Oct 28, 2022 at 7:41 PM Mark Wielaard wrote: > > Hi, > > On Fri, 2022-10-21 at 02:25 +0800, Yonggang Luo via Elfutils-devel > wrote: > > Signed-off-by: Yonggang Luo > > --- > > configure.ac | 1 + > > lib/crc32_file.c | 4 ++-- > > lib/system.h | 2 ++ > > libelf/elf32_updatefile.c | 3 ++- > > libelf/elf_begin.c| 5 - > > libelf/elf_end.c | 2 ++ > > libelf/elf_update.c | 5 - > > Missing commit message and ChangeLog entries. > > So this is for a system that doesn't have mmap? > How does the testsuite results look on such a system? > > ELF_C_{READ,WRITE,RDWR}_MMAP[_PRIVATE] are elfutils extensions, but > they are used internally in other libraries. I am trying getting elf support for windows/mingw/msvc, the MMAP support is not needed yet for (QEMU/mesa) > > Cheers, > > Mark -- 此致 礼 罗勇刚 Yours sincerely, Yonggang Luo
Re: [PATCH 09/25] include libgen.h in system.h
On Fri, Oct 28, 2022 at 7:45 PM Mark Wielaard wrote: > > On Fri, 2022-10-21 at 02:25 +0800, Yonggang Luo via Elfutils-devel > wrote: > > basename function are accessed multiple place, but used without > > include libgen.h > > This is wrong. We use the GNU basename (from string.h with > _GNU_SOURCE), not the POSIX one (from libgen.h). Thanks, that informs me, are they the same thing? obviously mingw lacked of this > > Cheers, > > Mark -- 此致 礼 罗勇刚 Yours sincerely, Yonggang Luo
Re: [PATCH 09/25] include libgen.h in system.h
But still I think the force cast to (char *) is needed On Sat, Dec 17, 2022 at 5:22 AM 罗勇刚(Yonggang Luo) wrote: > > > > On Fri, Oct 28, 2022 at 7:45 PM Mark Wielaard wrote: > > > > On Fri, 2022-10-21 at 02:25 +0800, Yonggang Luo via Elfutils-devel > > wrote: > > > basename function are accessed multiple place, but used without > > > include libgen.h > > > > This is wrong. We use the GNU basename (from string.h with > > _GNU_SOURCE), not the POSIX one (from libgen.h). > > Thanks, that informs me, are they the same thing? > obviously mingw lacked of this > > > > > Cheers, > > > > Mark > > > > -- > 此致 > 礼 > 罗勇刚 > Yours > sincerely, > Yonggang Luo -- 此致 礼 罗勇刚 Yours sincerely, Yonggang Luo
Re: [PATCH 11/25] libcpu: Use __asm instead asm that can be recognized by both clang-cl and gcc
On Mon, Dec 12, 2022 at 8:42 PM Mark Wielaard wrote: > > Hi, > > On Fri, 2022-10-21 at 02:25 +0800, Yonggang Luo via Elfutils-devel > wrote: > > Signed-off-by: Yonggang Luo > > --- > > libcpu/i386_disasm.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/libcpu/i386_disasm.c b/libcpu/i386_disasm.c > > index 599d1654..cc75a7b1 100644 > > --- a/libcpu/i386_disasm.c > > +++ b/libcpu/i386_disasm.c > > @@ -480,7 +480,7 @@ i386_disasm (Ebl *ebl __attribute__((unused)), > > > > /* gcc is not clever enough to see the following > > variables > >are not used uninitialized. */ > > - asm ("" > > + __asm ("" > > : "=mr" (opoff), "=mr" (correct_prefix), "=mr" > > (codep), > >"=mr" (next_curr), "=mr" (len)); > > } > > Urgh. Is this really (still) necessary? It is inside an if (0) block. > So it also is never used. Can we just get rid of the whole block? OK, I'll get rid of it > > Thanks, > > Mark -- 此致 礼 罗勇刚 Yours sincerely, Yonggang Luo
Re: [PATCH 14/25] libdw: check __OPTIMIZE__ in dwarf_whatattr.c and dwarf_whatform.c to match the header
>From bdf8a3b45f063d010e7c93b3d3bfc42b801ee9b2 Mon Sep 17 00:00:00 2001 From: Yonggang Luo Date: Thu, 20 Oct 2022 02:50:03 +0800 Subject: [PATCH] libdw: Fixes compile of dwarf_whatattr.c and dwarf_whatform.c If __OPTIMIZE__ is defined, then compile dwarf_whatattr.c and dwarf_whatform.c will cause symbol conflict between dwarf_whatattr.c and libdw.h, dwarf_whatform.c and libdw.h, So always undefined __OPTIMIZE__ when compiling these two files Signed-off-by: Yonggang Luo --- libdw/dwarf_whatattr.c | 4 +++- libdw/dwarf_whatform.c | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/libdw/dwarf_whatattr.c b/libdw/dwarf_whatattr.c index d664b021..c016f293 100644 --- a/libdw/dwarf_whatattr.c +++ b/libdw/dwarf_whatattr.c @@ -30,7 +30,9 @@ #ifdef HAVE_CONFIG_H # include #endif - +#ifdef __OPTIMIZE__ +#undef __OPTIMIZE__ +#endif #include #include "libdwP.h" diff --git a/libdw/dwarf_whatform.c b/libdw/dwarf_whatform.c index dee29a9f..f1d3574d 100644 --- a/libdw/dwarf_whatform.c +++ b/libdw/dwarf_whatform.c @@ -30,7 +30,9 @@ #ifdef HAVE_CONFIG_H # include #endif - +#ifdef __OPTIMIZE__ +#undef __OPTIMIZE__ +#endif #include #include "libdwP.h" -- 2.39.0.windows.1
Re: [PATCH 15/25] lib: Implement error properly even when not HAVE_ERR_H
On Mon, Dec 12, 2022 at 11:37 PM Mark Wielaard wrote: > > Hi, > > On Fri, 2022-10-21 at 02:25 +0800, Yonggang Luo via Elfutils-devel > wrote: > > on win32, there is no err.h > > [...] > > +#else > > + (void)status; > > + vfprintf(stderr, format, argp); > > +#endif > >va_end(argp); > > That doesn't look like a valid implementation of error, it ignores > errno and doesn't exit when necessary. Do you mean it should call `exit(status)` after the error message is printed? > > Cheers, > > Mark -- 此致 礼 罗勇刚 Yours sincerely, Yonggang Luo
[Bug general/29767] run-backtrace-native-core{,-biarch}.sh Tests Fail
https://sourceware.org/bugzilla/show_bug.cgi?id=29767 Mark Wielaard changed: What|Removed |Added Resolution|--- |WORKSFORME Status|UNCONFIRMED |RESOLVED --- Comment #8 from Mark Wielaard --- Works here and for reporter. -- You are receiving this mail because: You are on the CC list for the bug.