diff options
author | Thomas Schwinge <thomas@codesourcery.com> | 2012-12-11 11:22:18 +0100 |
---|---|---|
committer | Thomas Schwinge <thomas@codesourcery.com> | 2012-12-11 11:22:18 +0100 |
commit | a61ab7b60a4f29bf7652aafea2319bdc11ab06d8 (patch) | |
tree | d3eb5bef5cedae809d671aa9f8b6523c9000faf0 /open_issues | |
parent | 1c36eb6c025084af76c5b930ca4adc5953560fd7 (diff) | |
parent | 573d363a3458b8a37e6ec929c778dae8abf90fab (diff) |
Merge remote-tracking branch 'feldtkeller.SCHWINGE/master'
Conflicts:
hurd/libstore/nbd_store.mdwn
open_issues/glibc.mdwn
open_issues/libpthread_CLOCK_MONOTONIC.mdwn
open_issues/packaging_libpthread.mdwn
shortcuts.mdwn
Diffstat (limited to 'open_issues')
-rw-r--r-- | open_issues/automatic_backtraces_when_assertions_hit.mdwn | 5 | ||||
-rw-r--r-- | open_issues/binutils.mdwn | 22 | ||||
-rw-r--r-- | open_issues/code_analysis.mdwn | 60 | ||||
-rw-r--r-- | open_issues/exec_memory_leaks.mdwn | 24 | ||||
-rw-r--r-- | open_issues/fifo_thread_explosion.mdwn | 20 | ||||
-rw-r--r-- | open_issues/gcc.mdwn | 234 | ||||
-rw-r--r-- | open_issues/gdb.mdwn | 228 | ||||
-rw-r--r-- | open_issues/glibc.mdwn | 201 | ||||
-rw-r--r-- | open_issues/glibc/t/tls.mdwn | 6 | ||||
-rw-r--r-- | open_issues/glibc_madvise_vs_static_linking.mdwn | 2 | ||||
-rw-r--r-- | open_issues/glibc_ptrace.mdwn | 6 | ||||
-rw-r--r-- | open_issues/libpthread_1fcd93fd3c733eb19bcad8d03e65f13ec4b0e998..master-viengoos-on-bare-metal.mdwn | 849 | ||||
-rw-r--r-- | open_issues/libpthread_CLOCK_MONOTONIC.mdwn | 4 | ||||
-rw-r--r-- | open_issues/libpthread_glibc_nptl_testsuite.mdwn | 28 | ||||
-rw-r--r-- | open_issues/packaging_libpthread.mdwn | 46 | ||||
-rw-r--r-- | open_issues/term_blocking.mdwn | 67 | ||||
-rw-r--r-- | open_issues/whole_system_debugging.mdwn | 19 |
17 files changed, 1620 insertions, 201 deletions
diff --git a/open_issues/automatic_backtraces_when_assertions_hit.mdwn b/open_issues/automatic_backtraces_when_assertions_hit.mdwn index 71007f99..f6bf5856 100644 --- a/open_issues/automatic_backtraces_when_assertions_hit.mdwn +++ b/open_issues/automatic_backtraces_when_assertions_hit.mdwn @@ -72,3 +72,8 @@ In context of the [[ext2fs_libports_reference_counting_assertion]]. <braunr> yes, i thought it used the backtrace functions internally though <braunr> that is, execinfo <braunr> but this does require -rdynamic + + +# GCC's libbacktrace + +Introduced in commit ecd3459e7bb829202601e3274411135a15c64dde. diff --git a/open_issues/binutils.mdwn b/open_issues/binutils.mdwn index 8d6b3a94..eec5154f 100644 --- a/open_issues/binutils.mdwn +++ b/open_issues/binutils.mdwn @@ -123,20 +123,22 @@ sources|source_repositories/binutils]], run on kepler.SCHWINGE and coulomb.SCHWINGE. $ export LC_ALL=C - $ ../master/configure --prefix="$PWD".install SHELL=/bin/dash CC=gcc-4.6 CXX=g++-4.6 2>&1 | tee log_build + $ ../master/configure --prefix="$PWD".install --with-sysroot=/ SHELL=/bin/dash CC=gcc-4.6 CXX=g++-4.6 2>&1 | tee log_build [...] $ make 2>&1 | tee log_build_ [...] Different hosts may default to different shells and compiler versions; thus -harmonized. +harmonized. Debian GCC (which is used in binutils' testsuite) likes to pass +`--sysroot=/` to `ld`, so we need to configure binutils with support for +sysroots. This takes up around 120 MiB, and needs roughly 4 min on kepler.SCHWINGE and 15 min on coulomb.SCHWINGE. <!-- - $ (make && touch .go-install) 2>&1 | tee log_build_ && test -f .go-install && (make install && touch .go-check) 2>&1 | tee log_install && test -f .go-check && make -k check 2>&1 | tee log_check + $ (make && touch .go-install) 2>&1 | tee log_build_ && test -f .go-install && (make install && touch .go-test) 2>&1 | tee log_install && test -f .go-test && make -k check 2>&1 | tee log_test --> @@ -147,9 +149,7 @@ x86 GNU/Linux' and GNU/Hurd's configurations are slightly different, thus mask out most of the differences that are due to GNU/Linux supporting more core file formats, and more emulation vectors. - $ ssh kepler.SCHWINGE 'cd tmp/source/binutils/ && cat hurd/master.build/log_build* | sed -e "s%\(/media/data\)\?${PWD}%[...]%g"' > toolchain/logs/binutils/linux/log_build - $ ssh coulomb.SCHWINGE 'cd tmp/binutils/ && cat hurd/master.build/log_build* | sed -e "s%\(/media/erich\)\?${PWD}%[...]%g"' > toolchain/logs/binutils/hurd/log_build - $ diff -wu <(sed -f toolchain/logs/binutils/linux/log_build.sed < toolchain/logs/binutils/linux/log_build) <(sed -f toolchain/logs/binutils/hurd/log_build.sed < toolchain/logs/binutils/hurd/log_build) > toolchain/logs/binutils/log_build.diff + $ toolchain/logs/process binutils build # Install @@ -163,9 +163,7 @@ min on coulomb.SCHWINGE. ## Analysis - $ ssh kepler.SCHWINGE 'cd tmp/source/binutils/ && cat hurd/master.build/log_install | sed -e "s%\(/media/data\)\?${PWD}%[...]%g"' > toolchain/logs/binutils/linux/log_install - $ ssh coulomb.SCHWINGE 'cd tmp/binutils/ && cat hurd/master.build/log_install | sed -e "s%\(/media/erich\)\?${PWD}%[...]%g"' > toolchain/logs/binutils/hurd/log_install - $ diff -wu <(sed -f toolchain/logs/binutils/linux/log_install.sed < toolchain/logs/binutils/linux/log_install) <(sed -f toolchain/logs/binutils/hurd/log_install.sed < toolchain/logs/binutils/hurd/log_install) > toolchain/logs/binutils/log_install.diff + $ toolchain/logs/process binutils install * `libtool: finish`: `ldconfig` is not run for the Hurd. @@ -177,13 +175,11 @@ min on coulomb.SCHWINGE. This needs roughly 3 min on kepler.SCHWINGE and 13 min on coulomb.SCHWINGE. - $ ssh kepler.SCHWINGE 'cd tmp/source/binutils/ && cat hurd/master.build/*/*.sum hurd/master.build/*/*/*.sum | sed -e "s%\(/media/data\)\?${PWD}%[...]%g"' > toolchain/logs/binutils/linux/sum - $ ssh coulomb.SCHWINGE 'cd tmp/binutils/ && cat hurd/master.build/*/*.sum hurd/master.build/*/*/*.sum | sed -e "s%\(/media/erich\)\?${PWD}%[...]%g"' > toolchain/logs/binutils/hurd/sum - $ diff -u -F ^Running toolchain/logs/binutils/linux/sum toolchain/logs/binutils/hurd/sum > toolchain/logs/binutils/sum.diff - ## Analysis + $ toolchain/logs/process binutils test + * <a name="static"><!-- stable_URL -->`FAIL: static [...]`</a> The testsuite isn't prepared for using `crt0.o` instead of `crt1.o` diff --git a/open_issues/code_analysis.mdwn b/open_issues/code_analysis.mdwn index 4702fce6..2ab8bf1d 100644 --- a/open_issues/code_analysis.mdwn +++ b/open_issues/code_analysis.mdwn @@ -42,10 +42,13 @@ There is a [[!FF_project 276]][[!tag bounty]] on some of these tasks. "1123688017.3905.22.camel@buko.sinrega.org"]]. This could be checked by a static analysis tool. - * [Static Source Code Analysis Tools for C](http://spinroot.com/static/) - * [[!wikipedia List_of_tools_for_static_code_analysis]] + * [Engineering zero-defect software](http://esr.ibiblio.org/?p=4340), Eric + S. Raymond, 2012-05-13 + + * [Static Source Code Analysis Tools for C](http://spinroot.com/static/) + * [Cppcheck](http://sourceforge.net/apps/mediawiki/cppcheck/) For example, [Debian's hurd_20110319-2 @@ -59,13 +62,9 @@ There is a [[!FF_project 276]][[!tag bounty]] on some of these tasks. * <http://www.google.com/search?q=coccinelle+analysis> - * clang - - * <http://www.google.com/search?q=clang+analysis> + * [clang](http://www.google.com/search?q=clang+analysis) - * Linux' sparse - - * <https://sparse.wiki.kernel.org/> + * [Linux' sparse](https://sparse.wiki.kernel.org/) * <http://klee.llvm.org/> @@ -83,6 +82,12 @@ There is a [[!FF_project 276]][[!tag bounty]] on some of these tasks. * [sixgill](http://sixgill.org/) + * [s-spider](http://code.google.com/p/s-spider/) + + * [CIL (C Intermediate Language)](http://kerneis.github.com/cil/) + + * [Frama-C](http://frama-c.com/) + * [Coverity](http://www.coverity.com/) (nonfree?) * [Splint](http://www.splint.org/) @@ -102,8 +107,8 @@ There is a [[!FF_project 276]][[!tag bounty]] on some of these tasks. * Used by GDB, for example. - * Is not thread-safe, [[!sourceware_bug 6547]], [[!sourceware_bug 9939]], - [[!sourceware_bug 12751]], [[!stackoverflow_question 314931]]. + * Is not thread-safe, [[!sourceware_PR 6547]], [[!sourceware_PR 9939]], + [[!sourceware_PR 12751]], [[!stackoverflow_question 314931]]. * <http://en.wikipedia.org/wiki/Electric_Fence> @@ -113,18 +118,25 @@ There is a [[!FF_project 276]][[!tag bounty]] on some of these tasks. * <https://wiki.ubuntu.com/CompilerFlags> - * IRC, freenode, #glibc, 2011-09-28 + * `MALLOC_CHECK_`/`MALLOC_PERTURB_` + + * IRC, freenode, #glibc, 2011-09-28 + + <vsrinivas> two things you can do -- there is an environment + variable (DEBUG_MALLOC_ iirc?) that can be set to 2 to make + ptmalloc (glibc's allocator) more forceful and verbose wrt error + checking + <vsrinivas> another is to grab a copy of Tor's source tree and copy + out OpenBSD's allocator (its a clearly-identifyable file in the + tree); LD_PRELOAD it or link it into your app, it is even more + aggressive about detecting memory misuse. + <vsrinivas> third, Red hat has a gdb python plugin that can + instrument glibc's heap structure. its kinda handy, might help? + <vsrinivas> MALLOC_CHECK_ was the envvar you want, sorry. - <vsrinivas> two things you can do -- there is an environment variable - (DEBUG_MALLOC_ iirc?) that can be set to 2 to make ptmalloc (glibc's - allocator) more forceful and verbose wrt error checking - <vsrinivas> another is to grab a copy of Tor's source tree and copy out - OpenBSD's allocator (its a clearly-identifyable file in the tree); - LD_PRELOAD it or link it into your app, it is even more aggressive - about detecting memory misuse. - <vsrinivas> third, Red hat has a gdb python plugin that can instrument - glibc's heap structure. its kinda handy, might help? - <vsrinivas> MALLOC_CHECK_ was the envvar you want, sorry. + * [`MALLOC_PERTURB_`](http://udrepper.livejournal.com/11429.html) + + * <http://git.fedorahosted.org/cgit/initscripts.git/diff/?id=deb0df0124fbe9b645755a0a44c7cb8044f24719> * In context of [[!message-id "1341350006-2499-1-git-send-email-rbraun@sceen.net"]]/the `alloca` issue @@ -140,6 +152,12 @@ There is a [[!FF_project 276]][[!tag bounty]] on some of these tasks. <youpi> ah, no, the libthreads code properly sets the guard, just for grow-up stacks + * GCC's AddressSanitizer (ASan; `-faddress-sanitizer`) + + [Finding races and memory errors with GCC instrumentation + (AddressSanitizer)](http://gcc.gnu.org/wiki/cauldron2012#Finding_races_and_memory_errors_with_GCC_instrumentation_.28AddressSanitizer.29), + GNU Tools Cauldron 2012. + * Input fuzzing Not a new topic; has been used (and a paper published) for early UNIX diff --git a/open_issues/exec_memory_leaks.mdwn b/open_issues/exec_memory_leaks.mdwn new file mode 100644 index 00000000..1a73ce9a --- /dev/null +++ b/open_issues/exec_memory_leaks.mdwn @@ -0,0 +1,24 @@ +[[!meta copyright="Copyright © 2012 Free Software Foundation, Inc."]] + +[[!meta license="""[[!toggle id="license" text="GFDL 1.2+"]][[!toggleable +id="license" text="Permission is granted to copy, distribute and/or modify this +document under the terms of the GNU Free Documentation License, Version 1.2 or +any later version published by the Free Software Foundation; with no Invariant +Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license +is included in the section entitled [[GNU Free Documentation +License|/fdl]]."]]"""]] + +[[!tag open_issue_hurd]] + +There are is some memory leak in [[`exec`|hurd/translator/exec]]. After twelve +hours worth of `fork/exec` ([[GCC]]'s `check-c` part of the testsuite), we got: + + PID UID PPID PGrp Sess TH Vmem RSS %CPU User System Args + 4 0 3 1 1 10 392M 262M 0.0 2:18.29 2hrs /hurd/exec + +The *RSS* seems a tad high. Also the system part of CPU time consumption is +quite noticeable. In comparison: + + 0 0 1 1 1 19 131M 1.14M 0.0 3:30.25 9:17.79 /hurd/proc + 3 0 1 1 1 224 405M 12.6M 0.2 42:20.25 67min ext2fs --readonly --multiboot-command-line=root=device:hd0s6 --host-priv-port=1 --device-master-port=2 --exec-server-task=3 -T typed device:hd0s6 + 276 0 3 1 1 344 442M 28.2M 0.6 48:09.36 91min /hurd/ext2fs /dev/hd2s5 diff --git a/open_issues/fifo_thread_explosion.mdwn b/open_issues/fifo_thread_explosion.mdwn new file mode 100644 index 00000000..08f682f2 --- /dev/null +++ b/open_issues/fifo_thread_explosion.mdwn @@ -0,0 +1,20 @@ +[[!meta copyright="Copyright © 2012 Free Software Foundation, Inc."]] + +[[!meta license="""[[!toggle id="license" text="GFDL 1.2+"]][[!toggleable +id="license" text="Permission is granted to copy, distribute and/or modify this +document under the terms of the GNU Free Documentation License, Version 1.2 or +any later version published by the Free Software Foundation; with no Invariant +Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license +is included in the section entitled [[GNU Free Documentation +License|/fdl]]."]]"""]] + +[[!tag open_issue_hurd]] + +As reported in [[!message-id "87sj80yb3e.fsf@kepler.schwinge.homeip.net"]], +after a [[GCC]] build (native, so three stages bootstrap), we got: + + PID UID PPID PGrp Sess TH Vmem RSS %CPU User System Args + 449 1000 3 1 1 10118 782M 198M 0.0 0:40.78 2:26.65 /hurd/fifo + +The other processes, in particular two instances of ext2fs and one of [[exec]], +looked reasonable. diff --git a/open_issues/gcc.mdwn b/open_issues/gcc.mdwn index d9940716..574a743b 100644 --- a/open_issues/gcc.mdwn +++ b/open_issues/gcc.mdwn @@ -31,14 +31,14 @@ example. Especially all the compiler magic is all the same. <!-- git checkout reviewed -git log --reverse --pretty=fuller --stat=$COLUMNS,$COLUMNS -p -C --cc ..upstream/trunk +git log --reverse --topo-order --pretty=fuller --stat=$COLUMNS,$COLUMNS -w -p -C --cc ..upstream/trunk -i -/^commit |^---$|hurd|linux|nptl|glibc +/^commit |^Merge:|^---$|hurd|linux|nacl|nptl|glibc|gs: --> -Last reviewed up to the [[Git mirror's dfed30bca14de84e0446cc02f5a27407dbfdc3e1 -(2012-06-11) sources|source_repositories/gcc]]. +Last reviewed up to the [[Git mirror's 769bf18a20ee2540ca7601cdafabd62b18b9751b +(2012-10-01) sources|source_repositories/gcc]]. <http://gcc.gnu.org/install/configure.html> has documentation for the `configure` switches. @@ -74,24 +74,27 @@ Last reviewed up to the [[Git mirror's dfed30bca14de84e0446cc02f5a27407dbfdc3e1 * [[`libmudflap`|libmudflap]]. - * Might [`-fsplit-stack`](http://nickclifton.livejournal.com/6889.html) be - worthwhile w.r.t. our [[multithreaded|multithreading]] libraries? + * [`-fsplit-stack`](http://nickclifton.livejournal.com/6889.html) * Also see `libgcc/config/i386/morestack.S`: comments w.r.t - `TARGET_THREAD_SPLIT_STACK_OFFSET`; likely needs porting. + `TARGET_THREAD_SPLIT_STACK_OFFSET`/`%gs:0x30` usage; likely needs + porting. - As per `libgcc/config/i386/t-stack-i386`, the former file is only used for - `-fsplit-stack` support -- which is currently enabled for us in - `libgcc/config.host`, but not usable via GCC proper. + * As per `libgcc/config/i386/t-stack-i386`, the former file is only used + for `-fsplit-stack` support -- which is currently enabled for us in + `libgcc/config.host`. * `gcc/config/gnu-user.h` defines `*SPLIT_STACK*` macros -- which aren't valid for us (yet), I think. + * Might `-fsplit-stack` be useful for us with respect to our + [[multithreaded|multithreading]] libraries? + * `--enable-languages=[...]` - * GNAT is not yet ported / bootstrapped? + * [[Ada (GNAT)|GNAT]] support is work in progress. - * The Google Go's libgo (introduced in + * The [[Google Go's libgo|gccgo]] (introduced in e440a3286bc89368b8d3a8fd6accd47191790bf2 (2010-12-03)) needs OS configuration / support. @@ -136,9 +139,13 @@ Last reviewed up to the [[Git mirror's dfed30bca14de84e0446cc02f5a27407dbfdc3e1 * [-fstack-protector shouldn't use TLS in freestanding mode](http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29838) + * See also commit bf1c0af128f33bd342636c4afeaa8f3a8a7cf8ca (reverted in + commit a204f0622242865ffea889bd698bc7c7bd236bd1), commit + 05c1aa95e6c37b3b281d749c76c673392941a031. + * Check before/after Joseph changes. (Should be fine.) - * 34618b3190c110b8926cc2b1db4b4eac95451995 + * 34618b3190c110b8926cc2b1db4b4eac95451995 »config-list.mk« What's this used for? (Check ML.) Ask to include i686-pc-gnu (once it is buildable out of the box)? See also @@ -194,6 +201,17 @@ Last reviewed up to the [[Git mirror's dfed30bca14de84e0446cc02f5a27407dbfdc3e1 to find out why some stuff wasn't compiling even after kfreebsd porting patches adding preprocessors checks for __GLIBC__ + GNU/kFreeBSD and GNU/kNetBSD: commit + 6396cc37141180db4d2c8f73cab4f5977d8a1e19 (2004-06-24, r83577), + GNU/kOpenSolaris: commit 3bef40126fb1633018fce47828df0fa9f65f110c + (2009-01-29, r143768). See also GDB commits + fda1b24c62843f81d31de2af57b1ed9c55f1e348 and + 1acb4f4ff73d20850a7524fc939d2651be75f47b, and binutils commits + e3081899be7570eb90ccfd5d767950d3a62871ee, + 127c4d4a4fe65bd17ea64db1be7f3c93d393afcb, + 47dbf5b634b955c2db1221715d15751e1281546a, and + ad2be7e8b846f4cd67fa1e032f98d5dc1cdb6b8d. + IRC, freenode, #hurd, 2012-05-25: <gnu_srs> Hi, looks like __GLIBC__ is not defined by default for GNU? @@ -248,6 +266,8 @@ Last reviewed up to the [[Git mirror's dfed30bca14de84e0446cc02f5a27407dbfdc3e1 <pinotree> what should be done first is, however, find out why that define has been added to gcc + [[!message-id "201211061305.02565.pino@debian.org"]]. + * [low] Does `-mcpu=native` etc. work? (For example, 2ae1f0cc764e998bfc684d662aba0497e8723e52.) @@ -278,18 +298,20 @@ Last reviewed up to the [[Git mirror's dfed30bca14de84e0446cc02f5a27407dbfdc3e1 C.f. [[!message-id "x57jobtqx89w.fsf@frobland.mtv.corp.google.com"]], [[!message-id "x57jd359fkx3.fsf@frobland.mtv.corp.google.com"]] as well as [[!debbug 629866]]/[[!message-id - "20110609002620.GA16719@const.famille.thibault.fr"]]. + "20110609002620.GA16719@const.famille.thibault.fr"]]. commit + 026e608ecebcb2a6193971006a85276307d79b00. # Build Here's a log of a GCC build run; this is from our [[Git repository's -2e2db3f92b534460c68c2f9ae64455884424beb6 (2012-06-15; 2012-06-06) +b401cb7ed15602d244a6807835b0b9d740a302a8 (2012-11-26; +769bf18a20ee2540ca7601cdafabd62b18b9751b (2012-10-01)) sources|source_repositories/gcc]], run on kepler.SCHWINGE and coulomb.SCHWINGE. $ export LC_ALL=C $ (cd ../master/ && contrib/gcc_update --touch) - $ ../master/configure --prefix="$PWD".install SHELL=/bin/dash CC=gcc-4.6 CXX=g++-4.6 --enable-build-with-cxx --enable-languages=all,ada 2>&1 | tee log_build + $ ../master/configure --prefix="$PWD".install SHELL=/bin/dash CC=gcc-4.6 CXX=g++-4.6 --enable-languages=all,ada 2>&1 | tee log_build [...] $ make 2>&1 | tee log_build_ [...] @@ -297,12 +319,12 @@ sources|source_repositories/gcc]], run on kepler.SCHWINGE and coulomb.SCHWINGE. Different hosts may default to different shells and compiler versions; thus harmonized. -This takes up around 3.1 GiB, and needs roughly 3.0 h on kepler.SCHWINGE and -12.75 h on coulomb.SCHWINGE. +This takes up around 3.1 GiB, and needs roughly 3.25 h on kepler.SCHWINGE and +13.25 h on coulomb.SCHWINGE. <!-- - $ (make && touch .go-install) 2>&1 | tee log_build_ && test -f .go-install && (make install && touch .go-check) 2>&1 | tee log_install && test -f .go-check && make -k RUNTESTFLAGS=-v check 2>&1 | tee log_check + $ (make && touch .go-install) 2>&1 | tee log_build_ && test -f .go-install && (make install && touch .go-test) 2>&1 | tee log_install && test -f .go-test && make -k RUNTESTFLAGS=-v check 2>&1 | tee log_test --> @@ -382,7 +404,7 @@ This takes up around 3.1 GiB, and needs roughly 3.0 h on kepler.SCHWINGE and Just different order of object files, or another problem? TODO - * `libobjc/encoding.c`: + * `libobjc/encoding.c`: libtool: compile: [...]/hurd/master.build/./gcc/xgcc [...] [...]/hurd/master/libobjc/encoding.c -c [...] +[...]/hurd/master/libobjc/encoding.c:128:1: warning: '_darwin_rs6000_special_round_type_align' defined but not used [-Wunused-function] @@ -416,9 +438,11 @@ This takes up around 3.1 GiB, and needs roughly 3.0 h on kepler.SCHWINGE and * *default library search path* - -checking for the default library search path... /lib /usr/lib /lib/i386-linux-gnu /usr/lib/i386-linux-gnu /lib/i486-linux-gnu /usr/lib/i486-linux-gnu /usr/local/lib /lib64 /usr/lib64 + -checking for the default library search path... /lib /usr/lib /lib/i386-linux-gnu /usr/lib/i386-linux-gnu /lib/i486-linux-gnu /usr/lib/i486-linux-gnu /usr/local/lib +checking for the default library search path... /lib /usr/lib + [[binutils]] issue? Should be aligned by Samuel's binutils patch. + * `./classpath/[...]/*.properties` Just different order of files, or another problem? @@ -452,13 +476,6 @@ This takes up around 3.1 GiB, and needs roughly 3.0 h on kepler.SCHWINGE and There are other instances of this in the following. - * *default library search path* - - -checking for the default library search path... /lib /usr/lib /lib/[MULTIARCH] /usr/lib/[MULTIARCH] /lib/i486-linux-gnu /usr/lib/i486-linux-gnu /usr/local/lib /lib64 /usr/lib64 - +checking for the default library search path... /lib /usr/lib - - Should be aligned by Samuel's binutils patch. - * `value-unwind.h` -DEFINES='' HEADERS='../../../master/libgcc/config/i386/value-unwind.h' \ @@ -482,13 +499,22 @@ This takes up around 3.1 GiB, and needs roughly 3.0 h on kepler.SCHWINGE and * `libatomic` on GNU/Linux compiles several more files than on GNU/Hurd. Is that correct? Probably futex support. + * 2e2db3f92b534460c68c2f9ae64455884424beb6..3336556d2cb32f46322922a83015f760cfb79d8f + + Both GNU/Linux and GNU/Hurd: + + -checking assembler for rep and lock prefix... yes + +checking assembler for rep and lock prefix... no + + TODO. + # Install $ make install 2>&1 | tee log_install [...] -This takes up around 850 MiB, and needs roughly 4 min on kepler.SCHWINGE and 45 +This takes up around 850 MiB, and needs roughly 4 min on kepler.SCHWINGE and 35 min on coulomb.SCHWINGE. @@ -514,24 +540,158 @@ min on coulomb.SCHWINGE. Testing on GNU/Hurd is blocked on [[fork_mach_port_mod_refs_ekern_urefs_owerflow]]. -TODO. Can use parallel testing, see [[!message-id -"20110331070322.GI11563@sunsite.ms.mff.cuni.cz"]]. +TODO. On GNU/Hurd, it is advisable to reboot after having built and installed +GCC, before running the testsuite, as otherwise there seems to be a tendency +that the system crashes during the `gcc.c-torture/compile/limits-structnest.c` +tests, which are rather memory hungry, see [[!message-id +"87bol6aixd.fsf@schwinge.name"]]. Likewise, it also seems advisable to add +further reboots in between, that is, separate `make check`'s `check-host` into +several separate runs, and then one for `check-target` (see +`[build]/Makefile:do-check`, `[build]/gcc/Makefile:CHECK_TARGETS`), as +otherwise there seems to be a tendency for the system crashing sooner or later. +(Running `check-host` accumulates to something like 44 hours worth of +forking/execing of GCC and testcases.) On GNU/Linux we run it in one go, so +that we'll catch any fundamental rearrangements of/additions to the testsuites. + +kepler.SCHWINGE: + + $ make -k check 2>&1 | tee log_test + [...] + +coulomb.SCHWINGE: + + $ awk '/^maybe-check-target/ { next; }; /^maybe-check-[^:]*:./ { print; };' < Makefile + maybe-check-fixincludes: check-fixincludes + maybe-check-gcc: check-gcc + maybe-check-intl: check-intl + maybe-check-libbacktrace: check-libbacktrace + maybe-check-libcpp: check-libcpp + maybe-check-libdecnumber: check-libdecnumber + maybe-check-libiberty: check-libiberty + maybe-check-zlib: check-zlib + maybe-check-gnattools: check-gnattools + maybe-check-lto-plugin: check-lto-plugin + $ grep ^CHECK_TARGETS gcc/Makefile + CHECK_TARGETS = check-ada check-c check-c++ check-fortran check-java check-lto check-objc - $ make -k RUNTESTFLAGS=-v check 2>&1 | tee log_check + $ export LC_ALL=C + + $ make -k check-fixincludes 2>&1 | tee log_test_1_check-fixincludes + [...] + $ make -k -C gcc check-ada 2>&1 | tee log_test_2_gcc_check-ada + [...] + [reboot] + $ make -k -C gcc check-c 2>&1 | tee log_test_2_gcc_check-c + [...] + [reboot] + $ make -k -C gcc check-c++ 2>&1 | tee log_test_2_gcc_check-c++ + [...] + [reboot] + $ make -k -C gcc check-fortran check-java check-lto check-objc 2>&1 | tee log_test_2_gcc_check-fortran,check-java,check-lto,check-objc + [...] + [reboot] + $ make -k check-intl check-libbacktrace check-libcpp check-libdecnumber check-libiberty check-zlib check-gnattools check-lto-plugin 2>&1 | tee log_test_3 + [...] + $ make -k check-target 2>&1 | tee log_test_4_check-target [...] -This needs roughly 6.5 h on kepler.SCHWINGE and 50.25 h on coulomb.SCHWINGE. +This needs roughly 6.75 h on kepler.SCHWINGE and 3.5 h (`check-fixincludes`, +`gcc/check-ada`) + 10 h (`gcc/check-c`) + 3.75 h (`gcc/check-c++`) + 5.5 h +(`gcc/check-fortran`, `gcc/check-java`, `gcc/check-lto`, `gcc/check-objc`) + +8.25 h (`check-intl`, [...], `check-lto-plugin`, `check-target`) = 31 h on +coulomb.SCHWINGE. ## Analysis $ toolchain/logs/process gcc test -TODO. + * PTYs + + Occasionally tests FAIL due to: + + spawn -open -1 failed, 1 5, The system has no more ptys. Ask your system administrator to create more. + + TODO. + + * As of b401cb7ed15602d244a6807835b0b9d740a302a8 (2012-11-26; + 769bf18a20ee2540ca7601cdafabd62b18b9751b (2012-10-01)), all + `gcc.dg/guality` and `g++.dg/guality` and a few more are no longer tested + on coulomb.SCHWINGE and kepler.SCHWINGE. + + * As of b401cb7ed15602d244a6807835b0b9d740a302a8 (2012-11-26; + 769bf18a20ee2540ca7601cdafabd62b18b9751b (2012-10-01)), there are + regressions (FAILs) in libgomp execution tests on coulomb.SCHWINGE. + + * TODO + + +## Enhancements + + +### `contrib/testsuite-management/`, `contrib/regression/` + + * 35a27ee8c4b349fea44fd1fadc9614ab3cc9d578 `Add an xfail manifest for + x86_64-unknown-linux-gnu to trunk.` + + +### Parallel Testing + +[[!message-id "20110331070322.GI11563@sunsite.ms.mff.cuni.cz"]]. + + +### Distributed Testing + + +#### IRC, OFTC, #gcc, 2012-05-31 + <dnovillo> jsm28: in your mentor testing, you have the source and build + tree available for make check? or it's a pure installed-tree test? + <jsm28> dnovillo: Source tree, install tree, no build tree. + <dnovillo> jsm28: so, you run make check on top of the source tree or copy + the */testsuite trees to a testing area? + <jsm28> Create a site.exp and do runtest in a temporary directory. runtest + is pointed to the source tree to find sources. + <jsm28> For cross testing for GNU/Linux targets, the temporary directory is + mounted at the same path on host and target. + <dnovillo> jsm28: thanks. i guess i'll have to find the slice of the + source tree i need to copy. + <dnovillo> jsm28: for libstdc++ do you write a different site.exp? + <dnovillo> i noticed that it generates a different site,exp there. + <jsm28> The site.exp is mostly the same for all testsuites (so includes + settings that only some testsuites use). + <dnovillo> ok, thanks. + <dnovillo> and when you say "pointed to the source tree" you mean "set + srcdir /path/to/top/of/gcc" ? + <dnovillo> (in site.exp) + <jsm28> The GDB testsuite requires that you run the GDB testsuite's + configure script in the temporary directory where you will run runtest. + I don't think any GCC testsuites we use have requirements like that. + <jsm28> dnovillo: --srcdir option to runtest. + <dnovillo> ah, yes. + <jsm28> (and --tool, --target_board etc.) + <dnovillo> right + <dnovillo> since i'm distributing the tests. i want each node to only do a + bunch of files. this means that i either use 'tool.exp=file-pattern' or + simply copy the subset of files i want tool.exp to find. + <dnovillo> i chose the second approach, but that breaks in a handful of + cases that need files from other sub-directories. + <dnovillo> like g++.dg gcc.dg using stuff from c-c++-common. + <dnovillo> for libstdc++, the possibilities for splitting are enormous as + it has many directories. + <dnovillo> but i'm not setting it right. runtest runs without even trying + to test anything. + <dnovillo> i'm not having it pick up the right driver. + <jsm28> Probably all .exp files should be copied to anywhere running + testsuites, since some read .exp files from other directories. + <dnovillo> jsm28: that could be it too. it's irritating that libstdc++ + does not even error out. runtest just does nothing and returns 0. -# Specific Languages +##### IRC, OFTC, #gcc, 2012-06-06 - * [[GNAT]] + <dnovillo> any libstdc++ maintainer around? + <dnovillo> or, does anyone know when the testsuite/data files are copied + into the running testsuite/ dir? + <dnovillo> seems to be done in advance by make. - * [[gccgo]] +##### [[!message-id "4FC7791E.6040407@gmail.com"]] diff --git a/open_issues/gdb.mdwn b/open_issues/gdb.mdwn index 1652031b..f5daff48 100644 --- a/open_issues/gdb.mdwn +++ b/open_issues/gdb.mdwn @@ -24,8 +24,17 @@ Here's what's to be done for maintaining GNU GDB. # Configuration -Last reviewed up to the [[Git mirror's ea9812279fe436be9a010d07ef1dbe465199a3d7 -(2011-09-07) sources|source_repositories/gdb]]. +<!-- + +git checkout reviewed +git log --reverse --topo-order --pretty=fuller --stat=$COLUMNS,$COLUMNS -w -p -C --cc ..sourceware/master +-i +/^commit |^merge:|^---$|hurd|linux|nacl|nptl|glibc|gs:|gnu-nat|i386gnu + +--> + +Last reviewed up to the [[Git mirror's ded7dfe6274b281d92a6ed76cedf29d06c918dec +(2012-12-10) sources|source_repositories/gdb]]. * Globally @@ -51,15 +60,22 @@ Last reviewed up to the [[Git mirror's ea9812279fe436be9a010d07ef1dbe465199a3d7 * [[gdbserver]] + * 82763a3d329b0d342d0273941b1521be9ef0c604 »MODIFIED is unknown, pass it as + true.« + + * Configure so that Debian system's `/usr/lib/debug/[...]` will be loaded + automatically. + # Build -Here's a log of a GDB build run; this is from our [[Git repository's -695f61ff0f378e1680964128585044799de27015 (2011-09-06) -sources|source_repositories/gdb]], run on kepler.SCHWINGE and coulomb.SCHWINGE. +Here's a log of a GDB build run; this is from our [[Git +repository|source_repositories/gdb]]'s `tschwinge/Ferry_Tagscherer` branch, +commit ded7dfe6274b281d92a6ed76cedf29d06c918dec (2012-12-10), run on +kepler.SCHWINGE and coulomb.SCHWINGE. $ export LC_ALL=C - $ ../master/configure --prefix="$PWD".install SHELL=/bin/dash CC=gcc-4.6 CXX=g++-4.6 --disable-werror 2>&1 | tee log_build + $ ../Ferry_Tagscherer/configure --prefix="$PWD".install SHELL=/bin/dash CC=gcc-4.6 CXX=g++-4.6 --disable-werror 2>&1 | tee log_build [...] $ make 2>&1 | tee log_build_ [...] @@ -71,9 +87,15 @@ There are several occurences of *error: dereferencing type-punned pointer will break strict-aliasing rules* in the MIG-generated stub files; thus no `-Werror` until that is resolved ([[strict_aliasing]]). -This takes up around 140 MiB and needs roughly 6 min on kepler.SCHWINGE and 30 +This takes up around 200 MiB and needs roughly 7 min on kepler.SCHWINGE and 23 min on coulomb.SCHWINGE. +<!-- + + $ (make && touch .go-install) 2>&1 | tee log_build_ && test -f .go-install && (make install && touch .go-test) 2>&1 | tee log_install && test -f .go-test && make -k check 2>&1 | tee log_test + +--> + ## Analysis @@ -81,12 +103,86 @@ x86 GNU/Linux' and GNU/Hurd's configurations are slightly different, thus mask out most of the differences that are due to GNU/Linux supporting more core file formats and more emulation vectors. - $ ssh kepler.SCHWINGE 'cd tmp/source/gdb/ && cat hurd/master.build/log_build* | sed -e "s%\(/media/data\)\?${PWD}%[...]%g"' > toolchain/logs/gdb/linux/log_build - $ ssh coulomb.SCHWINGE 'cd tmp/gdb/ && cat hurd/master.build/log_build* | sed -e "s%\(/media/erich\)\?${PWD}%[...]%g"' > toolchain/logs/gdb/hurd/log_build - $ diff -wu <(sed -f toolchain/logs/gdb/linux/log_build.sed < toolchain/logs/gdb/linux/log_build) <(sed -f toolchain/logs/gdb/hurd/log_build.sed < toolchain/logs/gdb/hurd/log_build) > toolchain/logs/gdb/log_build.diff + $ toolchain/logs/process gdb build * Why do we specify `-D_GNU_SOURCE`, and GNU/Linux doesn't? + * GNU/Linux: `gdb/symfile-mem.c` for vDSO. + + * GNU/Linux: `gdb/i386-nat.c` for hardware breakpoints, etc. -- we should + probably use that, too. Related to Samuel's Hurd GDB patch? + + * `gdb/gnu-nat.c` + + gnu-nat.c: In function 'proc_set_exception_port': + gnu-nat.c:409:3: warning: format '%d' expects argument of type 'int', but argument 8 has type 'mach_port_t' [-Wformat] + gnu-nat.c: In function 'proc_steal_exc_port': + gnu-nat.c:449:7: warning: format '%d' expects argument of type 'int', but argument 8 has type 'mach_port_t' [-Wformat] + gnu-nat.c:470:7: warning: format '%d' expects argument of type 'int', but argument 8 has type 'mach_port_t' [-Wformat] + gnu-nat.c: In function 'make_proc': + gnu-nat.c:583:7: warning: format '%d' expects argument of type 'int', but argument 2 has type 'mach_port_t' [-Wformat] + gnu-nat.c:586:7: warning: format '%d' expects argument of type 'int', but argument 8 has type 'mach_port_t' [-Wformat] + gnu-nat.c: In function 'inf_set_pid': + gnu-nat.c:761:3: warning: format '%d' expects argument of type 'int', but argument 7 has type 'task_t' [-Wformat] + gnu-nat.c: In function 'inf_validate_procs': + gnu-nat.c:1085:6: warning: format '%d' expects argument of type 'int', but argument 8 has type 'thread_t' [-Wformat] + gnu-nat.c: In function 'inf_signal': + gnu-nat.c:1349:4: warning: format '%d' expects argument of type 'int', but argument 7 has type 'thread_t' [-Wformat] + gnu-nat.c:1349:4: warning: format '%d' expects argument of type 'int', but argument 8 has type 'thread_t' [-Wformat] + gnu-nat.c: In function 'S_exception_raise_request': + gnu-nat.c:1668:3: warning: format '%d' expects argument of type 'int', but argument 7 has type 'thread_t' [-Wformat] + gnu-nat.c:1668:3: warning: format '%d' expects argument of type 'int', but argument 8 has type 'task_t' [-Wformat] + gnu-nat.c:1705:8: warning: format '%d' expects argument of type 'int', but argument 7 has type 'mach_port_t' [-Wformat] + gnu-nat.c:1711:8: warning: format '%d' expects argument of type 'int', but argument 7 has type 'mach_port_t' [-Wformat] + gnu-nat.c: In function 'do_mach_notify_dead_name': + gnu-nat.c:1762:3: warning: format '%d' expects argument of type 'int', but argument 7 has type 'mach_port_t' [-Wformat] + gnu-nat.c: In function 'gnu_write_inferior': + gnu-nat.c:2383:8: warning: format '%x' expects argument of type 'unsigned int', but argument 2 has type 'vm_address_t' [-Wformat] + gnu-nat.c:2393:8: warning: format '%x' expects argument of type 'unsigned int', but argument 2 has type 'vm_address_t' [-Wformat] + gnu-nat.c: In function 'steal_exc_port': + gnu-nat.c:2864:5: warning: format '%d' expects argument of type 'int', but argument 2 has type 'mach_port_t' [-Wformat] + + + * fe19822761b4635f392875a186e48af446b40f41..7a63e9515491f21eaf07301df87d389def20e317): + + `-Wmissing-prototypes` + + gnu-nat.c: At top level: + gnu-nat.c:643:1: warning: no previous prototype for 'make_inf' [] + gnu-nat.c: At top level: + gnu-nat.c:879:1: warning: no previous prototype for 'inf_set_traced' [] + gnu-nat.c:980:1: warning: no previous prototype for 'inf_port_to_thread' [] + gnu-nat.c: At top level: + gnu-nat.c:1748:1: warning: no previous prototype for 'inf_task_died_status' [] + gnu-nat.c: At top level: + gnu-nat.c:2273:1: warning: no previous prototype for 'gnu_read_inferior' [] + gnu-nat.c:2319:1: warning: no previous prototype for 'gnu_write_inferior' [] + gnu-nat.c: At top level: + gnu-nat.c:3415:1: warning: no previous prototype for '_initialize_gnu_nat' [] + notify_S.c:305:24: warning: no previous prototype for 'notify_server' [] + notify_S.c:341:28: warning: no previous prototype for 'notify_server_routine' [] + process_reply_S.c:343:24: warning: no previous prototype for 'process_reply_server' [] + process_reply_S.c:379:28: warning: no previous prototype for 'process_reply_server_routine' [] + msg_reply_S.c:165:24: warning: no previous prototype for 'msg_reply_server' [] + msg_reply_S.c:201:28: warning: no previous prototype for 'msg_reply_server_routine' [] + exc_request_S.c:157:24: warning: no previous prototype for 'exc_server' [] + exc_request_S.c:193:28: warning: no previous prototype for 'exc_server_routine' [] + + * `dlopen`/`-ldl` + + -checking for library containing dlopen... none required + +checking for library containing dlopen... -ldl + + * `O_NOFOLLOW` + + First seen in + 20f498edfd7e57d3297febcf9c7c7d667cc74239..69a5e2b022c7d15ec4c7c49e6f53a8d924d3b72b: + + -checking for working fcntl.h... yes + +checking for working fcntl.h... no (bad O_NOFOLLOW) + + [[!taglink open_issue_glibc]]? + * Why does GNU/Linux have an additional `-ldl -rdynamic` when linking `gdb`? @@ -95,33 +191,125 @@ formats and more emulation vectors. $ make install 2>&1 | tee log_install [...] -This takes up around 50 MiB, and needs roughly 1 min on kepler.SCHWINGE and 3 +This takes up around 50 MiB, and needs roughly 1 min on kepler.SCHWINGE and 2 min on coulomb.SCHWINGE. ## Analysis - $ ssh kepler.SCHWINGE 'cd tmp/source/gdb/ && cat hurd/master.build/log_install | sed -e "s%\(/media/data\)\?${PWD}%[...]%g"' > toolchain/logs/gdb/linux/log_install - $ ssh coulomb.SCHWINGE 'cd tmp/gdb/ && cat hurd/master.build/log_install | sed -e "s%\(/media/erich\)\?${PWD}%[...]%g"' > toolchain/logs/gdb/hurd/log_install - $ diff -wu <(sed -f toolchain/logs/gdb/linux/log_install.sed < toolchain/logs/gdb/linux/log_install) <(sed -f toolchain/logs/gdb/hurd/log_install.sed < toolchain/logs/gdb/hurd/log_install) > toolchain/logs/gdb/log_install.diff + $ toolchain/logs/process gdb install * `libtool: finish`: `ldconfig` is not run for the Hurd. # Testsuite -On GNU/Hurd, hampered by the [[term_blocking]] issue. - $ make -k check [...] -This needs roughly 45 min on kepler.SCHWINGE and TODO min on coulomb.SCHWINGE. +This needs roughly 14 min on kepler.SCHWINGE and 110 min on coulomb.SCHWINGE. - $ ssh kepler.SCHWINGE 'cd tmp/source/gdb/ && sed -e "s%\(/media/data\)\?${PWD}%[...]%g" < hurd/master.build/gdb/testsuite/gdb.sum' > toolchain/logs/gdb/linux/sum - $ ssh coulomb.SCHWINGE 'cd tmp/gdb/ && sed -e "s%\(/media/erich\)\?${PWD}%[...]%g" < hurd/master.build/gdb/testsuite/gdb.sum' > toolchain/logs/gdb/hurd/sum - $ diff -u -F ^Running toolchain/logs/gdb/linux/sum toolchain/logs/gdb/hurd/sum > toolchain/logs/gdb/sum.diff +When running `make -k check 2>&1 | tee log_test`, at the end of the testsuite +the `tee` process does not terminate if there are still stray leftover +processes that [have their stdout/stderr +open](http://sourceware.org/ml/gdb-patches/2012-10/msg00489.html). `kill`ing +these (`SIGKILL` may be needed), makes the `tee` process terminate, too. On +GNU/Hurd, these generally are `gdb.multi/watchpoint-multi`, and an unknown +(`?`) one ("57 PIDs before" `expect [...] gdb.cp`). ## Analysis + $ toolchain/logs/process gdb test + + * Disabled + + * `gdb.base/readline.exp` + + [[term_blocking]] issue. + + * `gdb.base/sigall.exp` + + From `send signal TSTP` on, all FAIL running into timeouts. + + * `gdb.python/py-inferior.exp` (mostly disabled) + + Running ../../../Ferry_Tagscherer/gdb/testsuite/gdb.python/py-inferior.exp ... + [...] + python print 'result =', i0.was_attached + result = False + (gdb) PASS: gdb.python/py-inferior.exp: test Inferior.was_attached + python print i0.threads () + (<gdb.InferiorThread object at 0x61170>, <gdb.InferiorThread object at 0x61160>) + (gdb) FAIL: gdb.python/py-inferior.exp: test Inferior.threads + break check_threads + Breakpoint 2 at 0x8048869: file ../../../Ferry_Tagscherer/gdb/testsuite/gdb.python/py-inferior.c, line 61. + (gdb) continue + Continuing. + [New Thread 25670.6] + [New Thread 25670.7] + [New Thread 25670.8] + [New Thread 25670.9] + [New Thread 25670.10] + [New Thread 25670.11] + [New Thread 25670.12] + [New Thread 25670.13] + + Breakpoint 2, check_threads (barrier=0x15ff144) at ../../../Ferry_Tagscherer/gdb/testsuite/gdb.python/py-inferior.c:61 + 61 pthread_barrier_wait (barrier); + (gdb) PASS: gdb.python/py-inferior.exp: continue to breakpoint: cont to check_threads + python print len (i0.threads ()) + 10 + (gdb) FAIL: gdb.python/py-inferior.exp: test Inferior.threads 2 + break 28 + Breakpoint 3 at 0x80487c2: file ../../../Ferry_Tagscherer/gdb/testsuite/gdb.python/py-inferior.c, line 28. + (gdb) continue + Continuing. + FAIL: gdb.python/py-inferior.exp: continue to breakpoint: cont to Break here. (timeout) + python addr = gdb.selected_frame ().read_var ('str') + FAIL: gdb.python/py-inferior.exp: read str address (timeout) + [All following tests FAIL with timeout.] + FAIL: gdb.python/py-inferior.exp: Switch to first inferior (timeout) + remove-inferiors 3 + FAIL: gdb.python/py-inferior.exp: Remove second inferior (timeout) + + At this point, the system hangs; no new processes can be spawned, so + perhaps an issue with the exec server. + + * `UNSUPPORTED: gdb.threads/ia64-sigill.exp: Couldn't compile ../../../master/gdb/testsuite/gdb.threads/ia64-sigill.c: unrecognized error` + + ../../../master/gdb/testsuite/gdb.threads/ia64-sigill.c:29:24: fatal error: asm/unistd.h: No such file or directory + + * `UNSUPPORTED: gdb.threads/multi-create.exp: Couldn't compile ../../../master/gdb/testsuite/gdb.threads/multi-create.c: unrecognized error` + ../../../master/gdb/testsuite/gdb.threads/multi-create.c: In function 'create_function': + ../../../master/gdb/testsuite/gdb.threads/multi-create.c:46:39: error: 'PTHREAD_STACK_MIN' undeclared (first use in this function) + ../../../master/gdb/testsuite/gdb.threads/multi-create.c:46:39: note: each undeclared identifier is reported only once for each function it appears in + ../../../master/gdb/testsuite/gdb.threads/multi-create.c: In function 'main': + ../../../master/gdb/testsuite/gdb.threads/multi-create.c:73:39: error: 'PTHREAD_STACK_MIN' undeclared (first use in this function) + + * `UNSUPPORTED: gdb.threads/staticthreads.exp: Couldn't compile ../../../master/gdb/testsuite/gdb.threads/staticthreads.c: unrecognized error` + + ../../../master/gdb/testsuite/gdb.threads/staticthreads.c: In function 'main': + ../../../master/gdb/testsuite/gdb.threads/staticthreads.c:52:37: error: 'PTHREAD_STACK_MIN' undeclared (first use in this function) + ../../../master/gdb/testsuite/gdb.threads/staticthreads.c:52:37: note: each undeclared identifier is reported only once for each function it appears in + + * `UNSUPPORTED: gdb.threads/watchpoint-fork.exp: parent: multithreaded: Couldn't compile ../../../Ferry_Tagscherer/gdb/testsuite/gdb.threads/watchpoint-fork-mt.c ../../../Ferry_Tagscherer/gdb/testsuite/gdb.threads/watchpoint-fork-parent.c: unrecognized error` + + ../../../Ferry_Tagscherer/gdb/testsuite/gdb.threads/watchpoint-fork-mt.c:29:24: fatal error: asm/unistd.h: No such file or directory + + * `UNSUPPORTED: gdb.threads/create-fail.exp: Couldn't compile ../../../Ferry_Tagscherer/gdb/testsuite/gdb.threads/create-fail.c: unrecognized error` + + [...]/gdb.threads/create-fail.c:77: undefined reference to `pthread_attr_setaffinity_np' + [...]/gdb.threads/create-fail.c:83: undefined reference to `pthread_create' + + * `UNSUPPORTED: gdb.threads/siginfo-threads.exp: Couldn't compile ../../../Ferry_Tagscherer/gdb/testsuite/gdb.threads/siginfo-threads.c: unrecognized error` + + ../../../Ferry_Tagscherer/gdb/testsuite/gdb.threads/sigstep-threads.c:22:24: fatal error: asm/unistd.h: No such file or directory + + * `UNTESTED: gdb.base/longest-types.exp: longest-types.exp` + + ../../../Ferry_Tagscherer/gdb/testsuite/gdb.base/longest-types.c:20:8: error: size of array 'buf' is too large + + Also on GNU/Linux. + TODO. diff --git a/open_issues/glibc.mdwn b/open_issues/glibc.mdwn index 3b4e5efa..734806a1 100644 --- a/open_issues/glibc.mdwn +++ b/open_issues/glibc.mdwn @@ -36,8 +36,8 @@ git log --reverse --pretty=fuller --stat=$COLUMNS,$COLUMNS -w -p -C --cc ..sourc --> -Last reviewed up to the [[Git mirror's e80d6f94e19d17b91e3cd3ada7193cc88f621feb -(2012-04-05) sources|source_repositories/glibc]]. +Last reviewed up to the [[Git mirror's d3bd58cf0a027016544949ffd27300ac5fb01bb8 +(2012-11-03) sources|source_repositories/glibc]]. * `t/hurdsig-fixes` @@ -47,7 +47,9 @@ Last reviewed up to the [[Git mirror's e80d6f94e19d17b91e3cd3ada7193cc88f621feb * `t/host-independency` - `libc-alpha` discussion/commit. GCC + [[!message-id "87bougerfb.fsf@kepler.schwinge.homeip.net"]], [[!message-id + "20120525202732.GA31088@intel.com"]], commit + 918b56067a444572f1c71b02f18255ae4540b043. [[!GCC_PR 53183]], GCC commit c05436a7e361b8040ee899266e15bea817212c37. * `t/sysvshm` @@ -151,7 +153,7 @@ Last reviewed up to the [[Git mirror's e80d6f94e19d17b91e3cd3ada7193cc88f621feb checking for i386_set_gdt in mach_i386.defs... yes checking whether i586-pc-gnu-mig supports the retcode keyword... yes - * `elf/stackguard-macros.h` + * `sysdeps/i386/stackguard-macros.h` See [[t/tls|t/tls]]. @@ -211,7 +213,8 @@ Last reviewed up to the [[Git mirror's e80d6f94e19d17b91e3cd3ada7193cc88f621feb `AT_EMPTY_PATH`, `CLOCK_BOOTTIME`, `CLOCK_BOOTTIME_ALARM`, `CLOCK_REALTIME_ALARM`, `O_PATH`, - `PTRACE_*` (for example, cbff0d9689c4d68578b6a4f0a17807232506ea27), + `PTRACE_*` (for example, cbff0d9689c4d68578b6a4f0a17807232506ea27, + b1b2aaf8eb9eed301ea8f65b96844568ca017f8b), `RLIMIT_RTTIME`, `SEEK_DATA` (`unistd.h`), `SEEK_HOLE` (`unistd.h`) `clock_adjtime`, `fallocate`, `fallocate64`, `name_to_handle_at`, `open_by_handle_at`, `process_vm_readv`, `process_vm_writev`, `sendmmsg`, @@ -301,7 +304,7 @@ Last reviewed up to the [[Git mirror's e80d6f94e19d17b91e3cd3ada7193cc88f621feb We should be easily able to implement that one. - * `futimesat`, `readlinkat`, `renameat` + * `futimesat`, `readlinkat` If we have all of 'em (check Linux kernel), `#define __ASSUME_ATFCTS`. @@ -310,6 +313,7 @@ Last reviewed up to the [[Git mirror's e80d6f94e19d17b91e3cd3ada7193cc88f621feb * `io/fcntl.h [__USE_ATFILE]` Do we support `AT_FDCWD` et al.? + (80b4e5f3ef231702b24d44c33e8dceb70abb3a06.) * `MAP_POPULATE` (`mmap`, `sys/mman.h`) -- *Populate (prefault) pagetables.* @@ -323,16 +327,15 @@ Last reviewed up to the [[Git mirror's e80d6f94e19d17b91e3cd3ada7193cc88f621feb make_pages_present(addr, addr + len); return addr; - `t/mmap`. - - Is only advisory, so can worked around with `#define 0`. + Is only advisory, so can worked around with `#define MAP_POPULATE 0`, + 8069478040336a7de3461be275432493cc7e4c91. * `t/opendirat`: `opendirat` (`scandirat`, `scandirat64`) Need changes equivalent to c55fbd1ea768f9fdef34a01377702c0d72cbc213 + 14d96785125abee5e9a49a1c3037f35a581750bd. - * `madvise`, `MADV_DONTNEED` + * `madvise`, `MADV_DONTNEED`, `MADV_DONTDUMP`, `MADV_DODUMP` [[glibc_madvise_vs_static_linking]]. @@ -762,9 +765,6 @@ Last reviewed up to the [[Git mirror's e80d6f94e19d17b91e3cd3ada7193cc88f621feb * 7fb90fb89bbdf273ab7ab96517fe1b156cd7aee1 + 6fb2dde3f1aa3a1419cb6c2dfa53dd1d506722a4 -- `Fix Linux getcwd for long paths` - * [low] [[!taglink open_issue_libpthread]] - 5bdcc10322c488f53557440acf71623d8b313ab5 -- return `EAGAIN` instead of - `ENOMEM`. * f574184a0e4b6ed69a5d9a3234543fba6d2a7367 -- `Fix sched_setscheduler call in spawn implementation` * 3b85df27870a47ed1db84e948e37a5a50a178a92 + @@ -852,8 +852,7 @@ Last reviewed up to the [[Git mirror's e80d6f94e19d17b91e3cd3ada7193cc88f621feb <http://gcc.gnu.org/onlinedocs/gcc/Function-Attributes.html>. * [low] `conformtest`, 3134156779108fe8b46e0f4cd60d837572faaa93 + 4efeffc1d583597e4f52985b9747269e47b754e2 + - d94a4670800de6e8f088b8630ad5142866127980 -- takes 1.75 h (out of 2.75 h - total) on coulomb.SCHWINGE -- disable? Should probably mirror + d94a4670800de6e8f088b8630ad5142866127980 -- should probably mirror `bits/siginfo.h` changes. * [low] stack guard, 6c6a98c983c44b440ae66d2aa8f32529a9dd7bfe, [[!message-id "4F3BE241.9090409@mentor.com"]] -- anything needed for @@ -864,12 +863,26 @@ Last reviewed up to the [[Git mirror's e80d6f94e19d17b91e3cd3ada7193cc88f621feb "Pine.LNX.4.64.1203090206420.18868@digraph.polyomino.org.uk"]] 02a6f887cb3e2c048937111eb4cf150d397609de -- probably should do the same for the generic version as used by GNU Hurd. - * [log] CFI for `_start`, 6a1bd2a100c958d30bbfe8c9b8f9071d24b7c3f4, + * [low] CFI for `_start`, 6a1bd2a100c958d30bbfe8c9b8f9071d24b7c3f4, [[!message-id "20120316180551.GA6291@host2.jankratochvil.net"]] -- what about other architectures? + * `linkobj/libc.so`, 510bbf14b4f25fec8ee3a2d24de3f24bdbf84333 -- need to + adapt for (conditional?) Sun RPC reversion (if that was the original + cause for the patch)? + * [low] `Add __fsword_t and use it in bits/statfs.h`, + 3e5aef87d76cfa7354f2b0d82b96e59280720796, [[!message-id + "20120517134700.GA19046@intel.com"]] -- only updates one copy of + `bits/statfs.h`; update the others, too, for consistency. + * [low] 789bd351b45f024b7f51e4886bf46b8e887ab6da: remove + `libc_hidden_def` in `sysdeps/mach/hurd/accept4.c`? + * 0948c3af9dfb3bc1312d6bed2f3a6bfd4e96eef4, + b80af2f40631871cf53a5e39d08d5d5516473b96, + 04570aaa8ad88caad303f8afe469beb4cf851e17 `_dl_initial_dtv`: OK? + * [very low] ea4d37b3169908615b7c17c9c506c6a6c16b3a26 `Implement + POSIX-generic sleep via nanosleep rather than SIGARLM.`: any benefit + using that one (with `sysdeps/mach/nanosleep.c`) instead of + `sysdeps/mach/sleep.c`? * *baseline* - * [high] `sendmmsg` usage, c030f70c8796c7743c3aa97d6beff3bd5b8dcd5d -- - need a `ENOSYS` stub. * ea4d37b3169908615b7c17c9c506c6a6c16b3a26 -- IRC, freenode, #hurd, 2012-11-20, pinotree: »tschwinge: i agree on your comments on ea4d37b3169908615b7c17c9c506c6a6c16b3a26, especially since mach's @@ -877,10 +890,18 @@ Last reviewed up to the [[Git mirror's e80d6f94e19d17b91e3cd3ada7193cc88f621feb call)«. +## Update + +`baseline`, `t/regenerate_configure` (could now be removed), +`t/master_backports`, `t/eglibc_backports`, `t/host-independency`, +`tschwinge/Roger_Whittaker` + + # Build Here's a log of a glibc build run; this is from our [[Git repository's -d7294bbed51242338c4e9c15e1ee74a763259faf (2012-06-21; 2012-03-28) ([[!message-id "878vfhdapq.fsf@schwinge.name"]] applied) +28b74f8dbc3eb639d35fc0f93021ac5eb1fde9a4 (2012-11-03; +fbeafedeea37e0af1984a6511018d159f5ceed6a (2012-11-03)) sources|source_repositories/glibc]], run on coulomb.SCHWINGE. $ export LC_ALL=C @@ -889,11 +910,12 @@ sources|source_repositories/glibc]], run on coulomb.SCHWINGE. $ make install_root=/INVALID 2>&1 | tee log_build_ [...] -This takes up around 500 MiB and needs roughly X min on kepler.SCHWINGE and 100 -min on coulomb.SCHWINGE. +This takes up around 500 MiB, and needs roughly X min on kepler.SCHWINGE and +100 min on coulomb.SCHWINGE. <!-- - $ (make install_root=/INVALID && touch .go-install) 2>&1 | tee log_build_ && test -f .go-install && (make install_root="$PWD".install install && touch .go-check) 2>&1 | tee log_install && test -f .go-check && ln -s /usr/lib/i386-*gnu/libstdc++.so.6 /lib/i386-*gnu/libpthread-stubs.so.0 /lib/i386-*gnu/libgcc_s.so.1 mach/libmachuser.so.1 hurd/libhurduser.so.0.3 ./ && make -k install_root=/INVALID check TIMEOUTFACTOR=10 2>&1 | tee log_test + + $ (make install_root=/INVALID && touch .go-install) 2>&1 | tee log_build_ && test -f .go-install && (make install_root="$PWD".install install && touch .go-test) 2>&1 | tee log_install && test -f .go-test && ln -s /usr/lib/i386-*gnu/libstdc++.so.6 /lib/i386-*gnu/libpthread-stubs.so.0 /lib/i386-*gnu/libgcc_s.so.1 mach/libmachuser.so.1 hurd/libhurduser.so.0.3 ./ && make -k install_root=/INVALID check fast-check=yes 2>&1 | tee log_test Mask out gcc-4.X (with possibly a backslash before the dot), GCC 4.5's column output for (warning, error) messages, GCC 4.6's `[-Wsomething]` or `[enabled by @@ -946,18 +968,7 @@ TODO. sysdeps/mach/hurd/ioctl.c: In function '__ioctl': sysdeps/mach/hurd/ioctl.c:306: warning: case value '0' not in enumerated type 'error_t' - * baseline - fd5bdc0924e0cfd1688b632068c1b26f3b0c88da..2ba92745c36eb3c3f3af0ce1b0aebd255c63a13b - introduces: - - genops.c: In function '_IO_flush_all_lockp': - genops.c:869:3: warning: passing argument 1 of '__save_FCT' makes pointer from integer without a cast [enabled by default] - genops.c:869:3: note: expected 'void *' but argument is of type 'int' - - A similar warning has already been (and still is) seen here: - - dl-iteratephdr.c:83:3: warning: passing argument 1 of '__save_FCT' makes pointer from integer without a cast [enabled by default] - dl-iteratephdr.c:83:3: note: expected 'void *' but argument is of type 'int' + [[!message-id "20120723195143.7F8142C0B9@topped-with-meat.com"]]. * baseline fd5bdc0924e0cfd1688b632068c1b26f3b0c88da..2ba92745c36eb3c3f3af0ce1b0aebd255c63a13b @@ -973,15 +984,6 @@ TODO. fd5bdc0924e0cfd1688b632068c1b26f3b0c88da..2ba92745c36eb3c3f3af0ce1b0aebd255c63a13b introduces: - ../sysdeps/i386/fpu/bits/fenv.h: Assembler messages: - ../sysdeps/i386/fpu/bits/fenv.h:125: Warning: translating to `fdivp %st,%st(1)' - - Should be fixed as of 2012-04-16. - - * baseline - fd5bdc0924e0cfd1688b632068c1b26f3b0c88da..2ba92745c36eb3c3f3af0ce1b0aebd255c63a13b - introduces: - nscd_gethst_r.c: In function '__nscd_get_nl_timestamp': nscd_gethst_r.c:112:4: warning: implicit declaration of function 'time' [-Wimplicit-function-declaration] @@ -994,19 +996,34 @@ TODO. 2ba92745c36eb3c3f3af0ce1b0aebd255c63a13b..7a270350a9bc3110cd5ba12bbd8c5c8c365e0032 introduces: - In file included from regex.c:62:0: - regcomp.c: In function 'init_word_char': - regcomp.c:935:4: warning: large integer implicitly truncated to unsigned type [-Woverflow] - regcomp.c:936:4: warning: large integer implicitly truncated to unsigned type [-Woverflow] - - In file included from pldd.c:230:0: - pldd-xx.c:26:0: warning: "static_assert" redefined [enabled by default] - ../assert/assert.h:119:0: note: this is the location of the previous definition - - Should be fixed as of 2012-04-16. - tst-relsort1.c:6:1: warning: function declaration isn't a prototype [-Wstrict-prototypes] + * baseline + fc56c5bbc1a0d56b9b49171dd377c73c268ebcfd..cbc818d0ee66065f3942beffdca82986615aa19a + introduces + + +gcc-4.6 tst-printf-round.c -c -std=gnu99 -fgnu89-inline -O2 -Wall -Winline -Wwrite-strings -fmerge-all-constants -frounding-math -g -Wno-parentheses -Wstrict-prototypes -I../include -I[...]/tschwinge/Roger_Whittaker.build-gcc-4. + +tst-printf-round.c: In function 'do_test': + +tst-printf-round.c:203:11: warning: passing argument 3 of 'test_hex_in_one_mode' discards 'const' qualifier from pointer target type [enabled by default] + +tst-printf-round.c:139:1: note: expected 'const char **' but argument is of type 'const char * const*' + +tst-printf-round.c:208:8: warning: passing argument 3 of 'test_hex_in_one_mode' discards 'const' qualifier from pointer target type [enabled by default] + +tst-printf-round.c:139:1: note: expected 'const char **' but argument is of type 'const char * const*' + +tst-printf-round.c:216:8: warning: passing argument 3 of 'test_hex_in_one_mode' discards 'const' qualifier from pointer target type [enabled by default] + +tst-printf-round.c:139:1: note: expected 'const char **' but argument is of type 'const char * const*' + +tst-printf-round.c:224:8: warning: passing argument 3 of 'test_hex_in_one_mode' discards 'const' qualifier from pointer target type [enabled by default] + +tst-printf-round.c:139:1: note: expected 'const char **' but argument is of type 'const char * const*' + + gcc-4.6 test-wcschr.c -c -std=gnu99 -fgnu89-inline -O2 -Wall -Winline -Wwrite-strings -fmerge-all-constants -frounding-math -g -Wno-parentheses -Wstrict-prototypes -I../include -I[...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486 + +In file included from test-wcschr.c:2:0: + +../string/test-strchr.c: In function 'check1': + +../string/test-strchr.c:249:3: warning: passing argument 1 of 'stupid_STRCHR' from incompatible pointer type [enabled by default] + +../string/test-strchr.c:77:1: note: expected 'const wchar_t *' but argument is of type 'char *' + +../string/test-strchr.c:249:22: warning: initialization from incompatible pointer type [enabled by default] + +../string/test-strchr.c:252:5: warning: passing argument 2 of 'check_result' from incompatible pointer type [enabled by default] + +../string/test-strchr.c:92:1: note: expected 'const wchar_t *' but argument is of type 'char *' + +../string/test-strchr.c:252:5: warning: passing argument 4 of 'check_result' from incompatible pointer type [enabled by default] + +../string/test-strchr.c:92:1: note: expected 'const wchar_t *' but argument is of type 'char *' + # Install @@ -1015,7 +1032,7 @@ TODO. $ make install_root="$PWD".install install 2>&1 | tee log_install [...] -This takes up around 100 MiB, and needs roughly X min on kepler.SCHWINGE and 18 +This takes up around 100 MiB, and needs roughly X min on kepler.SCHWINGE and 16 min on coulomb.SCHWINGE. @@ -1037,10 +1054,14 @@ TODO. # Testsuite - $ make -k install_root=/INVALID check 2>&1 | tee log_test + $ make -k install_root=/INVALID check fast-check=yes 2>&1 | tee log_test [...] -This needs roughly X h on kepler.SCHWINGE and 2.75 h on coulomb.SCHWINGE. +This needs roughly X min on kepler.SCHWINGE and 60 min on coulomb.SCHWINGE. + +Specifying `fast-check=yes` disables the `conformtest` which takes 1.75 h (out +of 2.75 h total) on coulomb.SCHWINGE, doesn't pass anyway, and clearly isn't +our most critical issue to solve. <!-- $ ssh kepler.SCHWINGE 'cd tmp/source/gdb/ && sed < hurd/master.build/gdb/testsuite/gdb.sum -e "s%\(/media/data\)\?${PWD}%[...]%g"' > open_issues/gdb/sum_linux @@ -1078,10 +1099,12 @@ There is quite a baseline of failures. `configure` magic akin to the `fixincludes` stuff (`gcc-4.4 -print-file-name=libstdc++.so.6`, etc.). - * `debug/tst-chk4`, `debug/tst-chk5`, `debug/tst-chk6`, `debug/tst-lfschk4`, - `debug/tst-lfschk5`, `debug/tst-lfschk6` + Even if that that is being worked around, the tests fail with: + + dlopen failed: [...]/libc.so.0.3: version `GLIBC_2.13_DEBIAN_31' not found (required by [...]/libstdc++.so.6) + dlopen failed: [...]/libc.so.0.3: version `GLIBC_2.13_DEBIAN_31' not found (required by [...]/libgcc_s.so.1) - Fail in the same way as the C ones, `tst-chk1..3`. + [[packaging_libpthread]]. * `io/ftwtest`, `posix/globtest`, `iconvdata/iconv-test`, `intl/tst-gettext`, `malloc/tst-mtrace`, `elf/tst-pathopt`, `iconvdata/tst-tables`, @@ -1111,7 +1134,7 @@ There is quite a baseline of failures. SIGSEGV. - * `rt/tst-aio10`, `rt/tst-aio9` + * `rt-tst-aio2`, `rt-tst-aio3`, `rt/tst-aio10`, `rt/tst-aio9` /home/thomas/tmp/glibc/tschwinge/Roger_Whittaker.build-gcc-4.4-486.O/rt/tst-aio10.o: In function `do_test': tst-aio10.c:(.text+0x1b): undefined reference to `pthread_self' @@ -1124,7 +1147,7 @@ There is quite a baseline of failures. collect2: ld returned 1 exit status make[2]: *** [/home/thomas/tmp/glibc/tschwinge/Roger_Whittaker.build-gcc-4.4-486.O/rt/tst-aio10] Error 1 - * `rt-tst-aio2`, `rt-tst-aio3`, `rt/tst-mqueue3`, `rt/tst-mqueue6`, + * `rt/tst-mqueue3`, `rt/tst-mqueue6`, `rt/tst-mqueue8`, `elf/tst-thrlock`, `rt/tst-timer3`, `nss//libnss_test1.so` @@ -1141,7 +1164,7 @@ There is quite a baseline of failures. Will either need a `hurd/netinet/if_ether.h` that includes `<net/if_ether.h>`, or can do that in the generic `netinet/if_ether.h`? - See also [[!sourceware_bug 11142]]. + See also [[!sourceware_PR 11142]]. * `gmon/tst-sprofil` @@ -1159,7 +1182,10 @@ There is quite a baseline of failures. getcontext failed, errno: 1073741902. - Is not implemented; see above. + Is not implemented; see above. In 8958805c11c741d9211e20612c86271d906c9a0b + testing, `stdlib/bug-getcontext.out` now says: *Skipping test; no support + for FP exceptions.*, in cba1c83ad62a11347684a9daf349e659237a1741 testing, + it's back to the previous failure. * `elf/tst-unique3lib.so`, `elf/tst-unique3lib2.so`, `elf/tst-unique4lib.so` @@ -1181,11 +1207,56 @@ There is quite a baseline of failures. `expected-results-i486-gnu-libc`). * `elf/tst-unused-dep.out` (1f393a11f65dcaa1952bdcaf0317a65a5f8aff9d, - [[!sourceware_bug 13706]], [[!message-id "4F4210C1.1090704@redhat.com"]]) + [[!sourceware_PR 13706]], [[!message-id "4F4210C1.1090704@redhat.com"]]) Unused direct dependencies: /home/thomas/tmp/glibc/tschwinge/Roger_Whittaker.build-gcc-4.6-486/dlfcn/libdl.so.2 + As of 8958805c11c741d9211e20612c86271d906c9a0b, this test now passes -- + correct? + + * `stdlib/tst-secure-getenv.out` + + Needs [[`/proc/self/exe`|hurd/translator/procfs/jkoenig/discussion]]. + + * `elf/tst-array*` + + Failures also seen on GNU/Linux; [[!message-id + "50950082.1070906@df1tl.local.here"]]. + + gcc-4.6 tst-array1.c -c -std=gnu99 -fgnu89-inline -O2 -Wall -Winline -Wwrite-strings -fmerge-all-constants -frounding-math -g -Wno-parentheses -Wstrict-prototypes -I../include -I[...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/ + gcc-4.6 -nostdlib -nostartfiles -o [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/tst-array1 -Wl,-dynamic-linker=/lib/ld.so.1 -Wl,-z,combreloc -Wl,-z,relro -Wl,--hash-style=both [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486 + [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/ld.so.1 --library-path [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486:[...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/math:[...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf:[ + cmp [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/tst-array1.out tst-array1.exp > /dev/null + make[2]: *** [[...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/tst-array1.out] Error 1 + gcc-4.6 tst-array2.c -c -std=gnu99 -fgnu89-inline -O2 -Wall -Winline -Wwrite-strings -fmerge-all-constants -frounding-math -g -Wno-parentheses -Wstrict-prototypes -I../include -I[...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/ + gcc-4.6 tst-array2dep.c -c -std=gnu99 -fgnu89-inline -O2 -Wall -Winline -Wwrite-strings -fmerge-all-constants -frounding-math -g -Wno-parentheses -Wstrict-prototypes -fPIC -I../include -I[...]/tschwinge/Roger_Whittaker.build-gcc + gcc-4.6 -shared -static-libgcc -Wl,-dynamic-linker=/lib/ld.so.1 -Wl,-z,defs -B[...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/csu/ -Wl,-z,combreloc -Wl,-z,relro -Wl,--hash-style=both -L[...]/tschwinge/Roger_Whittaker.build-gcc-4.6 + gcc-4.6 -nostdlib -nostartfiles -o [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/tst-array2 -Wl,-dynamic-linker=/lib/ld.so.1 -Wl,-z,combreloc -Wl,-z,relro -Wl,--hash-style=both [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486 + [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/ld.so.1 --library-path [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486:[...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/math:[...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf:[ + cmp [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/tst-array2.out tst-array2.exp > /dev/null + make[2]: *** [[...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/tst-array2.out] Error 1 + gcc-4.6 tst-array3.c -c -std=gnu99 -fgnu89-inline -O2 -Wall -Winline -Wwrite-strings -fmerge-all-constants -frounding-math -g -Wno-parentheses -Wstrict-prototypes -I../include -I[...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/ + gcc-4.6 -nostdlib -nostartfiles -o [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/tst-array3 -Wl,-dynamic-linker=/lib/ld.so.1 -Wl,-z,combreloc -Wl,-z,relro -Wl,--hash-style=both [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486 + [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/ld.so.1 --library-path [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486:[...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/math:[...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf:[ + cmp [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/tst-array3.out tst-array1.exp > /dev/null + make[2]: *** [[...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/tst-array3.out] Error 1 + gcc-4.6 tst-array4.c -c -std=gnu99 -fgnu89-inline -O2 -Wall -Winline -Wwrite-strings -fmerge-all-constants -frounding-math -g -Wno-parentheses -Wstrict-prototypes -I../include -I[...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/ + gcc-4.6 -nostdlib -nostartfiles -o [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/tst-array4 -Wl,-dynamic-linker=/lib/ld.so.1 -Wl,-z,combreloc -Wl,-z,relro -Wl,--hash-style=both [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486 + [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/ld.so.1 --library-path [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486:[...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/math:[...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf:[ + cmp [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/tst-array4.out tst-array4.exp > /dev/null + make[2]: *** [[...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/tst-array4.out] Error 1 + + `tst-array5` passes. + + gcc-4.6 tst-array1-static.c -c -std=gnu99 -fgnu89-inline -O2 -Wall -Winline -Wwrite-strings -fmerge-all-constants -frounding-math -g -Wno-parentheses -Wstrict-prototypes -I../include -I[...]/tschwinge/Roger_Whittaker.build-gcc-4 + gcc-4.6 -nostdlib -nostartfiles -static -o [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/tst-array1-static [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/csu/crt0.o [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/csu/crti + [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/tst-array1-static > [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/tst-array1-static.out + cmp [...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/tst-array1-static.out tst-array1.exp > /dev/null + make[2]: *** [[...]/tschwinge/Roger_Whittaker.build-gcc-4.6-486/elf/tst-array1-static.out] Error 1 + + `tst-array5-static` passes. + ## OLD diff --git a/open_issues/glibc/t/tls.mdwn b/open_issues/glibc/t/tls.mdwn index 14ef36e4..68db2cc1 100644 --- a/open_issues/glibc/t/tls.mdwn +++ b/open_issues/glibc/t/tls.mdwn @@ -1,4 +1,4 @@ -[[!meta copyright="Copyright © 2011 Free Software Foundation, Inc."]] +[[!meta copyright="Copyright © 2011, 2012 Free Software Foundation, Inc."]] [[!meta license="""[[!toggle id="license" text="GFDL 1.2+"]][[!toggleable id="license" text="Permission is granted to copy, distribute and/or modify this @@ -53,6 +53,10 @@ License|/fdl]]."]]"""]] <tschwinge> And the other offsers are generated via tcb-offsets.sym. <tschwinge> glibc's elf/stackguard-macros.h is wrong for us (but not used anywhere apart from elf/tst-stackguard1.c, I think). + +After commit a9538892adfbb9f092e0bb14ff3a1703973968af, it's +`sysdeps/i386/stackguard-macros.h`; problem remains. + <tschwinge> __thread __locale_t __libc_tsd_LOCALE = &_nl_global_locale; -- this means that a __libc_tsd_LOCALE values will be in the TLS segment, and this is what is being accessed from the assembler code diff --git a/open_issues/glibc_madvise_vs_static_linking.mdwn b/open_issues/glibc_madvise_vs_static_linking.mdwn index 1f766428..ab633b0f 100644 --- a/open_issues/glibc_madvise_vs_static_linking.mdwn +++ b/open_issues/glibc_madvise_vs_static_linking.mdwn @@ -11,7 +11,7 @@ License|/fdl]]."]]"""]] [[!tag open_issue_glibc]] -[[!sourceware_bug 4822]]. +[[!sourceware_PR 4822]]. $ echo 'int main() {}' | gcc -o /dev/null -static -x c - /usr/lib/gcc/i486-gnu/4.4.5/../../../libcrt.a(malloc.o): In function `_int_free': diff --git a/open_issues/glibc_ptrace.mdwn b/open_issues/glibc_ptrace.mdwn index b4c529d7..6704ed80 100644 --- a/open_issues/glibc_ptrace.mdwn +++ b/open_issues/glibc_ptrace.mdwn @@ -1,4 +1,4 @@ -[[!meta copyright="Copyright © 2009 Free Software Foundation, Inc."]] +[[!meta copyright="Copyright © 2009, 2012 Free Software Foundation, Inc."]] [[!meta license="""[[!toggle id="license" text="GFDL 1.2+"]][[!toggleable id="license" text="Permission is granted to copy, distribute and/or modify this @@ -33,8 +33,8 @@ License|/fdl]]."]]"""]] and for us it is a `struct i386_thread_state` from `mach/i386/thread_status.h`; - * Linux probides some functionality that we don't provide, e.g., - `PTRACE_SINGLESTEP`. + * Linux provides some functionality that we don't provide: + `PTRACE_GETFPXREGS` , `PTRACE_SINGLESTEP`. * Some parts are wrongly implemented, e.g., `PTRACE_GETREGS` and `PTRACE_SETREGS` both do the same thing. diff --git a/open_issues/libpthread_1fcd93fd3c733eb19bcad8d03e65f13ec4b0e998..master-viengoos-on-bare-metal.mdwn b/open_issues/libpthread_1fcd93fd3c733eb19bcad8d03e65f13ec4b0e998..master-viengoos-on-bare-metal.mdwn new file mode 100644 index 00000000..4396cf59 --- /dev/null +++ b/open_issues/libpthread_1fcd93fd3c733eb19bcad8d03e65f13ec4b0e998..master-viengoos-on-bare-metal.mdwn @@ -0,0 +1,849 @@ +[[!meta copyright="Copyright © 2012 Free Software Foundation, Inc."]] + +[[!meta license="""[[!toggle id="license" text="GFDL 1.2+"]][[!toggleable +id="license" text="Permission is granted to copy, distribute and/or modify this +document under the terms of the GNU Free Documentation License, Version 1.2 or +any later version published by the Free Software Foundation; with no Invariant +Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license +is included in the section entitled [[GNU Free Documentation +License|/fdl]]."]]"""]] + +[[!tag open_issue_libpthread]] + +Things found in a `git diff +1fcd93fd3c733eb19bcad8d03e65f13ec4b0e998..master-viengoos-on-bare-metal` that +are not specific to L4 or Viengoos, and may be worth having on master, too. + + +# `__pthread_alloc` init with `malloc` or `calloc` + + diff --git a/pthread/pt-alloc.c b/pthread/pt-alloc.c + index 6af2da9..c63801f 100644 + --- a/pthread/pt-alloc.c + +++ b/pthread/pt-alloc.c + @@ -123,7 +123,7 @@ __pthread_alloc (struct __pthread **pthread) + } + + /* Allocate a new thread structure. */ + - new = malloc (sizeof (struct __pthread)); + + new = calloc (sizeof (struct __pthread), 1); + if (new == NULL) + return ENOMEM; + + + +# `atomic.h` + +Later on master, commit 608a12659f15d57abf42a972c1e56c6a24cfe244: `Rename +bits/atomic.h to bits/pt-atomic.h`. + + diff --git a/pthread/pt-create.c b/pthread/pt-create.c + index 8f62b78..504cacc 100644 + --- a/pthread/pt-create.c + +++ b/pthread/pt-create.c + @@ -22,7 +22,7 @@ + #include <pthread.h> + #include <signal.h> + + -#include <bits/atomic.h> + +#include <atomic.h> + + #include <pt-internal.h> + + @@ -33,7 +33,7 @@ + /* The total number of pthreads currently active. This is defined + here since it would be really stupid to have a threads-using + program that doesn't call `pthread_create'. */ + -__atomic_t __pthread_total; + +atomic_fast32_t __pthread_total; + + + /* The entry-point for new threads. */ + @@ -163,7 +163,7 @@ __pthread_create_internal (struct __pthread **thread, + the number of threads from within the new thread isn't an option + since this thread might return and call `pthread_exit' before the + new thread runs. */ + - __atomic_inc (&__pthread_total); + + atomic_increment (&__pthread_total); + + /* Store a pointer to this thread in the thread ID lookup table. We + could use __thread_setid, however, we only lock for reading as no + @@ -190,7 +190,7 @@ __pthread_create_internal (struct __pthread **thread, + + failed_starting: + __pthread_setid (pthread->thread, NULL); + - __atomic_dec (&__pthread_total); + + atomic_decrement (&__pthread_total); + failed_sigstate: + __pthread_sigstate_destroy (pthread); + failed_setup: + diff --git a/pthread/pt-exit.c b/pthread/pt-exit.c + index 5fe0ba8..68c56d7 100644 + --- a/pthread/pt-exit.c + +++ b/pthread/pt-exit.c + @@ -24,7 +24,7 @@ + + #include <pt-internal.h> + + -#include <bits/atomic.h> + +#include <atomic.h> + + + /* Terminate the current thread and make STATUS available to any + @@ -57,7 +57,7 @@ pthread_exit (void *status) + + /* Decrease the number of threads. We use an atomic operation to + make sure that only the last thread calls `exit'. */ + - if (__atomic_dec_and_test (&__pthread_total)) + + if (atomic_decrement_and_test (&__pthread_total)) + /* We are the last thread. */ + exit (0); + + diff --git a/pthread/pt-internal.h b/pthread/pt-internal.h + index cb441d0..986ec6b 100644 + --- a/pthread/pt-internal.h + +++ b/pthread/pt-internal.h + @@ -26,13 +26,15 @@ + #include <signal.h> + #include <assert.h> + + -#include <bits/atomic.h> + +#include <atomic.h> + [...] + @@ -136,7 +144,7 @@ __pthread_dequeue (struct __pthread *thread) + ) + + /* The total number of threads currently active. */ + -extern __atomic_t __pthread_total; + +extern atomic_fast32_t __pthread_total; + + /* The total number of thread IDs currently in use, or on the list of + available thread IDs. */ + diff --git a/sysdeps/ia32/bits/atomic.h b/sysdeps/ia32/bits/atomic.h + deleted file mode 100644 + index 0dfc1f6..0000000 + --- a/sysdeps/ia32/bits/atomic.h + +++ /dev/null + @@ -1,66 +0,0 @@ + -/* Atomic operations. i386 version. + - Copyright (C) 2000 Free Software Foundation, Inc. + - This file is part of the GNU C Library. + - + - The GNU C Library is free software; you can redistribute it and/or + - modify it under the terms of the GNU Library General Public License as + - published by the Free Software Foundation; either version 2 of the + - License, or (at your option) any later version. + - + - The GNU C Library is distributed in the hope that it will be useful, + - but WITHOUT ANY WARRANTY; without even the implied warranty of + - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + - Library General Public License for more details. + - + - You should have received a copy of the GNU Library General Public + - License along with the GNU C Library; see the file COPYING.LIB. If not, + - write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + - Boston, MA 02111-1307, USA. */ + - + -#ifndef _BITS_ATOMIC_H + -#define _BITS_ATOMIC_H 1 + - + -typedef __volatile int __atomic_t; + - + -static inline void + -__atomic_inc (__atomic_t *__var) + -{ + - __asm__ __volatile ("lock; incl %0" : "=m" (*__var) : "m" (*__var)); + -} + - + -static inline void + -__atomic_dec (__atomic_t *__var) + -{ + - __asm__ __volatile ("lock; decl %0" : "=m" (*__var) : "m" (*__var)); + -} + - + -static inline int + -__atomic_dec_and_test (__atomic_t *__var) + -{ + - unsigned char __ret; + - + - __asm__ __volatile ("lock; decl %0; sete %1" + - : "=m" (*__var), "=qm" (__ret) : "m" (*__var)); + - return __ret != 0; + -} + - + -/* We assume that an __atomicptr_t is only used for pointers to + - word-aligned objects, and use the lowest bit for a simple lock. */ + -typedef __volatile int * __atomicptr_t; + - + -/* Actually we don't implement that yet, and assume that we run on + - something that has the i486 instruction set. */ + -static inline int + -__atomicptr_compare_and_swap (__atomicptr_t *__ptr, void *__oldval, + - void * __newval) + -{ + - char __ret; + - int __dummy; + - + - __asm__ __volatile ("lock; cmpxchgl %3, %1; sete %0" + - : "=q" (__ret), "=m" (*__ptr), "=a" (__dummy) + - : "r" (__newval), "m" (*__ptr), "a" (__oldval)); + - return __ret; + -} + - + -#endif + + +# Memory Barries + + diff --git a/sysdeps/generic/bits/memory.h b/sysdeps/generic/bits/memory.h + new file mode 100644 + index 0000000..7b88a7e + --- /dev/null + +++ b/sysdeps/generic/bits/memory.h + @@ -0,0 +1,36 @@ + +/* Memory barrier operations. Generic version. + + Copyright (C) 2008 Free Software Foundation, Inc. + + This file is part of the GNU Hurd. + + + + The GNU Hurd is free software; you can redistribute it and/or + + modify it under the terms of the GNU General Public License as + + published by the Free Software Foundation; either version 3 of the + + License, or (at your option) any later version. + + + + The GNU Hurd is distributed in the hope that it will be useful, but + + WITHOUT ANY WARRANTY; without even the implied warranty of + + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + + General Public License for more details. + + + + You should have received a copy of the GNU General Public License + + along with this program. If not, see + + <http://www.gnu.org/licenses/>. */ + + + +#ifndef _BITS_MEMORY_H + +#define _BITS_MEMORY_H 1 + + + +/* Prevent read and write reordering across this function. */ + +static inline void + +__memory_barrier (void) + +{ + + /* Any lock'ed instruction will do. */ + + __sync_synchronize (); + +} + + + +/* Prevent read reordering across this function. */ + +#define __memory_read_barrier __memory_barrier + + + +/* Prevent write reordering across this function. */ + +#define __memory_write_barrier __memory_barrier + + + +#endif + + +# Spin Locks + + diff --git a/sysdeps/generic/bits/spin-lock-inline.h b/sysdeps/generic/bits/spin-lock-inline.h + new file mode 100644 + index 0000000..6c3e06e + --- /dev/null + +++ b/sysdeps/generic/bits/spin-lock-inline.h + @@ -0,0 +1,99 @@ + +/* Machine-specific definitions for spin locks. Generic version. + + Copyright (C) 2000, 2005, 2008 Free Software Foundation, Inc. + + This file is part of the GNU C Library. + + + + The GNU C Library is free software; you can redistribute it and/or + + modify it under the terms of the GNU Library General Public License as + + published by the Free Software Foundation; either version 2 of the + + License, or (at your option) any later version. + + + + The GNU C Library is distributed in the hope that it will be useful, + + but WITHOUT ANY WARRANTY; without even the implied warranty of + + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + + Library General Public License for more details. + + + + You should have received a copy of the GNU Library General Public + + License along with the GNU C Library; see the file COPYING.LIB. If not, + + write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + + Boston, MA 02111-1307, USA. */ + + + +/* + + * Never include this file directly; use <pthread.h> or <cthreads.h> instead. + + */ + + + +#ifndef _BITS_SPIN_LOCK_INLINE_H + +#define _BITS_SPIN_LOCK_INLINE_H 1 + + + +#include <features.h> + +#include <bits/spin-lock.h> + + + +__BEGIN_DECLS + + + +#if defined __USE_EXTERN_INLINES || defined _FORCE_INLINES + + + +# if !defined (__EBUSY) || !defined (__EINVAL) + +# include <errno.h> + +# ifndef __EBUSY + +# define __EBUSY EBUSY + +# endif + +# ifndef __EINVAL + +# define __EINVAL EINVAL + +# endif + +# endif + + + +# ifndef __PT_SPIN_INLINE + +# define __PT_SPIN_INLINE __extern_inline + +# endif + + + +__PT_SPIN_INLINE int __pthread_spin_destroy (__pthread_spinlock_t *__lock); + + + +__PT_SPIN_INLINE int + +__pthread_spin_destroy (__pthread_spinlock_t *__lock) + +{ + + return 0; + +} + + + +__PT_SPIN_INLINE int __pthread_spin_init (__pthread_spinlock_t *__lock, + + int __pshared); + + + +__PT_SPIN_INLINE int + +__pthread_spin_init (__pthread_spinlock_t *__lock, int __pshared) + +{ + + *__lock = __SPIN_LOCK_INITIALIZER; + + return 0; + +} + + + +__PT_SPIN_INLINE int __pthread_spin_trylock (__pthread_spinlock_t *__lock); + + + +__PT_SPIN_INLINE int + +__pthread_spin_trylock (__pthread_spinlock_t *__lock) + +{ + + int __locked = __sync_val_compare_and_swap (__lock, 0, 1); + + return __locked ? __EBUSY : 0; + +} + + + +__extern_inline int __pthread_spin_lock (__pthread_spinlock_t *__lock); + +extern int _pthread_spin_lock (__pthread_spinlock_t *__lock); + + + +__extern_inline int + +__pthread_spin_lock (__pthread_spinlock_t *__lock) + +{ + + if (__pthread_spin_trylock (__lock)) + + return _pthread_spin_lock (__lock); + + return 0; + +} + + + +__PT_SPIN_INLINE int __pthread_spin_unlock (__pthread_spinlock_t *__lock); + + + +__PT_SPIN_INLINE int + +__pthread_spin_unlock (__pthread_spinlock_t *__lock) + +{ + + int __locked = __sync_val_compare_and_swap (__lock, 1, 0); + + return __locked ? 0 : __EINVAL; + +} + + + +#endif /* Use extern inlines or force inlines. */ + + + +__END_DECLS + + + +#endif /* bits/spin-lock.h */ + diff --git a/sysdeps/l4/bits/pthread-np.h b/sysdeps/generic/bits/spin-lock.h + similarity index 67% + rename from sysdeps/l4/bits/pthread-np.h + rename to sysdeps/generic/bits/spin-lock.h + index 6a02bdc..c2ba332 100644 + --- a/sysdeps/l4/bits/pthread-np.h + +++ b/sysdeps/generic/bits/spin-lock.h + @@ -1,5 +1,5 @@ + -/* Non-portable functions. L4 version. + - Copyright (C) 2003, 2007 Free Software Foundation, Inc. + +/* Machine-specific definitions for spin locks. Generic version. + + Copyright (C) 2000, 2005, 2008 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or + @@ -21,15 +21,19 @@ + * Never include this file directly; use <pthread.h> or <cthreads.h> instead. + */ + + -#ifndef _BITS_PTHREAD_NP_H + -#define _BITS_PTHREAD_NP_H 1 + +#ifndef _BITS_SPIN_LOCK_H + +#define _BITS_SPIN_LOCK_H 1 + + -#include <l4.h> + +#include <features.h> + + -/* Add the thread TID to the internal kernel thread pool. */ + -extern int pthread_pool_add_np (l4_thread_id_t tid); + +__BEGIN_DECLS + + -/* Get the first thread from the pool. */ + -extern l4_thread_id_t pthread_pool_get_np (void); + +/* The type of a spin lock object. */ + +typedef __volatile int __pthread_spinlock_t; + + -#endif /* bits/pthread-np.h */ + +/* Initializer for a spin lock object. */ + +# define __SPIN_LOCK_INITIALIZER ((__pthread_spinlock_t) 0) + + + +__END_DECLS + + + +#endif /* bits/spin-lock.h */ + + +# Signal Stuff + + diff --git a/pthread/pt-internal.h b/pthread/pt-internal.h + index cb441d0..986ec6b 100644 + --- a/pthread/pt-internal.h + +++ b/pthread/pt-internal.h + @@ -26,13 +26,15 @@ + [...] + #include <pt-sysdep.h> + #include <pt-machdep.h> + + +#include <sig-internal.h> + + + /* Thread state. */ + enum pthread_state + { + @@ -54,6 +56,10 @@ enum pthread_state + # define PTHREAD_SYSDEP_MEMBERS + #endif + + +#ifndef PTHREAD_SIGNAL_MEMBERS + +# define PTHREAD_SIGNAL_MEMBERS + +#endif + + + /* This structure describes a POSIX thread. */ + struct __pthread + { + @@ -89,6 +95,8 @@ struct __pthread + + PTHREAD_SYSDEP_MEMBERS + + + PTHREAD_SIGNAL_MEMBERS + + + struct __pthread *next, **prevp; + }; + + diff --git a/signal/kill.c b/signal/kill.c + index 27c9c32..c281640 100644 + --- a/signal/kill.c + +++ b/signal/kill.c + @@ -20,6 +20,8 @@ + + #include "sig-internal.h" + + +#include <string.h> + + + int + kill (pid_t pid, int signo) + { + @@ -65,6 +67,12 @@ kill (pid_t pid, int signo) + current thread has blocked the signal, the correct thing to do is + to iterate over all the other threads and find on that hasn't + blocked it. */ + + + + extern int __pthread_num_threads; + + if (__pthread_num_threads == 0) + + panic ("signal %d received before pthread library is able to handle it", + + signo); + + + return pthread_kill (pthread_self (), signo); + } + + diff --git a/signal/pt-kill-siginfo-np.c b/signal/pt-kill-siginfo-np.c + index 9bdf6cc..35642c3 100644 + --- a/signal/pt-kill-siginfo-np.c + +++ b/signal/pt-kill-siginfo-np.c + @@ -75,7 +75,8 @@ pthread_kill_siginfo_np (pthread_t tid, siginfo_t si) + || (ss->stack.ss_flags & SS_DISABLE) + || (ss->stack.ss_flags & SS_ONSTACK))) + /* We are sending a signal to ourself and we don't use an + - alternate stack. */ + + alternate stack. (Recall: SA_ONSTACK means use the alt + + stack.) */ + signal_dispatch (ss, &si); + else + signal_dispatch_lowlevel (ss, tid, si); + diff --git a/signal/signal-dispatch.c b/signal/signal-dispatch.c + index 40440b7..6fafcc1 100644 + --- a/signal/signal-dispatch.c + +++ b/signal/signal-dispatch.c + @@ -20,6 +20,8 @@ + + #include "sig-internal.h" + + +#include <viengoos/math.h> + + + /* This is the signal handler entry point. A thread is forced into + this state when it receives a signal. We need to save the thread's + state and then invoke the high-level signal dispatcher. SS->LOCK + @@ -107,7 +109,7 @@ signal_dispatch (struct signal_state *ss, siginfo_t *si) + sigset_t pending = ~ss->blocked & ss->pending; + if (! pending) + pending = ~ss->blocked & process_pending; + - signo = l4_lsb64 (pending); + + signo = vg_lsb64 (pending); + } + while (signo); + + diff --git a/signal/sigwaiter.c b/signal/sigwaiter.c + index 8d041ac..adc05ca 100644 + --- a/signal/sigwaiter.c + +++ b/signal/sigwaiter.c + @@ -20,7 +20,7 @@ + + #include "sig-internal.h" + + -#include <hurd/futex.h> + +#include <viengoos/futex.h> + + struct sigwaiter *sigwaiters; + + diff --git a/signal/sigwaitinfo.c b/signal/sigwaitinfo.c + index 1b47079..dea3ef4 100644 + --- a/signal/sigwaitinfo.c + +++ b/signal/sigwaitinfo.c + @@ -43,7 +43,7 @@ sigwaitinfo (const sigset_t *restrict set, siginfo_t *restrict info) + + assert (extant); + + - int signo = l4_msb64 (extant); + + int signo = vg_msb64 (extant); + + if (info) + { + + +# `ALWAYS_TRACK_MUTEX_OWNER` + + diff --git a/sysdeps/generic/pt-mutex-timedlock.c b/sysdeps/generic/pt-mutex-timedlock.c + index ee43219..265a453 100644 + --- a/sysdeps/generic/pt-mutex-timedlock.c + +++ b/sysdeps/generic/pt-mutex-timedlock.c + @@ -36,7 +36,6 @@ __pthread_mutex_timedlock_internal (struct __pthread_mutex *mutex, + if (__pthread_spin_trylock (&mutex->__held) == 0) + /* Successfully acquired the lock. */ + { + -#ifdef ALWAYS_TRACK_MUTEX_OWNER + #ifndef NDEBUG + self = _pthread_self (); + if (self) + @@ -48,7 +47,6 @@ __pthread_mutex_timedlock_internal (struct __pthread_mutex *mutex, + mutex->owner = _pthread_self (); + } + #endif + -#endif + + if (mutex->attr) + switch (mutex->attr->mutex_type) + @@ -75,16 +73,14 @@ __pthread_mutex_timedlock_internal (struct __pthread_mutex *mutex, + self = _pthread_self (); + assert (self); + + - if (! mutex->attr || mutex->attr->mutex_type == PTHREAD_MUTEX_NORMAL) + - { + -#if defined(ALWAYS_TRACK_MUTEX_OWNER) + - assert (mutex->owner != self); + -#endif + - } + - else + + if (mutex->attr) + { + switch (mutex->attr->mutex_type) + { + + case PTHREAD_MUTEX_NORMAL: + + assert (mutex->owner != self); + + break; + + + case PTHREAD_MUTEX_ERRORCHECK: + if (mutex->owner == self) + { + @@ -106,10 +102,9 @@ __pthread_mutex_timedlock_internal (struct __pthread_mutex *mutex, + LOSE; + } + } + + else + + assert (mutex->owner != self); + + -#if !defined(ALWAYS_TRACK_MUTEX_OWNER) + - if (mutex->attr && mutex->attr->mutex_type != PTHREAD_MUTEX_NORMAL) + -#endif + assert (mutex->owner); + + if (abstime && (abstime->tv_nsec < 0 || abstime->tv_nsec >= 1000000000)) + @@ -146,12 +141,9 @@ __pthread_mutex_timedlock_internal (struct __pthread_mutex *mutex, + else + __pthread_block (self); + + -#if !defined(ALWAYS_TRACK_MUTEX_OWNER) + - if (mutex->attr && mutex->attr->mutex_type != PTHREAD_MUTEX_NORMAL) + -#endif + - { + +#ifndef NDEBUG + assert (mutex->owner == self); + - } + +#endif + + if (mutex->attr) + switch (mutex->attr->mutex_type) + diff --git a/sysdeps/generic/pt-mutex-transfer-np.c b/sysdeps/generic/pt-mutex-transfer-np.c + index 7796ac4..bcb809d 100644 + --- a/sysdeps/generic/pt-mutex-transfer-np.c + +++ b/sysdeps/generic/pt-mutex-transfer-np.c + @@ -45,12 +45,7 @@ __pthread_mutex_transfer_np (struct __pthread_mutex *mutex, pthread_t tid) + } + + #ifndef NDEBUG + -# if !defined(ALWAYS_TRACK_MUTEX_OWNER) + - if (mutex->attr && mutex->attr->mutex_type != PTHREAD_MUTEX_NORMAL) + -# endif + - { + mutex->owner = thread; + - } + #endif + + return 0; + diff --git a/sysdeps/generic/pt-mutex-unlock.c b/sysdeps/generic/pt-mutex-unlock.c + index 7645fd4..f299750 100644 + --- a/sysdeps/generic/pt-mutex-unlock.c + +++ b/sysdeps/generic/pt-mutex-unlock.c + @@ -33,16 +33,19 @@ __pthread_mutex_unlock (pthread_mutex_t *mutex) + + if (! mutex->attr || mutex->attr->mutex_type == PTHREAD_MUTEX_NORMAL) + { + -#if defined(ALWAYS_TRACK_MUTEX_OWNER) + # ifndef NDEBUG + if (_pthread_self ()) + { + assert (mutex->owner); + - assert (mutex->owner == _pthread_self ()); + + assertx (mutex->owner == _pthread_self (), + + "%p("VG_THREAD_ID_FMT") != %p("VG_THREAD_ID_FMT")", + + mutex->owner, + + ((struct __pthread *) mutex->owner)->threadid, + + _pthread_self (), + + _pthread_self ()->threadid); + mutex->owner = NULL; + } + # endif + -#endif + } + else + switch (mutex->attr->mutex_type) + @@ -81,12 +84,7 @@ __pthread_mutex_unlock (pthread_mutex_t *mutex) + __pthread_dequeue (wakeup); + + #ifndef NDEBUG + -# if !defined (ALWAYS_TRACK_MUTEX_OWNER) + - if (mutex->attr && mutex->attr->mutex_type != PTHREAD_MUTEX_NORMAL) + -# endif + - { + mutex->owner = wakeup; + - } + #endif + + /* We do not unlock MUTEX->held: we are transferring the ownership + + +# `t/fix_have_kernel_resources` + +See topic branch of that name. + + diff --git a/sysdeps/mach/hurd/pt-sysdep.h b/sysdeps/mach/hurd/pt-sysdep.h + index f14a136..83bad96 100644 + --- a/sysdeps/mach/hurd/pt-sysdep.h + +++ b/sysdeps/mach/hurd/pt-sysdep.h + @@ -1,5 +1,5 @@ + /* Internal defenitions for pthreads library. + - Copyright (C) 2000, 2002, 2008 Free Software Foundation, Inc. + + Copyright (C) 2000, 2002 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or + @@ -32,8 +32,7 @@ + + #define PTHREAD_SYSDEP_MEMBERS \ + thread_t kernel_thread; \ + - mach_msg_header_t wakeupmsg; \ + - int have_kernel_resources; + + mach_msg_header_t wakeupmsg; + + #define _HURD_THREADVAR_THREAD _HURD_THREADVAR_DYNAMIC_USER + + diff --git a/sysdeps/mach/pt-thread-alloc.c b/sysdeps/mach/pt-thread-alloc.c + index 3d7c046..1acba98 100644 + --- a/sysdeps/mach/pt-thread-alloc.c + +++ b/sysdeps/mach/pt-thread-alloc.c + @@ -1,5 +1,5 @@ + /* Start thread. Mach version. + - Copyright (C) 2000, 2002, 2005, 2008 Free Software Foundation, Inc. + + Copyright (C) 2000, 2002, 2005 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or + @@ -63,9 +63,6 @@ create_wakeupmsg (struct __pthread *thread) + int + __pthread_thread_alloc (struct __pthread *thread) + { + - if (thread->have_kernel_resources) + - return 0; + - + error_t err; + + err = create_wakeupmsg (thread); + @@ -100,7 +97,5 @@ __pthread_thread_alloc (struct __pthread *thread) + return EAGAIN; + } + + - thread->have_kernel_resources = 1; + - + return 0; + } + + +# Miscellaneous + + diff --git a/Makefile b/Makefile + index 04dfb26..a4c0c52 100644 + --- a/Makefile + +++ b/Makefile + @@ -71,7 +71,6 @@ SRCS := pt-attr.c pt-attr-destroy.c pt-attr-getdetachstate.c \ + pt-mutex-init.c pt-mutex-destroy.c \ + pt-mutex-lock.c pt-mutex-trylock.c pt-mutex-timedlock.c \ + pt-mutex-unlock.c \ + - pt-mutex-transfer-np.c \ + pt-mutex-getprioceiling.c pt-mutex-setprioceiling.c \ + \ + pt-rwlock-attr.c \ + @@ -100,7 +99,6 @@ SRCS := pt-attr.c pt-attr-destroy.c pt-attr-getdetachstate.c \ + pt-thread-dealloc.c \ + pt-thread-start.c \ + pt-thread-halt.c \ + - pt-startup.c \ + \ + pt-getconcurrency.c pt-setconcurrency.c \ + \ + @@ -143,7 +141,6 @@ sysdeps_headers = \ + semaphore.h \ + \ + bits/pthread.h \ + - bits/pthread-np.h \ + bits/mutex.h \ + bits/condition.h \ + bits/condition-attr.h \ + diff --git a/Makefile.am b/Makefile.am + index e59c946..e73d8d6 100644 + --- a/Makefile.am + +++ b/Makefile.am + @@ -20,17 +20,18 @@ + if ARCH_IA32 + arch=ia32 + endif + +if ARCH_X86_64 + + arch=x86_64 + +endif + if ARCH_POWERPC + arch=powerpc + endif + + # The source files are scattered over several directories. Add + # all these directories to the vpath. + -SYSDEP_PATH = $(srcdir)/sysdeps/l4/hurd/${arch} \ + - $(srcdir)/sysdeps/l4/${arch} \ + +SYSDEP_PATH = $(srcdir)/sysdeps/viengoos/${arch} \ + $(srcdir)/sysdeps/${arch} \ + - $(srcdir)/sysdeps/l4/hurd \ + - $(srcdir)/sysdeps/l4 \ + + $(srcdir)/sysdeps/viengoos \ + $(srcdir)/sysdeps/hurd \ + $(srcdir)/sysdeps/generic \ + $(srcdir)/sysdeps/posix \ + @@ -68,7 +69,6 @@ libpthread_a_SOURCES = pt-attr.c pt-attr-destroy.c pt-attr-getdetachstate.c \ + pt-alloc.c \ + pt-create.c \ + pt-getattr.c \ + - pt-pool-np.c \ + pt-equal.c \ + pt-dealloc.c \ + pt-detach.c \ + diff --git a/headers.m4 b/headers.m4 + index 5a58b9b..7c73cf2 100644 + --- a/headers.m4 + +++ b/headers.m4 + @@ -14,10 +14,9 @@ AC_CONFIG_LINKS([ + sysroot/include/pthread.h:libpthread/include/pthread.h + sysroot/include/pthread/pthread.h:libpthread/include/pthread/pthread.h + sysroot/include/pthread/pthreadtypes.h:libpthread/include/pthread/pthreadtypes.h + - sysroot/include/bits/memory.h:libpthread/sysdeps/${arch}/bits/memory.h + - sysroot/include/bits/spin-lock.h:libpthread/sysdeps/${arch}/bits/spin-lock.h + - sysroot/include/bits/spin-lock-inline.h:libpthread/sysdeps/${arch}/bits/spin-lock-inline.h + - sysroot/include/bits/pthreadtypes.h:libpthread/sysdeps/generic/bits/pthreadtypes.h + + sysroot/include/bits/memory.h:libpthread/sysdeps/generic/bits/memory.h + + sysroot/include/bits/spin-lock.h:libpthread/sysdeps/generic/bits/spin-lock.h + + sysroot/include/bits/spin-lock-inline.h:libpthread/sysdeps/generic/bits/spin-lock-inline.h + sysroot/include/bits/barrier-attr.h:libpthread/sysdeps/generic/bits/barrier-attr.h + sysroot/include/bits/barrier.h:libpthread/sysdeps/generic/bits/barrier.h + sysroot/include/bits/cancelation.h:libpthread/sysdeps/generic/bits/cancelation.h + @@ -30,9 +29,8 @@ AC_CONFIG_LINKS([ + sysroot/include/bits/rwlock-attr.h:libpthread/sysdeps/generic/bits/rwlock-attr.h + sysroot/include/bits/rwlock.h:libpthread/sysdeps/generic/bits/rwlock.h + sysroot/include/bits/thread-attr.h:libpthread/sysdeps/generic/bits/thread-attr.h + - sysroot/include/bits/thread-barrier.h:libpthread/sysdeps/generic/bits/thread-barrier.h + sysroot/include/bits/thread-specific.h:libpthread/sysdeps/generic/bits/thread-specific.h + - sysroot/include/bits/pthread-np.h:libpthread/sysdeps/l4/hurd/bits/pthread-np.h + + sysroot/include/bits/pthread-np.h:libpthread/sysdeps/viengoos/bits/pthread-np.h + sysroot/include/semaphore.h:libpthread/include/semaphore.h + sysroot/include/bits/semaphore.h:libpthread/sysdeps/generic/bits/semaphore.h + sysroot/include/signal.h:libpthread/signal/signal.h + @@ -41,5 +39,5 @@ AC_CONFIG_LINKS([ + AC_CONFIG_COMMANDS_POST([ + mkdir -p sysroot/lib libpthread && + ln -sf ../../libpthread/libpthread.a sysroot/lib/ && + - touch libpthread/libpthread.a + + echo '/* This file intentionally left blank. */' >libpthread/libpthread.a + ]) + diff --git a/sysdeps/hurd/pt-setspecific.c b/sysdeps/hurd/pt-setspecific.c + index 89ca4d7..d2d1157 100644 + --- a/sysdeps/hurd/pt-setspecific.c + +++ b/sysdeps/hurd/pt-setspecific.c + @@ -1,5 +1,5 @@ + /* pthread_setspecific. Generic version. + - Copyright (C) 2002 Free Software Foundation, Inc. + + Copyright (C) 2002, 2008 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or + @@ -30,7 +30,8 @@ pthread_setspecific (pthread_key_t key, const void *value) + + if (! self->thread_specifics) + { + - err = hurd_ihash_create (&self->thread_specifics, HURD_IHASH_NO_LOCP); + + err = hurd_ihash_create (&self->thread_specifics, false, + + HURD_IHASH_NO_LOCP); + if (err) + return ENOMEM; + } + diff --git a/sysdeps/mach/pt-thread-halt.c b/sysdeps/mach/pt-thread-halt.c + index 973cde1..9f86024 100644 + --- a/sysdeps/mach/pt-thread-halt.c + +++ b/sysdeps/mach/pt-thread-halt.c + @@ -30,8 +30,14 @@ + being halted, thus the last action should be halting the thread + itself. */ + void + -__pthread_thread_halt (struct __pthread *thread) + +__pthread_thread_halt (struct __pthread *thread, int need_dealloc) + { + - error_t err = __thread_terminate (thread->kernel_thread); + + error_t err; + + thread_t tid = thread->kernel_thread; + + + + if (need_dealloc) + + __pthread_dealloc (thread); + + + + err = __thread_terminate (tid); + assert_perror (err); + } diff --git a/open_issues/libpthread_CLOCK_MONOTONIC.mdwn b/open_issues/libpthread_CLOCK_MONOTONIC.mdwn index 22b2cd3b..5a99778b 100644 --- a/open_issues/libpthread_CLOCK_MONOTONIC.mdwn +++ b/open_issues/libpthread_CLOCK_MONOTONIC.mdwn @@ -111,3 +111,7 @@ License|/fdl]]."]]"""]] our "libpthread needs lirt which pulls libphtread" circular issue by moving the clock_* functions to libc proper <youpi> I've seen that yes :) + +[[!sourceware_PR 14304]], [[!sourceware_PR 14743]], [[!message-id +"CAH6eHdQRyTgkXE7k+UVpaObNTOZf7QF_fNoU-bqbMhfzXxXUDg@mail.gmail.com"]], commit +6e6249d0b461b952d0f544792372663feb6d792a (2012-10-24). diff --git a/open_issues/libpthread_glibc_nptl_testsuite.mdwn b/open_issues/libpthread_glibc_nptl_testsuite.mdwn new file mode 100644 index 00000000..687f8eea --- /dev/null +++ b/open_issues/libpthread_glibc_nptl_testsuite.mdwn @@ -0,0 +1,28 @@ +[[!meta copyright="Copyright © 2012 Free Software Foundation, Inc."]] + +[[!meta license="""[[!toggle id="license" text="GFDL 1.2+"]][[!toggleable +id="license" text="Permission is granted to copy, distribute and/or modify this +document under the terms of the GNU Free Documentation License, Version 1.2 or +any later version published by the Free Software Foundation; with no Invariant +Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license +is included in the section entitled [[GNU Free Documentation +License|/fdl]]."]]"""]] + +[[!tag open_issue_glibc open_issue_libpthread]] + +For fun and profit we should run [[glibc]]'s [[NPTL]] testsuite against +[[libpthread]]. + +Also, there are sometimes issues fixed in NPTL that libpthread should also be +checked against. Totally incomplete list: + + * Return `EAGAIN` instead of `ENOMEM`, glibc + 5bdcc10322c488f53557440acf71623d8b313ab5. + * `pthread_cancel` when single-threaded, glibc + 439bf404b8fa125cf950dc1aa37838702c5353ea, [[!sourceware_PR 13613]], + [[!message-id "20120509202437.268a72b9@spoyarek"]]. + * `__libc_stack_end`, glibc 9c6ea9facbba4d430807bd21fa82892d713b1ecd, + 18b5e737de22462ab6b3fc89f26c9ad480ebb843, [[!sourceware_PR 12416]], + [[!message-id "20120419120021.4780e8c8@spoyarek"]], [[!message-id + "20120615005913.4f517e02@spoyarek"]], [[!message-id + "4FE378DE.8050906@mentor.com"]]. diff --git a/open_issues/packaging_libpthread.mdwn b/open_issues/packaging_libpthread.mdwn index 2d90779e..18f124b4 100644 --- a/open_issues/packaging_libpthread.mdwn +++ b/open_issues/packaging_libpthread.mdwn @@ -93,7 +93,6 @@ License|/fdl]]."]]"""]] by anybody? <youpi> they are half-finished (no __PTHREAD_SPIN_LOCK_INITIALIZER), and come in the way when building in glibc - <youpi> also, any reason for using ia32 and not i386? glibc uses the latter <youpi> pinotree: rid of pthread-stubs yes <pinotree> \o/ <tschwinge> youpi: You mean sysdeps/mach/i386/machine-lock.h? No idea @@ -101,7 +100,7 @@ License|/fdl]]."]]"""]] <youpi> I'm talking about libpthread <youpi> not glibc <tschwinge> Oh. - <tschwinge> sysdeps/ia32/bits/spin-lock.h:# define + <tschwinge> sysdeps/i386/bits/spin-lock.h:# define __PTHREAD_SPIN_LOCK_INITIALIZER ((__pthread_spinlock_t) 0) <tschwinge> Anyway, no idea about that either. <youpi> that one is meant to be used with the spin-lock.h just below @@ -128,33 +127,6 @@ License|/fdl]]."]]"""]] no-add-needed issue -## IRC, freenode, #hurd, 2012-04-27 - - <pinotree> youpi: wouldn't be the case to rename ia32 subdirs to i386 in - libpthread? - <pinotree> after all, Makefile hardcodes it, Makefile.am sets the variable - for it, and glibc expects i386 - <youpi> I know, I've asked tschwinge about it - <youpi> it's not urging anyway - <pinotree> right - - -## IRC, freenode, #hurd, 2012-07-21 - - <pinotree> tschwinge: btw, samuel suggested to rename in libpthread ia32 → - i386, to better fit with glibc - <tschwinge> pinotree: Hmm, that'd somewhat break interopability with - Viengoos' use of libpthread. - <pinotree> how would it break with viengoos? - <tschwinge> I assume it is using the i386 names. Hmm, no isn't it x86_64 - only? - <tschwinge> I'll check. - <pinotree> does it use automake (with the Makefile.am in repo)? - <tschwinge> I have no idea what the current branch arrangement is. - <pinotree> tschwinge: it looks like ia32 is hardcoded in Makefile and - Makefile.am - - ## IRC, freenode, #hurd, 2012-08-07 <tschwinge> Also, the Savannah hurd/glibc.git one does not/not yet include @@ -168,15 +140,11 @@ License|/fdl]]."]]"""]] <tschwinge> The libpthread in Debian glibc is hurd/libpthread.git:b428baaa85c0adca9ef4884c637f289a0ab5e2d6 but with 25260994c812050a5d7addf125cdc90c911ca5c1 »Store self in __thread variable - instead of threadvar« reverted (why?), and the following additional - change applied to Makefile: - <tschwinge> ifeq ($(IN_GLIBC),yes) - <tschwinge> $(inst_libdir)/libpthread.so: - $(objpfx)libpthread.so$(libpthread.so-version) \ - <tschwinge> $(+force) - <tschwinge> - ln -sf $(slibdir)/libpthread.so$(libpthread.so-version) - $@ - <tschwinge> + ln -sf libpthread.so$(libpthread.so-version) $@ + instead of threadvar« reverted (why?), [...] + +..., and 549aba4335946c26f2701c2b43be0e6148d27c09 »Fix libpthread.so symlink« +cherry-picked. + <braunr> tschwinge: is there any plan to merge libpthread.git in glibc.git upstream ? <tschwinge> braunr, youpi: Has not yet been discussed with Roland, as far @@ -185,8 +153,6 @@ License|/fdl]]."]]"""]] <youpi> libpthread.diff is supposed to be a verbatim copy of the repository <youpi> and then there are a couple patches which don't (yet) make sense upstream - <youpi> the slibdir change, however, is odd - <youpi> it must be a leftover # IRC, freenode, #hurd, 2012-11-16 diff --git a/open_issues/term_blocking.mdwn b/open_issues/term_blocking.mdwn index 39803779..0ed0b4df 100644 --- a/open_issues/term_blocking.mdwn +++ b/open_issues/term_blocking.mdwn @@ -114,9 +114,76 @@ user started GDB test suite, noticed the PTY it's using; in a root shell started GDB (the system one, for `.debug` stuff) on `/hurd/term`, `set noninvasive on`, attach to the *term* that GDB is using. +--- [[2011-07-04]]. +--- + +2012-11-05 + +Log file from a 2011-09-07 run: + + [...] + Running ../../../master/gdb/testsuite/gdb.base/readline.exp ... + spawn [...]/gdb/testsuite/../../gdb/gdb -nw -nx -data-directory [...]/gdb/testsuite/../data-directory + GNU gdb (GDB) 7.3.50.20110906-cvs + Copyright (C) 2011 Free Software Foundation, Inc. + License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> + This is free software: you are free to change and redistribute it. + There is NO WARRANTY, to the extent permitted by law. Type "show copying" + and "show warranty" for details. + This GDB was configured as "i686-unknown-gnu0.3". + For bug reporting instructions, please see: + <http://www.gnu.org/software/gdb/bugs/>. + (gdb) set height 0 + (gdb) set width 0 + (gdb) dir + Reinitialize source path to empty? (y or n) y + Source directories searched: $cdir:$cwd + (gdb) dir ../../../master/gdb/testsuite/gdb.base + Source directories searched: [...]/gdb/testsuite/../../../master/gdb/testsuite/gdb.base:$cdir:$cwd + (gdb) p 1 + $1 = 1 + PASS: gdb.base/readline.exp: Simple operate-and-get-next - send p 1 + (gdb) p 2 + $2 = 2 + PASS: gdb.base/readline.exp: Simple operate-and-get-next - send p 2 + (gdb) p 3 + $3 = 3 + PASS: gdb.base/readline.exp: Simple operate-and-get-next - send p 3 + (gdb) p 3(gdb) p 3PASS: gdb.base/readline.exp: Simple operate-and-get-next - C-p to p 3 + ^H2(gdb) p 2PASS: gdb.base/readline.exp: Simple operate-and-get-next - C-p to p 2 + ^H1(gdb) p 1PASS: gdb.base/readline.exp: Simple operate-and-get-next - C-p to p 1 + ^OFAIL: gdb.base/readline.exp: Simple operate-and-get-next - C-o for p 1 + FAIL: gdb.base/readline.exp: operate-and-get-next with secondary prompt - send if 1 > 0 + FAIL: gdb.base/readline.exp: print 42 (timeout) + FAIL: gdb.base/readline.exp: arrow keys with secondary prompt (timeout) + spawn [...]/gdb/testsuite/../../gdb/gdb -nw -nx -data-directory [...]/gdb/testsuite/../data-directory + ERROR: (timeout) GDB never initialized after 10 seconds. + ERROR: no fileid for coulomb + ERROR: no fileid for coulomb + UNRESOLVED: gdb.base/readline.exp: Simple operate-and-get-next - send p 7 + testcase ../../../master/gdb/testsuite/gdb.base/readline.exp completed in 646 seconds + Running ../../../master/gdb/testsuite/gdb.base/wchar.exp ... + Executing on host: gcc -c -g -o [...]/gdb/testsuite/gdb.base/wchar0.o ../../../master/gdb/testsuite/gdb.base/wchar.c (timeout = 300) + spawn gcc -c -g -o [...]/gdb/testsuite/gdb.base/wchar0.o ../../../master/gdb/testsuite/gdb.base/wchar.c + Executing on host: gcc [...]/gdb/testsuite/gdb.base/wchar0.o -g -lm -o [...]/gdb/testsuite/gdb.base/wchar (timeout = 300) + spawn gcc [...]/gdb/testsuite/gdb.base/wchar0.o -g -lm -o [...]/gdb/testsuite/gdb.base/wchar + get_compiler_info: gcc-4-6-1 + spawn [...]/gdb/testsuite/../../gdb/gdb -nw -nx -data-directory [...]/gdb/testsuite/../data-directory + ERROR: (timeout) GDB never initialized after 10 seconds. + ERROR: no fileid for coulomb + ERROR: no fileid for coulomb + ERROR: no fileid for coulomb + ERROR: couldn't load [...]/gdb/testsuite/gdb.base/wchar into [...]/gdb/testsuite/../../gdb/gdb (timed out). + ERROR: no fileid for coulomb + ERROR: Delete all breakpoints in delete_breakpoints (timeout) + ERROR: no fileid for coulomb + UNRESOLVED: gdb.base/wchar.exp: setting breakpoint at wchar.c:34 (timeout) + testcase ../../../master/gdb/testsuite/gdb.base/wchar.exp completed in 797 seconds + [...] + # IRC, freenode, #hurd, 2012-08-09 diff --git a/open_issues/whole_system_debugging.mdwn b/open_issues/whole_system_debugging.mdwn new file mode 100644 index 00000000..b438c5cf --- /dev/null +++ b/open_issues/whole_system_debugging.mdwn @@ -0,0 +1,19 @@ +[[!meta copyright="Copyright © 2012 Free Software Foundation, Inc."]] + +[[!meta license="""[[!toggle id="license" text="GFDL 1.2+"]][[!toggleable +id="license" text="Permission is granted to copy, distribute and/or modify this +document under the terms of the GNU Free Documentation License, Version 1.2 or +any later version published by the Free Software Foundation; with no Invariant +Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license +is included in the section entitled [[GNU Free Documentation +License|/fdl]]."]]"""]] + +[[!tag open_issue_gdb open_issue_gnumach]] + +Given our distributed system structure, it'd be immensely useful then when a +[[RPC]] to another entitiy is made, [[GDB]] followed suit. + +[[GDB]] does have some *multi-process* debugging infrastructure which should +basically be usable for this. + +[[`mach_msg`|microkernel/mach/message]] is the *great barrier*, of course. |