Skip to content

Conversation

hartwork
Copy link
Contributor

@henry2cox I keep getting this mismatch error:

+ make check
Creating coverage files (2 tests, 5 source files)
  Source tree ......... done (950 lines, 50 functions, 3428 branches)
  Full coverage ....... done
  Target coverage ..... done
  Partial coverage .... done
  Zero coverage ....... done
Starting tests
genhtml/full.sh ................... [pass] (time 0.5s, mem 47.0MB)
genhtml/zero.sh ................... [pass] (time 0.5s, mem 46.8MB)
genhtml/demangle.sh ............... [pass] (time 1.4s, mem 39.0MB)
genhtml/relative/relative.sh ...... [pass] (time 0.3s, mem 39.0MB)
genhtml/lambda/lambda.sh .......... [fail] (time 1.5s, mem 124.2MB)
    Skipping 165 previous lines (see /home/runner/work/lcov-fork/lcov-fork/tests//test.log)
    ...
      Lines executed:94.21% of 916
    stderr:
      /home/runner/work/lcov-fork/lcov-fork/tests/genhtml/lambda/lambda.gcno:version 'B33*', prefer 'B50 '
      /home/runner/work/lcov-fork/lcov-fork/tests/genhtml/lambda/lambda.gcda:version 'B33*', prefer version 'B50 '
    lcov: ERROR: (version) Incompatible GCC/GCOV version found while processing /home/runner/work/lcov-fork/lcov-fork/tests/genhtml/lambda/lambda.gcda:
    	Your test was built with 'B33*'.
    	You are trying to capture with gcov tool '/usr/bin/gcov' which is version 'B50 '.
    	(use "lcov --ignore-errors version ..." to bypass this error)
    Error:  unexpected error code from lcov
  EXITCODE ...: 1
make[3]: *** [../../common.mak:116: check] Error 1
make[2]: *** [../common.mak:116: check] Error 1
5 tests executed, 4 passed, 1 failed, 0 skipped (time 4.2s, mem 296.0MB)
Result log stored in /home/runner/work/lcov-fork/lcov-fork/tests/test.log
make[1]: *** [common.mak:116: check] Error 1
make: *** [Makefile:270: check] Error 2

Both GCC and GCOV are at version 15 here so I'm not sure why. Does "B33" and "B50" ring a bell with you? Any ideas what to try?

@henry2cox
Copy link
Collaborator

The only times I have seen such messages is when the version of gcc used to create the .gcno and/or .gcda data is not the same as the gcov version used to capture.
Offhand: I don't know which gcc version "B33" nor "B50" correspond to...but that would likely be a good clue.

Two things that might be happening here:

  • incomplete 'clean' set between regression executions which use different toolchains: some shrapnel left behind that the next one finds
  • strange path such that you are picking up gcc in one place and gcov in another - or, more likely, that the gcc release you are pointing to holds a mismatched gcov version.

Either way: it would be useful to echo the gcc, g++, and gcov versions to the log.

When I see this, it has always been because the user generated data on one machine and then tried to capture on another.

Not sure if this is helpful.

@hartwork
Copy link
Contributor Author

Either way: it would be useful to echo the gcc, g++, and gcov versions to the log.

@henry2cox I made the CI echo those versions in the past during stage Make GCC <version> systemwide default and went to check the output (at https://github.com/hartwork/lcov-fork/actions/runs/13996918220/job/39194270383) and found that commands g++ and cpp were skipped rather than rewired to GCC 15. That finding then led to the fix — installing two more packages:

# git --no-pager diff 8498b31 HEAD
diff --git a/.github/workflows/run_test_suite.yml b/.github/workflows/run_test_suite.yml
index 6e466e3..1189609 100644
--- a/.github/workflows/run_test_suite.yml
+++ b/.github/workflows/run_test_suite.yml
@@ -49,7 +49,7 @@ jobs:
             install:
           - runs-on: ubuntu-24.04
             gcc: 15
-            install: binutils gcc-15
+            install: binutils g++-15 gcc-15 cpp-15
     steps:
       - uses: actions/checkout@v4
 

I believe the pull request is ready for review (and potentially merging) now.

@hartwork hartwork changed the title [DRAFT] run_test_suite.yml: Start covering GCC 15 run_test_suite.yml: Start covering GCC 15 Mar 24, 2025
@hartwork hartwork changed the title run_test_suite.yml: Start covering GCC 15 Start covering GCC 15 in CI Mar 24, 2025
@henry2cox
Copy link
Collaborator

Looks good - thanks for the increased testing.
And sorry for the delay - got wrapped up in some other stuff, then in another lcov bug.

@henry2cox henry2cox merged commit 51515e7 into linux-test-project:master Mar 25, 2025
5 checks passed
@hartwork
Copy link
Contributor Author

hartwork commented Mar 25, 2025

@henry2cox no worries — thank you! 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants