llvm/llvm/test/Transforms/DCE/intrinsics-bpf.ll

; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 5
; RUN: opt -S < %s -passes=dce  | FileCheck %s

declare i64 @llvm.bpf.load.half(ptr, i64)
declare i64 @llvm.bpf.load.word(ptr, i64)
declare i64 @llvm.bpf.load.byte(ptr, i64)

define void @test_bpf_load_half(ptr %a, i64 %b) {
; CHECK-LABEL: define void @test_bpf_load_half(
; CHECK-SAME: ptr [[A:%.*]], i64 [[B:%.*]]) {
; CHECK-NEXT:    ret void
;
  %v = call i64 @llvm.bpf.load.half(ptr %a, i64 %b)
  ret void
}

define void @test_bpf_load_word(ptr %a, i64 %b) {
; CHECK-LABEL: define void @test_bpf_load_word(
; CHECK-SAME: ptr [[A:%.*]], i64 [[B:%.*]]) {
; CHECK-NEXT:    ret void
;
  %v = call i64 @llvm.bpf.load.word(ptr %a, i64 %b)
  ret void
}

define void @test_bpf_load_byte(ptr %a, i64 %b) {
; CHECK-LABEL: define void @test_bpf_load_byte(
; CHECK-SAME: ptr [[A:%.*]], i64 [[B:%.*]]) {
; CHECK-NEXT:    ret void
;
  %v = call i64 @llvm.bpf.load.byte(ptr %a, i64 %b)
  ret void
}