The RTEMS Tester work using coverage has been left aside for the moment. This
post details the testing of Couverture-QEMU against the RSB built QEMU without
the coverage flag being passed to rtems-test.
The Xilinx Zynq A9 BSP is built with:
When running the testsuite with rtems-test it produces qemu.cfg errors as
before. These error messages produce exit codes that aren’t standardized and
are more of a general error message which is not much to go on. I found a useful
flag –report-mode=all to add to rtems-test runs that produces a more detailed
error log. This produced:
Now there was a neccessary patch to get Couverture-qemu to build from the
previous work that swapped ‘gthread-2.0’ for ‘glib-2.0’ that might be a problem.
I also found that the problem first arose in glib-2.46.0 so maybe forcing the
use of an earlier version would work. I found some patches from mainline qemu
to fix the GLib warning. It was caused because GLib removed support for malloc
vtable because it broke when constructors called g_malloc. The patches fix was
to remove malloc tracing, I was worried that this might have negative effects
on the coverage analysis ability as it reduces trace information. After this I
am still left with the ‘gic_cpu_write..’ problem.
Luckily I got talking to one of the Couverture-Qemu devs and he told me that
they hadn’t updated the default branch for the source download. So there was
actually a newer stable release which fixed all of the above problems. If I
wasn’t such a git novice I probably would have figued this out myself. I had
been using ‘git remote show’ and thought this is showing me what was available
but I needed ‘git ls-remote’ to see all the possible remote branches. There was
‘ref/heads/qemu-stable-2.4.1’ and in order to retrieve that I needed
‘git checkout -b qemu-stable-2.4.1 origin/qemu-stable-2.4.1’. All of the above
problems disappeared and none of the patches were now needed. It did introduce
a few new dependencies for my system ‘libpixman-1-dev’ and ‘libfdt-dev’
The testing consisted of running hello.exe by hand and passing different options
to it to determine the correct options and then running the testsuite with
RTEMS Tester for both RSB-QEMU and Couverture-Qemu. Adjust the qemu options if
most results were invalid or timed out. If a BSP had no current support in
RTEMS Tester I would add a bsp.mc file to handle the qemu options.
There were 3 BSPS that produced good results almost entirely agreeing between
RSB-Qemu and Couverture-Qemu.
ARM: xilinx zynq a9 qemu
ARM: realview pbx a9 qemu
SPARC: Leon 3
For the folowing 4 BSPS qemu runs the tests but fails to exit and so the tests
time out. If I run hello.exe by hand it hangs on the line ‘end of test hello
world’ and must be manually exited (crtl+c). This turns into tests timing out
in RTEMS Tester.
The BSPS affected are
A note on PC386, Couverture-Qemu reacts as above but passes the test instead of
a timeout. RSB-Qemu hangs just before the hello world output and must be
manually exited. When hello.exe is run both take 3 minutes, RSB-Qemu times out
and Couverture-Qemu passes it. I ran the entire testsuite with Couverture-qemu
because it appeared to have valid results i.e not many invalid or timed out.
It took 7 hours and a lot of tests passed that probably should have timed out.
There was 2 other exceptions lm32: milkymist BSP fails to run hello.exe due to
an audio driver issue
The other was PowerPC: qemuprep which qemu fails to boot as no boot partition is
found. I tried to boot it from a floppy disk image with
It still found no boot partition. I filed tickets for all these issues 1,
2 and 3. I now have 3 BSPS to build my RTEMS Tester coverage work on and to
test with. The other BSPS can be sorted out later on. I will now begin the work
of switching the RTEMS Source Builder to build Couverture-Qemu as the standard
RTEMS QEMU variant.