[mips][msa] Enable inlinse assembly for MSA.
authorDaniel Sanders <daniel.sanders@imgtec.com>
Tue, 12 Nov 2013 12:56:01 +0000 (12:56 +0000)
committerDaniel Sanders <daniel.sanders@imgtec.com>
Tue, 12 Nov 2013 12:56:01 +0000 (12:56 +0000)
commit9e2838e29b0820afc35f6ef2d465d4aca9ed402a
treef3fcd266bee421161a54ca4a5dbba55b3e5f5f24
parentf681437cb082bf6fb5da43c8acd4e1313ba3b213
[mips][msa] Enable inlinse assembly for MSA.

Like GCC, this re-uses the 'f' constraint and a new 'w' print-modifier:
  asm ("ldi.w %w0, 1", "=f"(result));

Unlike GCC, the 'w' print-modifer is not _required_ to produce the intended
output. This is a consequence of differences in the internal handling of
the registers in each compiler. To be source-compatible between the
compilers, users must use the 'w' print-modifier.

MSA registers (including control registers) are supported in clobber lists.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194476 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/Mips/MipsAsmPrinter.cpp
lib/Target/Mips/MipsISelLowering.cpp
test/CodeGen/Mips/msa/inline-asm.ll [new file with mode: 0644]