[LLVMdev] Newbee question: LLVM backend regression tests for thumb1 targets on simulator possible?

Bjoern Haase bjoern.m.haase at web.de
Tue Dec 16 00:31:41 PST 2014


Am 15.12.2014 19:31, schrieb Jonathan Roelofs:
> Why not test your v6m changes on a Cortex-m0 QEMU? Semihosted 
> applications are pretty easy to get going, something like:
>
> $ qemu-system-arm -semihosting -M integratorcp -cpu cortex-m0 -kernel 
> a.out
>
Thank you, Jonathan, for your reply. I will be checking this out. To my 
knowledge there was no free simulator for cortex M0! Great to see that 
there *is* an option.

> Thumv4t support is a bit spotty in llvm as it's not very well tested. 
> The problem I run into most (and fixed several times), is that 
> thumbv4t doesn't have a lo->lo mov instruction that doesn't clobber 
> cpsr. That being said, it does work for the most part... just 
> something to watch out for.
>>
OK, good to know this. I considered using v4t only because I assumed 
that licensing prohibited free simulators for v6m.

>
> I routinely run the libc++ & libc++abi test suites in QEMU, but that's 
> more of a whole-toolchain test, rather that just a backend test. You 
> can get surprisingly far without simulator testing, so for most 
> things, LLVM doesn't use it for testing. This makes it easier for any 
> random developer to check out the llvm sources, build them, and run 
> the testsuite, and not have to have simulators installed for all the 
> different backends.
>> - If not, how is regression testing for the thumb1 targets currently
>> implemented?
> We use the LIT framework http://llvm.org/docs/CommandGuide/lit.html to 
> test the compiler. Mostly this means feeding in llvm IR, and using 
> FileCheck http://llvm.org/docs/CommandGuide/FileCheck.html (which is 
> basically a glorified grep) to verify that the assembly produced is 
> the same as what the test expects to be generated.
>
OK, I will look after this, It might take me some time to understand the 
mechanisms.

Thank's again for your support.

Björn.



More information about the llvm-dev mailing list