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
91 lines
3.4 KiB
LLVM
91 lines
3.4 KiB
LLVM
; REQUIRES: asserts
|
|
; Test workload based importing via -thinlto-pgo-ctx-prof with moving the whole
|
|
; graph to a new module.
|
|
; Use external linkage symbols so we don't depend on module paths which are
|
|
; used when computing the GUIDs of internal linkage symbols.
|
|
;
|
|
; Set up
|
|
; RUN: rm -rf %t
|
|
; RUN: mkdir -p %t
|
|
; RUN: split-file %s %t
|
|
;
|
|
; RUN: opt -module-summary -passes=assign-guid,ctx-instr-gen %t/m1.ll -o %t/m1.bc
|
|
; RUN: opt -module-summary -passes=assign-guid,ctx-instr-gen %t/m2.ll -o %t/m2.bc
|
|
; RUN: opt -module-summary -passes=assign-guid,ctx-instr-gen %t/m3.ll -o %t/m3.bc
|
|
; RUN: opt -module-summary -passes=assign-guid,ctx-instr-gen %t/6019442868614718803.ll -o %t/6019442868614718803.bc
|
|
|
|
; RUN: llvm-ctxprof-util fromYAML --input %t/ctxprof.yaml --output %t/ctxprof.bitstream
|
|
; RUN: llvm-lto2 run %t/m1.bc %t/m2.bc %t/m3.bc %t/6019442868614718803.bc -thinlto-move-ctxprof-trees \
|
|
; RUN: -o %t/result.o -save-temps \
|
|
; RUN: -use-ctx-profile=%t/ctxprof.bitstream \
|
|
; RUN: -r %t/m1.bc,m1_f1,plx \
|
|
; RUN: -r %t/m2.bc,m2_f1,plx \
|
|
; RUN: -r %t/m3.bc,m1_f1 \
|
|
; RUN: -r %t/m3.bc,m3_f1,plx -debug-only=function-import 2>&1 | FileCheck %s --check-prefix=ABSENT-MSG
|
|
|
|
; also add the move semantics for the root:
|
|
; RUN: llvm-lto2 run %t/m1.bc %t/m2.bc %t/m3.bc %t/6019442868614718803.bc -thinlto-move-ctxprof-trees \
|
|
; RUN: -thinlto-move-symbols=6019442868614718803 \
|
|
; RUN: -o %t/result-with-move.o -save-temps \
|
|
; RUN: -use-ctx-profile=%t/ctxprof.bitstream \
|
|
; RUN: -r %t/m1.bc,m1_f1,plx \
|
|
; RUN: -r %t/m2.bc,m2_f1,plx \
|
|
; RUN: -r %t/m3.bc,m1_f1 \
|
|
; RUN: -r %t/m3.bc,m3_f1,plx -debug-only=function-import 2>&1 | FileCheck %s --check-prefix=ABSENT-MSG
|
|
|
|
; RUN: llvm-dis %t/result.o.4.3.import.bc -o - | FileCheck %s
|
|
; RUN: llvm-dis %t/result.o.3.3.import.bc -o - | FileCheck %s --check-prefix=ABSENT
|
|
; RUN: llvm-dis %t/result-with-move.o.1.3.import.bc -o - | FileCheck %s --check-prefix=WITHMOVE-SRC
|
|
; RUN: llvm-dis %t/result-with-move.o.4.3.import.bc -o - | FileCheck %s --check-prefix=WITHMOVE-DEST
|
|
; RUN: llvm-dis %t/result.o.1.3.import.bc -o - | FileCheck %s --check-prefix=WITHOUTMOVE-SRC
|
|
;
|
|
; CHECK: define available_externally void @m1_f1()
|
|
; CHECK: define available_externally void @m2_f1()
|
|
; ABSENT: declare void @m1_f1()
|
|
; ABSENT-MSG: Skipping over 6019442868614718803 because its import is handled in a different module.
|
|
;
|
|
; WITHMOVE-SRC: declare dso_local void @m1_f1
|
|
; WITHMOVE-DEST: define dso_local void @m1_f1
|
|
; WITHOUTMOVE-SRC: define dso_local void @m1_f1
|
|
;--- ctxprof.yaml
|
|
Contexts:
|
|
-
|
|
Guid: 6019442868614718803
|
|
TotalRootEntryCount: 5
|
|
Counters: [1]
|
|
Callsites:
|
|
- -
|
|
Guid: 15593096274670919754
|
|
Counters: [1]
|
|
|
|
;--- m1.ll
|
|
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
|
|
target triple = "x86_64-pc-linux-gnu"
|
|
|
|
define dso_local void @m1_f1() {
|
|
ret void
|
|
}
|
|
|
|
;--- m2.ll
|
|
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
|
|
target triple = "x86_64-pc-linux-gnu"
|
|
|
|
define dso_local void @m2_f1() {
|
|
ret void
|
|
}
|
|
|
|
;--- m3.ll
|
|
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
|
|
target triple = "x86_64-pc-linux-gnu"
|
|
|
|
declare void @m1_f1()
|
|
|
|
define dso_local void @m3_f1() {
|
|
call void @m1_f1()
|
|
ret void
|
|
}
|
|
|
|
;--- 6019442868614718803.ll
|
|
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
|
|
target triple = "x86_64-pc-linux-gnu"
|