annotate lld/test/ELF/mips-64-gprel-so.s @ 192:d7606dcf6fce

Added tag llvm10 for changeset 0572611fdcc8
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Mon, 14 Dec 2020 18:01:34 +0900
parents 1d019706d866
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
150
anatofuz
parents:
diff changeset
1 # REQUIRES: mips
anatofuz
parents:
diff changeset
2 # Check setup of GP relative offsets in a function's prologue.
anatofuz
parents:
diff changeset
3
anatofuz
parents:
diff changeset
4 # RUN: llvm-mc -filetype=obj -triple=mips64-unknown-linux %s -o %t.o
anatofuz
parents:
diff changeset
5 # RUN: echo "SECTIONS { foo = 0x2000; _gp = 0x3000; }" > %t.script
anatofuz
parents:
diff changeset
6 # RUN: ld.lld %t.o --script %t.script -shared -o %t.so
anatofuz
parents:
diff changeset
7 # RUN: llvm-objdump -d -t --print-imm-hex --no-show-raw-insn %t.so | FileCheck %s
anatofuz
parents:
diff changeset
8
anatofuz
parents:
diff changeset
9 # CHECK: {{.*}} lui $gp, 0x0
anatofuz
parents:
diff changeset
10 # CHECK-NEXT: {{.*}} daddu $gp, $gp, $25
anatofuz
parents:
diff changeset
11 # CHECK-NEXT: {{.*}} daddiu $gp, $gp, 0x1000
anatofuz
parents:
diff changeset
12
anatofuz
parents:
diff changeset
13 .text
anatofuz
parents:
diff changeset
14 lui $gp,%hi(%neg(%gp_rel(foo)))
anatofuz
parents:
diff changeset
15 daddu $gp,$gp,$t9
anatofuz
parents:
diff changeset
16 daddiu $gp,$gp,%lo(%neg(%gp_rel(foo)))