Files
TheRock/compiler/amd-llvm/llvm/test/Transforms/MetaRenamer/exclude-names.ll
T
derek.holloway 7502bf64a4
CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
Flatten subprojects into a single base monorepo
2026-09-02 16:34:47 -07:00

59 lines
1.9 KiB
LLVM

; RUN: opt -passes=metarenamer -rename-exclude-function-prefixes=my_func -rename-exclude-global-prefixes=my_global -rename-exclude-struct-prefixes=my_struct -rename-exclude-alias-prefixes=my_alias -S %s | FileCheck %s
; Check that excluded names don't get renamed while all the other ones do
; CHECK: %my_struct1 = type { ptr, i32 }
; CHECK: %my_struct2 = type { ptr, i32 }
; CHECK-NOT: %other_struct = type { ptr, i32 }
; CHECK: @my_global1 = global i32 42
; CHECK: @my_global2 = global i32 24
; CHECK-NOT: @other_global = global i32 24
; CHECK: @my_alias1 = alias i32, ptr @my_global1
; CHECK: @my_alias2 = alias i32, ptr @my_global2
; CHECK-NOT: @other_alias = alias i32, ptr @other_global
; CHECK: declare void @my_func1
; CHECK: declare void @my_func2
; CHECK-NOT: declare void @other_func
; CHECK: call void @my_func1
; CHECK: call void @my_func2
; CHECK-NOT: call void @other_func
; CHECK: load i32, ptr @my_global1
; CHECK: load i32, ptr @my_global2
; CHECK-NOT: load i32, ptr @other_global
; CHECK: load i32, ptr @my_alias1
; CHECK: load i32, ptr @my_alias2
; CHECK-NOT: load i32, ptr @other_alias
; CHECK: alloca %my_struct1
; CHECK: alloca %my_struct2
; CHECK-NOT: alloca %other_struct
%my_struct1 = type { ptr, i32 }
%my_struct2 = type { ptr, i32 }
%other_struct = type { ptr, i32 }
@my_global1 = global i32 42
@my_global2 = global i32 24
@other_global = global i32 24
@my_alias1 = alias i32, ptr @my_global1
@my_alias2 = alias i32, ptr @my_global2
@other_alias = alias i32, ptr @other_global
declare void @my_func1()
declare void @my_func2()
declare void @other_func()
define void @some_func() {
call void @my_func1()
call void @my_func2()
call void @other_func()
%a = load i32, ptr @my_global1
%b = load i32, ptr @my_global2
%c = load i32, ptr @other_global
%d = load i32, ptr @my_alias1
%e = load i32, ptr @my_alias2
%f = load i32, ptr @other_alias
%g = alloca %my_struct1
%h = alloca %my_struct2
%i = alloca %other_struct
ret void
}