File: instr-analysis.s

package info (click to toggle)
swiftlang 6.0.3-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 2,519,992 kB
  • sloc: cpp: 9,107,863; ansic: 2,040,022; asm: 1,135,751; python: 296,500; objc: 82,456; f90: 60,502; lisp: 34,951; pascal: 19,946; sh: 18,133; perl: 7,482; ml: 4,937; javascript: 4,117; makefile: 3,840; awk: 3,535; xml: 914; fortran: 619; cs: 573; ruby: 573
file content (36 lines) | stat: -rw-r--r-- 996 bytes parent folder | download | duplicates (15)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
# RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o - \
# RUN:   | llvm-objdump -d - | FileCheck %s

# CHECK:      <foo>:
# CHECK-NEXT:        0:       0c 00 00 02     jal     0x8 <loc1>
# CHECK-NEXT:        4:       00 00 00 00     nop
#
# CHECK:      <loc1>:
# CHECK-NEXT:        8:       0c 00 00 06     jal     0x18 <loc3>
# CHECK-NEXT:        c:       00 00 00 00     nop
#
# CHECK:      <loc2>:
# CHECK-NEXT:       10:       10 00 ff fd     b	      0x8 <loc1>
# CHECK-NEXT:       14:       00 00 00 00     nop
#
# CHECK:      <loc3>:
# CHECK-NEXT:       18:       10 43 ff fd     beq     $2, $3, 0x10 <loc2>
# CHECK-NEXT:       1c:       00 00 00 00     nop
# CHECK-NEXT:       20:       04 11 ff f9     bal     0x8 <loc1>
# CHECK-NEXT:       24:       00 00 00 00     nop
# CHECK-NEXT:       28:       08 00 00 04     j       0x10 <loc2>

  .text
  .globl foo
  .ent foo
foo:
  jal loc1
loc1:
  jal loc3
loc2:
  b   loc1
loc3:
  beq $2, $3, loc2
  bal loc1
  j   loc2
  .end foo