* How do I add my tcg tests to check-tcg?
@ 2020-06-03 9:51 Bastian Koppelmann
2020-06-03 10:25 ` Alex Bennée
0 siblings, 1 reply; 3+ messages in thread
From: Bastian Koppelmann @ 2020-06-03 9:51 UTC (permalink / raw)
To: qemu-devel; +Cc: alex.bennee
Hi Alex,
I have some time again to integrate my tcg tests patch for TriCore [1]. However,
I'm struggeling a bit to get through the details of the Makefiles. I'm assuming
the right rule to run is 'make check-tcg'. I tried running that for
xtensa-softmmu, arm-softmmu, and aarch64-softmmu, but they are always skipped.
Digging into the Makefiles I found that there is some way to use the dockerfiles
to run the test. Can someone elighten me on how to properly use this?
Thanks and cheers,
Bastian
[1] https://lists.nongnu.org/archive/html/qemu-devel/2018-05/msg00074.html
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: How do I add my tcg tests to check-tcg?
2020-06-03 9:51 How do I add my tcg tests to check-tcg? Bastian Koppelmann
@ 2020-06-03 10:25 ` Alex Bennée
2020-06-04 9:05 ` Bastian Koppelmann
0 siblings, 1 reply; 3+ messages in thread
From: Alex Bennée @ 2020-06-03 10:25 UTC (permalink / raw)
To: Bastian Koppelmann; +Cc: qemu-devel
Bastian Koppelmann <kbastian@mail.uni-paderborn.de> writes:
> Hi Alex,
>
> I have some time again to integrate my tcg tests patch for TriCore [1]. However,
> I'm struggeling a bit to get through the details of the Makefiles. I'm assuming
> the right rule to run is 'make check-tcg'. I tried running that for
> xtensa-softmmu, arm-softmmu, and aarch64-softmmu, but they are always skipped.
> Digging into the Makefiles I found that there is some way to use the dockerfiles
> to run the test. Can someone elighten me on how to properly use this?
The configure script in tests/tcg/configure.sh will probe for available
cross compilers (or take a passed in one). Failing that you can fall
back to a docker image which has the compilers included.
The result should end up in:
$(BUILD_DIR)/tests/tcg/config-$(PROBE_TARGET).mak
Assuming you have a CROSS_CC_GUEST or DOCKER_IMAGE and
DOCKER_CROSS_CC_GUEST defined there the makefiles should allow building
of the tests.
For linux-user we include the tests/tcg/multiarch/Makefile.target as
well as the target specific one. The CC variable should already be setup
to build either via docker or using the installed setup.
We don't have a linker or assembler in the tooling so everything is
invoked via the compiler with the appropriate flags to call the
sub-tools if required. Most rules are single file compile and link.
For softmmu tests things are a bit more bespoke. The tooling will make
sure things are setup and then include
tests/tcg/multiarch/system/Makefile.softmmu-target and
tests/tcg/$ARCH/Makefile.softmmu-target. The main purpose of the arch
specific Makefile is to provide the appropriate build instructions to
build a system image for the multiarch tests and any target specific
tests.
To support the multiarch tests you need a boot.S and a kernel.ld that
defines a simple boot and a __sys_outc helper function. There is a
minilib which provides for a basic printf like output. The boot should
call main and then return the int code via some mechanism to signal the
pass/fail of the test. For aarch64 this is done with semihosting.
Please let me know if you have any more questions.
>
> Thanks and cheers,
> Bastian
>
> [1] https://lists.nongnu.org/archive/html/qemu-devel/2018-05/msg00074.html
--
Alex Bennée
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: How do I add my tcg tests to check-tcg?
2020-06-03 10:25 ` Alex Bennée
@ 2020-06-04 9:05 ` Bastian Koppelmann
0 siblings, 0 replies; 3+ messages in thread
From: Bastian Koppelmann @ 2020-06-04 9:05 UTC (permalink / raw)
To: Alex Bennée; +Cc: qemu-devel
Hi Alex,
On Wed, Jun 03, 2020 at 11:25:36AM +0100, Alex Bennée wrote:
>
> Bastian Koppelmann <kbastian@mail.uni-paderborn.de> writes:
>
> > Hi Alex,
> >
> > I have some time again to integrate my tcg tests patch for TriCore [1]. However,
> > I'm struggeling a bit to get through the details of the Makefiles. I'm assuming
> > the right rule to run is 'make check-tcg'. I tried running that for
> > xtensa-softmmu, arm-softmmu, and aarch64-softmmu, but they are always skipped.
> > Digging into the Makefiles I found that there is some way to use the dockerfiles
> > to run the test. Can someone elighten me on how to properly use this?
>
> The configure script in tests/tcg/configure.sh will probe for available
> cross compilers (or take a passed in one). Failing that you can fall
> back to a docker image which has the compilers included.
>
> The result should end up in:
> $(BUILD_DIR)/tests/tcg/config-$(PROBE_TARGET).mak
that file did not get generated, as I didn't add TriCore to
tests/tcg/configure.sh
Thanks for the quick help. I have sent the TriCore tcg-tests series to the list.
Cheers,
Bastian
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-06-04 9:07 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-03 9:51 How do I add my tcg tests to check-tcg? Bastian Koppelmann
2020-06-03 10:25 ` Alex Bennée
2020-06-04 9:05 ` Bastian Koppelmann
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).