xref: /llvm-project/llvm/test/CodeGen/Mips/rdhwr-directives.ll (revision 8663926a544602932d299dda435ed1ef70a05f48)
1; RUN: llc -mtriple=mipsel -mcpu=mips32 -relocation-model=static < %s | FileCheck %s
2
3@a = external thread_local global i32
4
5define i32 @foo() nounwind readonly {
6entry:
7; CHECK: .set  push
8; CHECK: .set  mips32r2
9; CHECK: rdhwr
10; CHECK: .set  pop
11
12  %0 = load i32, ptr @a, align 4
13  ret i32 %0
14}
15
16