Commit Graph

9 Commits

Author SHA1 Message Date
Jim Lin 9c0ac101d7 [M68k][test][NFC] Add missing tests for arith inst with size byte or word 2022-01-06 16:40:40 +08:00
Jim Lin cb0e12a144 [M68k][test][NFC] Add missing tests for MxCMP_RM
Let each format of inst have two tests for it like other MxCMP
testcases.
2022-01-06 10:38:53 +08:00
Jim Lin 75ea6b4319 [M68k][test][NFC] Fix no newline at end of file 2022-01-06 10:07:35 +08:00
Jim Lin 30d739603c [M68k][test][NFC] Remove new line at end of file 2022-01-05 17:05:54 +08:00
Jim Lin c6c19a77e3 [M68k][test][NFC] Remove unecessary labels and assembly directives 2022-01-05 15:49:05 +08:00
Min-Yih Hsu 657bb7262d [M68k] Separate ADDA from ADD and migrate rest of the arithmetic MC tests
Previously ADD & ADDA (as well as SUB & SUBA) instructions are mixed
together, which not only violated Motorola assembly's syntax but also
made asm parsing more difficult. This patch separates these two kinds of
instructions migrate rest of the tests from
test/CodeGen/M68k/Encoding/Arithmetic to test/MC/M68k/Arithmetic.

Note that we observed minor regressions on codegen quality: Sometimes
isel uses ADD instead of ADDA even the latter can lead to shorter
sequence of code. This issue implies that some isel patterns might need
to be updated.
2021-08-07 17:19:12 -07:00
Min-Yih Hsu f6d7fc801b [M68k][test][NFC] Scrubing some tests
Remove unecessary labels and assembly directives. NFC.
2021-05-05 17:48:28 -07:00
Min-Yih Hsu abac6023bb [M68k][AsmParser] Support negative integer constants
Parsing negative integer constants as expressions.

Differential Revision: https://reviews.llvm.org/D101732
2021-05-05 17:11:59 -07:00
Min-Yih Hsu 34da083a8c [M68k][test] Initial migration of MC tests
As the context depicted by bug 49865[1], we are migrating tests under
`test/CodeGen/M68k/Encoding`, which was originally used to test
instruction encoding using MIR file as input, into `test/MC/M68k`. We
are also adding test directives for AsmParser using the same set of
inputs.

Currently we are converting the original MIR test files into assembly
code as well as translating the original LIT "RUN" statement into one
that only uses built-in LLVM tools (i.e. Get rid of `extract-section`).

However, since AsmParser has not completely finished, many of these
original test cases fail. Thus, this patch only migrate test files
that are passed by the current implementation of AsmParser (and
MCCodeEmitter). The remaining tests (under test/CodeGen/M68k/Encoding)
will be ported alone with the patch that fixes the related issues.

[1]: https://bugs.llvm.org/show_bug.cgi?id=49865

Differential Revision: https://reviews.llvm.org/D101410
2021-05-05 17:11:35 -07:00