Re-commit: [mips] Correct section alignments and EntrySizes for .bss, .text, .data...
[oota-llvm.git] / test / MC / Mips / micromips-16-bit-instructions.s
1 # RUN: llvm-mc %s -triple=mipsel -show-encoding -mattr=micromips | \
2 # RUN: FileCheck -check-prefix=CHECK-EL %s
3 # RUN: llvm-mc %s -triple=mips -show-encoding -mattr=micromips | \
4 # RUN: FileCheck -check-prefix=CHECK-EB %s
5 # Check that the assembler can handle the documented syntax
6 # for arithmetic and logical instructions.
7 #------------------------------------------------------------------------------
8 # MicroMIPS 16-bit Instructions
9 #------------------------------------------------------------------------------
10 # Little endian
11 #------------------------------------------------------------------------------
12 # CHECK-EL: mfhi    $9              # encoding: [0x09,0x46]
13 # CHECK-EL: mflo    $9              # encoding: [0x49,0x46]
14 # CHECK-EL: move    $25, $1         # encoding: [0x21,0x0f]
15 # CHECK-EL: jalr    $9              # encoding: [0xc9,0x45]
16 #------------------------------------------------------------------------------
17 # Big endian
18 #------------------------------------------------------------------------------
19 # CHECK-EB: mfhi    $9              # encoding: [0x46,0x09]
20 # CHECK-EB: mflo    $9              # encoding: [0x46,0x49]
21 # CHECK-EB: move    $25, $1         # encoding: [0x0f,0x21]
22 # CHECK-EB: jalr    $9              # encoding: [0x45,0xc9]
23
24     mfhi    $9
25     mflo    $9
26     move    $25, $1
27     jalr    $9