File: mips-abi-flags.yaml

package info (click to toggle)
llvm-toolchain-13 1%3A13.0.1-11
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 1,418,840 kB
  • sloc: cpp: 5,290,826; ansic: 996,570; asm: 544,593; python: 188,212; objc: 72,027; lisp: 30,291; f90: 25,395; sh: 24,898; javascript: 9,780; pascal: 9,398; perl: 7,484; ml: 5,432; awk: 3,523; makefile: 2,913; xml: 953; cs: 573; fortran: 539
file content (66 lines) | stat: -rw-r--r-- 1,936 bytes parent folder | download | duplicates (25)
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
## Test how yaml2obj creates SHT_MIPS_ABIFLAGS sections.

# RUN: yaml2obj %s -o %t
# RUN: llvm-readobj -A %t | FileCheck %s

# CHECK:      MIPS ABI Flags {
# CHECK-NEXT:   Version: 0
# CHECK-NEXT:   ISA: MIPS64r5
# CHECK-NEXT:   ISA Extension: Cavium Networks Octeon3 (0x13)
# CHECK-NEXT:   ASEs [ (0x103)
# CHECK-NEXT:     DSP (0x1)
# CHECK-NEXT:     DSPR2 (0x2)
# CHECK-NEXT:     VZ (0x100)
# CHECK-NEXT:   ]
# CHECK-NEXT:   FP ABI: Hard float (double precision) (0x1)
# CHECK-NEXT:   GPR size: 64
# CHECK-NEXT:   CPR1 size: 64
# CHECK-NEXT:   CPR2 size: 0
# CHECK-NEXT:   Flags 1 [ (0x1)
# CHECK-NEXT:     ODDSPREG (0x1)
# CHECK-NEXT:   ]
# CHECK-NEXT:   Flags 2: 0x0
# CHECK-NEXT: }

--- !ELF
FileHeader:
  Class:   ELFCLASS64
  Data:    ELFDATA2MSB
  Type:    ET_REL
  Machine: [[MACHINE=EM_MIPS]]
Sections:
  - Name:         .MIPS.abiflags
    Type:         SHT_MIPS_ABIFLAGS
    AddressAlign: 8
    Version:      0
    ISA:          MIPS64
    ISARevision:  5
    ISAExtension: EXT_OCTEON3
    ASEs:         [ DSP, DSPR2, VIRT ]
    FpABI:        FP_DOUBLE
    GPRSize:      REG_64
    CPR1Size:     REG_64
    CPR2Size:     REG_NONE
    Flags1:       [ ODDSPREG ]
    Flags2:       0x0
    Content:     [[CONTENT=<none>]]
    Size:        [[SIZE=<none>]]

## Check we don't recognize the SHT_MIPS_ABIFLAGS section for non-MIPS targets.

# RUN: not yaml2obj %s -DMACHINE=EM_NONE 2>&1 | FileCheck %s --check-prefix=ERR

# ERR:      error: invalid hex32 number
# ERR-NEXT: Type: SHT_MIPS_ABIFLAGS

## Document we don't support the "Content" key yet.

# RUN: not yaml2obj %s -DCONTENT="'00'" 2>&1 | FileCheck %s --check-prefix=ERR-CONTENT

# ERR-CONTENT: error: "Content" key is not implemented for SHT_MIPS_ABIFLAGS section

## Document we don't support the "Size" key yet.

# RUN: not yaml2obj %s -DSIZE=0 2>&1 | FileCheck %s --check-prefix=ERR-SIZE

# ERR-SIZE: error: "Size" key is not implemented for SHT_MIPS_ABIFLAGS section