[PATCH] [llvm] [Hexagon] Adding tests, TableGen entries, and code for emitting add opcode.

Rafael EspĂ­ndola rafael.espindola at gmail.com
Fri Oct 10 08:12:09 PDT 2014


> Disassembler tests might be possible, I hadn't considered that before.  We had thought the gtests would be sufficient since the inputs and outputs shouldn't vary as time goes on since the instructions and their encoding are tied to existing hardware.
>
> What types of problems with clang-format tests are we looking to avoid?  We have a fair number of instructions with running gtests we have pretty much prepped for upstreaming and haven't encountered any problems but we want to avoid something maybe we haven't thought of.

With gtest you end up with a massive .cpp files which are hard to read
and hard to check against a native tool. IMHO it is also way too easy
to simply write gtest tests that just check that copy and paste is
working :-(

If you checkin a .o and test disassembly, things are much better IMHO:
* You can check the .o agains a native tool or even the CPU.
* You get an end to end test.
* FileCheck error makes it very easy to see what instruction failed to
disassemble.

Cheers,
Rafael




More information about the llvm-commits mailing list