Files
llvm-project/llvm/test/CodeGen/RISCV/thread-pointer.ll
Jianjian Guan 93f2deb1d0 [RISCV] Remove intrinsic declarations in tests, NFC (#167474)
As @mshockwave mentioned in
https://github.com/llvm/llvm-project/pull/156415, we don't need to
declare intrinsics in tests now, this pr removes them.
2025-11-26 17:25:07 +08:00

13 lines
377 B
LLVM

; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
; RUN: llc < %s -mtriple=riscv64 | FileCheck %s
; RUN: llc < %s -mtriple=riscv32 | FileCheck %s
define ptr @thread_pointer() nounwind {
; CHECK-LABEL: thread_pointer:
; CHECK: # %bb.0:
; CHECK-NEXT: mv a0, tp
; CHECK-NEXT: ret
%1 = tail call ptr @llvm.thread.pointer()
ret ptr %1
}