aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2024-05-02lib/stam.sh (check_stamp): Compute action message only onceHEADtestedmasterChristophe Lyon
Replace several expansions of "${stamp_type:+, ${stamp_type}ing..}." with only one, using an intermediate variable. This makes sure we always use the same message. Change-Id: Ib33c75a1fbb63ccadce04dfd2ead7acb7e6b4ee5
2024-04-15Add support to build gprofngChristophe Lyon
and enable it with binutils master config Change-Id: I5c51cb539d01ebd5adcc77cd1ab715e4bfe6cc48
2024-04-15Add support for --enable full_docsChristophe Lyon
Make --enable make_docs behave as before a recent patch: install html and info formats by default. --enable full_docs adds pdf and dvi formats, which are not supported by some of the older toolchain components versions. This way, ABE is still able to build successfully toolchains of older versions, and --enable full_docs enables more document formats if desired. Change-Id: I358f913970dd8c9505362afa6e929aeadaf3bca9
2024-04-08config/glibc.conf: Improve coverageAdhemerval Zanella
The extra options are the ones usually used by distributions. Although all are security oriented, it improves the test coverage. Change-Id: I4a93a3a9280111ff7cf8436990ac00503133ee13
2024-04-04lib/make.sh (make_docs): Report errors when building gdb docsChristophe Lyon
Also use the same scheme to report errors when building docs for other components. Change-Id: I6f1404d3d58ac8eeab2c7b56bd91a741ee4d74d3
2024-04-02lib/make.sh (make_docs): Build more docsChristophe Lyon
Build PDF docs for binutils, gdb and gcc. Build man pages for binutils, gcc and libstdc++. For libstdc++, this requires 'doxygen' and 'dot' to be present (they are detected at configure time, and this is a no-op if they are absent). Note that gdbserver documentation is part of the gdb component. Change-Id: I94579cf085bb2ff78f45c34b93015100ceb8ae0a
2024-04-02config/binutils.conf: Disable gdbserverChristophe Lyon
ABE has a dedicated component for gdbserver, so do not build it as part of binutils. Change-Id: I077d3195513c4348479fefbe73d26106f8ef5406
2024-03-13lib/make.sh: Fix test-container tests on armhfAdhemerval Zanella
The glibc tests are built in two different modes (enabled at configure time): 1. No RPATH defined, tests will run by issuing the loader along with the required library paths. It is the default option. 2. RPATH defined, tests will have RPATH pointing to the build directory, so the kernel will be responsible for running the loader. It enables with --enable-hardcoded-path-in-tests. In both cases, the loader consults the system cache (ld.so.cache), so any compiler dynamic library (libgcc_s.so for instance) is supplied by the system. However, this might fail for container tests, where even test-container (the binary that setups and runs the tests in a container mode) creates a loader cache that might not contain the required libraries. The glibc build system tries to check and provide the required libraries by tracing the DT_NEEDED one from a test binary, but the tracing inhibits the system loader, and thus it will not copy the required system libraries. It is expected the user to copy the required libraries to build a directory. This works for case 2., however, test-container does not issue the loader for case 1.: it will parse the command arguments and issue the binary and the kernel will be responsible for starting the loader. This has the side-effect of ignoring all the defined --library-path and thus making the compiler libraries copy trick ineffective. So we copy the compiler libraries on both the build directory and on the sysroot used by the test-container to set each test. The former handles the case 1., while the latter will place the libraries on the default system path, which will be included in the loader cache as well (and handling case 2.). Change-Id: I5b90c733a92a5980a8f33e5b6a5c67f768f91906
2024-03-04lib/stamp.sh (check_stamp): Fix typo in previous commitChristophe Lyon
Change-Id: Ide588436ab5c3f5f5a4d945cabb5170752ff9ae5
2024-03-04lib/make.sh (build): Print stamps of directory srcdir instead of symlinkChristophe Lyon
It seems 'test -nt' does not check the same dates as reported by 'stat -c %Y'. Change-Id: Ia403b4b23b6768cf3ef3623559b79f758d34b9cb
2024-02-29lib/make.sh (build): Print stamps of srcdirChristophe Lyon
... after configure and after build, to help understand why a subsequent call to ABE decides it's worth rebuilding. Change-Id: I27ed7103231769280e635ffe9cc76014ef7f3ae4
2024-02-29Fix typo in info messages.Christophe Lyon
Change-Id: Ic0040c14b36af622b8e45cf13b3a616538478219
2024-02-22abe.sh: maintainer_mode implies make_docsChristophe Lyon
Under --enable maintainer_mode, we probably want to enable make_docs, unless disabled later on the command line. This ensures that when we activate maintainer_mode, we also make sure that the (possibly updated) docs can be built. Change-Id: I78e57eb0fc53ca37e9d72360e4031b59dd612d8a
2024-02-21Add FIXMEs for aarch64-w64-mingw32Maxim Kuvyrkov
Change-Id: I880b743bef731d569386a896f4381ee50170bbd9
2024-02-14manifest(): Skip packages when using default system versionChristophe Lyon
The loop which iterates over gcc, binutils and ${clibrary} expects the sources of all these packages to be available so that we can copy information into the manifest. However, this is not true when building a single package (eg with --build gcc), leading to spurious error messages in the logs, such as: fatal: cannot change to 'default': No such file or directory fatal: cannot change to 'log': No such file or directory which happen because 'binutils' is defined to 'default' and 'clibrary' to 'auto' in global.sh, leading to incorrect definition of srcdir. This patch explicitly skips 'default' and '' values for srcdir. Change-Id: I7caaf52f0b727e10fc15a322389062999b9b755f
2024-02-14Use a single make-${component}.log logfile for all build stepsChristophe Lyon
Merge 'all', 'make_docs' and 'install' logs into a single file, to make information easier to find/manage in CI. Insert a "NOTE:" before each fragment to make identification of each step easier. Change-Id: I4a90d28b40b6c93ef9a88d43d306df2a478feca0
2024-02-14make.sh: Do not override BUILD_INFO nor MAKEINFO with --disable make_docsChristophe Lyon
GCC's top-level Makefile does not propagate BUILD_INFO to sub-makes, instead BUILD_INFO is defined at configure time depending on the availability of a suitable version of makeinfo (so overriding MAKEINFO=echo like we used to do is sufficient). However, it seems cleaner to define a fake makeinfo wrapper outside ABE (like we do in CI), and don't try to play tricks with GCC's Makefiles. With this patch, make_docs only enables/disables building the optional versions of the documentations (eg HTML). Change-Id: I56652e5048e2898a3f8e74af3cbde96a1a471aa7
2024-02-14Make 'install' and 'makedoc' logs follow the same pattern as 'all' onesChristophe Lyon
We generate 'make all' logs as ${builddir}/make-${component}${2:+-$2}.log but 'make install' and 'make doc' do not follow the same pattern: - we store 'make install' logs in ${builddir}/.. - we store 'make doc' logs as makedoc.log (without component name) This patch makes all of them follow the same pattern: ${builddir}/{make,makedoc,install}-${component}${2:+-$2}.log Change-Id: If3438fd63ce35e449ca6ea606d313f384efea094
2024-02-09config/linaro.exp: Change Expect's buffer size to 100kThiago Jung Bauermann
The default buffer size Expect uses to hold the tool's output is 2000 bytes. This is too low for some GDB tests which run commands generating a lot of output — e.g., when they turn on GDB debug output or when testing GDB's Machine Interface which is verbose. As a result those GDB tests become flaky because depending on the testsuite run, the expected GDB output may have already been removed from the buffer by the time Expect tries to match it. Well-written tests shouldn't have that problem because they are supposed to frequently match GDB's output (which removes it from the buffer), but in practice a number of tests don't yet do that. By increasing the buffer size we can reduce the severity of this problem, increasing the stability of testsuite results. The Expect man page notes that "excessively large values can slow down the pattern matcher". With the default buffer size, a tcwg_gdb_check job on aarch64-linux takes about 115 minutes. With this patch, it takes about 145 minutes. I think the extra time is worth it though. I also tried buffer sizes of 65k and 200k, but with the former the results aren't as good as with 100k, and with 200k the results aren't better. Change-Id: I0466c6f19658f7b638cc0e3dcf5023614de8fa41
2024-02-09Add a quick workaround for building aarch64-w64-mingw32Maxim Kuvyrkov
Change-Id: I58ced760f4e45bbc98c18b889ac03c3354bccfca
2024-01-30Add support for --enable maintainer_modeChristophe Lyon
For components binutils, gcc, gdb, gdbserver, glibc, newlib this flags adds --enable-maintainer-mode to the configure flags. Note that this expacts the appropriate versions of autoconf and automake to be in $PATH (autoconf-2.69 and automake-1.15.1 at the moment). Tested by applying a binutils patch series which requires some files to be regenerated, otherwise there are many failures when running the testsuite: we do see the failures without this flag, and they disappear with this flag. Change-Id: Iadac4c1905761857f976c7b0aa228c4ac1e8c7d5
2024-01-29Add gcc-read1 buffering workaroundChristophe Lyon
Unlike what we do for GDB, gcc-read1 builds the read1 library in ${abe_top} and makes EXPECT point to the expect-read1 wrapper. We rely on ABE's copy of read1, at some point we can probably do the same for GDB for consistency. Change-Id: I43f7d08961f75968900bfa595d3e15977e5530aa
2024-01-29Add READ1 lib and tool to ABEChristophe Lyon
Instead of relying on each of the the projects to include support for READ1, it seems simpler to build it once with ABE, then point to it when running each project's testsuite. We could also think about adding to Dejagnu instead, but adding it to ABE seems easier for the time being. This patch mimics what GDB does, and actually copies read1.c from GDB. We now rely on Makefile.in to expand the appropriate paths at configure time, so that the expect-read1 wrapper is able to find the read1.so shared lib in ${abe_top}. Change-Id: I3500eb714e1a05f5ff99bd73b241812e8879ef26
2024-01-18lib/make.sh (make_check): Copy glibc required gcc librariesAdhemerval Zanella
A recent glibc change (1d5024f4f05) made libsupport (which is used by all tests) to be built with ‘-fexceptions' and ' -fasynchronous-unwind-tables’. Different than aarch64 and x86, these options make arm tests require libgcc_so symbols to enable unwind support ((__aeabi_unwind_cpp_pr0/__aeabi_unwind_cpp_pr1). This extra required library is handled by glibc test-container, which is responsible to setup the container tests (all containers tests now fail due to the missing library). The easier solution would be to copy both libgcc_s.so.1 and libstdc++.so.6 to the top-level build folder. It also makes the glibc testing less dependent on the system configuration (for both libgcc_s.so, which is used on cancellation and backtrace tests, and libstdc++.so). Change-Id: I53fb3cfb49fdcdfd629075026219221290abbf60
2024-01-15lib/make.sh (make_check): Support various output buffering workaroundsChristophe Lyon
Similar to GDB's "READ1" mode, I experimented with several buffering workarounds for GCC. Since GCC's Makefiles have many check-* targets, it is not practicable to add a single check-read1 like GDB does. Instead, we could create a 'read1' rule in the top-level Makefile to build read1.so and expect-read1, like what GDB can do. Then, the usual check-* targets can be used, and we can override the READ1 environment variable as needed (as is already supported by GDB). Note that this requires a GCC patch which has not been submitted yet (and may never be, not sure how useful/usable it would be). This patch partially reverts a previous patch which added READ1 support for GDB, and adds the preliminary call to 'make read1' as needed. In addition to "READ!" more, this patch adds support for coreutils' stdbuf-based wrappers, provided as helper scripts. They can be used by overloading the EXPECT variable when calling 'make check'. A GCC patch to fully allow that will be submitted. The advantage of such wrappers is that the machinery is kept part of ABE. Change-Id: I184a486c7101550ad3cd0de12ddb7fd26a8deb7f
2023-12-28lib/make.sh (make_check): Fix generation of the list of .exp files to re-testThiago Jung Bauermann
Maxim spotted that we are using "for_output" fails/passes to construct the list of .exp files to re-test. So that even we "decide" that we need to re-test only a.exp and b.exp, but "for_output" we'll have "a.exp b.exp c.exp ... z.exp", then "c.exp ... z.exp" will also get re-tested. Fix by using $new_fails_for_deciding and $new_passes_for_deciding to generate the $failed_exps list. Suggested-by: Maxim Kuvyrkov <maxim.kuvyrkov@linaro.org> Change-Id: Id1aab541e681a2cf7718529b57baa304e1f1013c
2023-12-27lib/make.sh (make_check): Don't use baseline to build flaky tests listThiago Jung Bauermann
We remove old results from the database, which also removes the flaky entries they provided. This causes our CI to forget previously detected flaky tests. Fix this by making each job record all flaky tests that it detects. So even if it is later removed from the results database, other results will also have the same flaky entries. This has the additional advantage of recording how often each flaky entry occurs. We do this by not using the baseline flaky results when generating the lists of flaky test failures and flaky test passes detected in each testsuite run. We still use the baseline flaky results to decide whether to run another try of the testsuite, so this change won't impact runtime cost. Change-Id: Idf2ec69af9d613511b743f871dc9abfe32e7b977
2023-12-08configure_build: Always update gcc/REVISIONChristophe Lyon
Since we often build withouth --send-results-to, and use that option only when running the tests, don't rely on it when updating gcc/REVISION which is used when building GCC. Change-Id: Ia89c864329a5d355811ff414ebdd8977b8f1e96b
2023-12-08Change update location of LAST_UPDATED and gcc/REVISIONChristophe Lyon
These files are used when sending test results summaries. Since the CI uses Jenkins rather ABE to checkout the sources, we want to update LAST_UPDATED and gcc/REVISION later than the checkout phase. Since we want to include $ABE_TARGET_BOARD_OPTIONS early in the summaries to make them easier to read/more informative, we have to update these two files in two different locations: - gcc/REVISION is used to build the output of 'gcc --version' and has to be updated before starting the build, so we create it before running the configure step. The drawback is that at this stage we don't know about $ABE_TARGET_BOARD_OPTIONS in case the user invokes ABE once to build the toolchain (without $ABE_TARGET_BOARD_OPTIONS), and once to run the tests (with $ABE_TARGET_BOARD_OPTIONS, but too late to update gcc/REVISION). (This is what we do in CI) - LAST_UPDATED is used only by contrib/test_summary, and can be updated when running the tests. Change-Id: I5e50072fc189b7ae41a0829b83155d21294aa282
2023-11-30scripts/testresults2jenkins.sh: Remove "to:" prefix for recipientsChristophe Lyon
because Jenkins creates an error when it is present. Change-Id: I46580b5aeac077b5ae225de19167a61b03b38dc1
2023-11-30scripts/testresults2jenkins.sh: Rename output file with recipientsChristophe Lyon
from mail-recipient.txt to mail-recipients.txt for consistency with our other scripts. Change-Id: I44f509cdb350183065ad2c7923da817c7274abcb
2023-11-22Add scripts/testresults2jenkins.shChristophe Lyon
Move this script from the jenkins-scripts repository. Change-Id: I47ef3ffddf6a711fc9c2526efd6127915039c7dd
2023-11-02Allow specification of --enable-languages=default for GCCMaxim Kuvyrkov
Rename current "default" value to "abe_default". This allows us to build GCC's upstream default languages. Change-Id: I7e3b573092d2747ffd3dd300cfe7a464357668a2
2023-11-02lib/make.sh (exp_to_tool,tool_to_check): Handle Go testsuitesMaxim Kuvyrkov
Change-Id: Iff6617aba91c82d6f006dbc28a0c5fae86c362ae
2023-10-06Add --send-results-filter optionChristophe Lyon
This option is meant to be used with GCC's contrib/test_summary to send validation results to gcc-testresults mailing-list. Instead of emailing the results directly from ABE, we want to let Jenkins handle this step, so this option provides a way of "parsing" the email to transform it into a format suitable for our CI. The CI scripts can provide a filter whose interface would be: cat BODY | filter -s SUBJECT RECIPIENT For instance, it can store BODY, SUBJECT and RECIPIENT in different files, and make them available to Jenkins. Change-Id: I204900945433dac046815267e6993e61fa5ef39b
2023-10-04make.sh: Run GDB testsuite with read1 libraryThiago Jung Bauermann
GDB has a test debugging library which is ld-preloaded into expect and causes it to read one byte at a time from the tested tool. This allows finding test races (see gdb/testsuite/README), and also makes the testsuite run more deterministically. Some testcases are buggy and have additional failures when running under read1. In particular, gdb.linespec/cpcompletion.exp has 422 FAILs and gdb.mi/mi2-var-child.exp has 425 FAILs. A couple of tests in gdb.mi are still as flaky (and verbose) as before though. The testsuite unexpected failures go from 56 to 1411. Still, the increased stability of the test results makes this change worth it. With this change, the check_gdb step goes from about 1h to 5h30m. I'll explore enabling running the tests in parallel to compensate the increase in run time. Change-Id: I1ab812a6ba2492778bca5c87e4480499f76ad6cf
2023-09-27gcc.conf: Add --with-native-system-header-dir=/include when using newlibChristophe Lyon
Newlib installs its header files under $(exec_prefix)/$(host_alias)/include, but by default GCC expects them under $(exec_prefix)/$(host_alias)/usr/include. Before this patch, GCC's configure sets inhibit_libc to 'true', thus preventing libgcc2 from containing any code which requires libc support. For instance, this means that libgcov.a is essentially empty. This patch adds --with-headers=yes --with-native-system-header-dir=/include, so that GCC's configure detects the presence of the needed headers. --with-headers=yes is to be safe, as we don't want it to be set to no, see this part of GCC's configure: -------------------------------------------------- : ${inhibit_libc=false} if { { test x$host != x$target && test "x$with_sysroot" = x ; } || test x$with_newlib = xyes ; } && { test "x$with_headers" = xno || test ! -f "$target_header_dir/stdio.h"; } ; then inhibit_libc=true fi -------------------------------------------------- Change-Id: I4521aea24509dbf5021e844e4a9647df24221966
2023-09-05tcwg-local.exp: Fix gdb_test_timeout, againThiago Jung Bauermann
The default timeout value in the GDB testsuite is supposed to be 1 min (see gdb/testsuite/config/unix.exp), but is actually 10 seconds because the code in lib/gdb.exp which sets 'gdb_test_timeout' from DejaGNU's 'timeout' variable doesn't actually run. Change-Id: I86c38239d79f7dadb5ee5e8077a74108b814e3b8
2023-08-28tcwg-local.exp: Fix gdb_test_timeoutThiago Jung Bauermann
GDB's default timeout value is 1 minute. Setting it to 5 minutes leads to very long GDB check jobs. Change-Id: Ie798eeb12c628a55af24a243245d90601e3b0060
2023-08-11tcwg-local.exp: Set gdb_test_timeoutThiago Jung Bauermann
The GDB testsuite uses its own timeout variable. Change-Id: I1c133cc8846e5d7263af4cc70fc14b25013d0965
2023-08-11tcwg-local.exp: Use TIMEOUTFACTOR environment variable to adjust timeoutThiago Jung Bauermann
The glibc testsuite supports the TIMEOUTFACTOR environment variable, so extend that support to the DejaGNU testsuites we run too. Change-Id: Ica4c086f22e14bd177bc444308c69ecebc0c4e9b
2023-08-10lib/make.sh (check_all): Print target_board optionsChristophe Lyon
As an help to read/parse the build/check logs, display the value of ABE_TARGET_BOARD_OPTIONS before running the tests. Change-Id: Ia6031a09bb9d2f19362900fa25b7ec4113acd90e
2023-08-01lib/make.sh (make_check): Explain validate_failures.py outputThiago Jung Bauermann
When producing a manifest file, validate_failures.py also prints it to stdout. This is a bit confusing in ABE's output so add a notice explaining what it is. Change-Id: If8602cf30ae54b534e04d0fe05c54548fb7e0a42
2023-07-27lib/make.sh (create_glibc_tests_log): Fix grep patternMaxim Kuvyrkov
Change-Id: Icfcc045df67ba30bdb0601551ea97a9a2154b5d5
2023-07-27lib/make.sh: Fix typoMaxim Kuvyrkov
Change-Id: I1808a546dd30da503dc37c9b5880a5ea4dc885b6
2023-07-27lib/make.sh (create_glibc_tests_log): New functionMaxim Kuvyrkov
... to create tests.log from output of failed glibc tests. Change-Id: Idabcd45cfb1715d9933e76a71a4fbe678531553f
2023-07-27lib/make.sh (make_check): Remove handling of xtests.sumMaxim Kuvyrkov
... which we no longer generate due to glibc's xcheck testsuite being poorly supported. Change-Id: I1a7d7bb571f488c63de68758dc04751a854fbd99
2023-07-27lib/make.sh (make_check): Detect glibc tests with low timeout as flaky.Maxim Kuvyrkov
Change-Id: Ibd843c61fabde084654169624f5dd734745b5229
2023-07-04config/gdb.conf: Add --with-additional-debug-dirs optionThiago Jung Bauermann
Add configure option "--with-additional-debug-dirs=/usr/lib/debug" so that GDB can find the distro's debug info in /usr/lib/debug. This fixes Ada tests for tcwg_gnu_native_check_gdb on arm, which use the distro's compiler and thus need to find the distro's ld.so debug symbols. At the moment this option is implemented by a patch applied locally, but it has been submitted upstream. Change-Id: I08470dd5253083642b64d4355d1d49b94af8d49c
2023-07-04Add --set target_board_options supportChristophe Lyon
Dejagnu supports overriding options when running the testsuite, by using --target_board as part of RUNTESTFLAGS. However, since we override RUNTESTFLAGS during automatic bisection, it would be troublesome to maintain the --target_board part. Instead, append these options to $target_list, which is then parsed by runtest. For instance: --set target_board_options="/-O3/-fmerge-constants" --set target_board_options="{-mcpu=cortex-a53/-O2,-mcpu=cortex-a72}" --set target_board_options="{-mlittle-endian,-mbig-endian}{-O1,-O2,-O3,}" See also https://gcc.gnu.org/install/test.html Change-Id: I99b50e35126bdcba9c05560f5213f4dd4482c96e