xref: /linux/arch/riscv/kernel/tests/module_test/test_sub16.S (revision e7d759f31ca295d589f7420719c311870bb3166f)
1/* SPDX-License-Identifier: GPL-2.0 */
2/*
3 * Copyright (C) 2023 Rivos Inc.
4 */
5
6.text
7.global test_sub16
8test_sub16:
9	lh	a0, sub16
10	addi	a0, a0, -32
11	ret
12first:
13	.space 32
14second:
15
16.data
17sub16:
18	.reloc		sub16, R_RISCV_ADD16, second
19	.reloc		sub16, R_RISCV_SUB16, first
20	.half		0
21