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
97 lines
2.8 KiB
LLVM
97 lines
2.8 KiB
LLVM
; Check that the JSON output from DTLTO is as expected. Note that validate.py
|
|
; checks the JSON structure so we just check the field contents in this test.
|
|
|
|
RUN: rm -rf %t && split-file %s %t && cd %t
|
|
|
|
; Generate bitcode files with summary.
|
|
RUN: opt -thinlto-bc t1.ll -o t1.bc
|
|
RUN: opt -thinlto-bc t2.ll -o t2.bc
|
|
|
|
; Perform DTLTO with clang.
|
|
RUN: not llvm-lto2 run t1.bc t2.bc -o my.output \
|
|
RUN: -r=t1.bc,t1,px -r=t2.bc,t2,px \
|
|
RUN: -dtlto-distributor=%python \
|
|
RUN: -dtlto-distributor-arg=%llvm_src_root/utils/dtlto/validate.py,--da1=10,--da2=10 \
|
|
RUN: -dtlto-compiler=my_clang.exe \
|
|
RUN: -dtlto-compiler-arg=--rota1=10,--rota2=20 \
|
|
RUN: 2>&1 | FileCheck --check-prefixes=CHECK,CLANG %s
|
|
|
|
; Perform DTLTO with LLVM driver.
|
|
RUN: not llvm-lto2 run t1.bc t2.bc -o my.output \
|
|
RUN: -r=t1.bc,t1,px -r=t2.bc,t2,px \
|
|
RUN: -dtlto-distributor=%python \
|
|
RUN: -dtlto-distributor-arg=%llvm_src_root/utils/dtlto/validate.py,--da1=10,--da2=10 \
|
|
RUN: -dtlto-compiler=llvm \
|
|
RUN: -dtlto-compiler-prepend-arg=clang \
|
|
RUN: -dtlto-compiler-arg=--rota1=10,--rota2=20 \
|
|
RUN: 2>&1 | FileCheck --check-prefixes=CHECK,LLVM %s
|
|
|
|
CHECK: distributor_args=['--da1=10', '--da2=10']
|
|
|
|
; Check the common object.
|
|
CHECK: "linker_output": "my.output"
|
|
CHECK: "args":
|
|
CLANG-NEXT: "my_clang.exe"
|
|
LLVM-NEXT: "llvm"
|
|
LLVM-NEXT: "clang"
|
|
CHECK-NEXT: "-c"
|
|
CHECK-NEXT: "--target=x86_64-unknown-linux-gnu"
|
|
CHECK-NEXT: "-O2"
|
|
CHECK-NEXT: "-fpic"
|
|
CHECK-NEXT: "-Wno-unused-command-line-argument"
|
|
CHECK-NEXT: "--rota1=10"
|
|
CHECK-NEXT: "--rota2=20"
|
|
CHECK-NEXT: ]
|
|
CHECK: "inputs": []
|
|
|
|
; Check the first job entry.
|
|
CHECK: "args":
|
|
CHECK-NEXT: "t1.bc"
|
|
CHECK-NEXT: "-fthinlto-index=t1.1.[[#]].native.o.thinlto.bc"
|
|
CHECK-NEXT: "-o"
|
|
CHECK-NEXT: "t1.1.[[#]].native.o"
|
|
CHECK-NEXT: ]
|
|
CHECK: "inputs": [
|
|
CHECK-NEXT: "t1.bc"
|
|
CHECK-NEXT: "t1.1.[[#]].native.o.thinlto.bc"
|
|
CHECK-NEXT: ]
|
|
CHECK: "outputs": [
|
|
CHECK-NEXT: "t1.1.[[#]].native.o"
|
|
CHECK-NEXT: ]
|
|
|
|
; Check the second job entry.
|
|
CHECK: "args": [
|
|
CHECK-NEXT: "t2.bc"
|
|
CHECK-NEXT: "-fthinlto-index=t2.2.[[#]].native.o.thinlto.bc"
|
|
CHECK-NEXT: "-o"
|
|
CHECK-NEXT: "t2.2.[[#]].native.o"
|
|
CHECK-NEXT: ]
|
|
CHECK-NEXT: "inputs": [
|
|
CHECK-NEXT: "t2.bc"
|
|
CHECK-NEXT: "t2.2.[[#]].native.o.thinlto.bc"
|
|
CHECK-NEXT: ]
|
|
CHECK-NEXT: "outputs": [
|
|
CHECK-NEXT: "t2.2.[[#]].native.o"
|
|
CHECK-NEXT: ]
|
|
|
|
; This check ensures that we have failed for the expected reason.
|
|
CHECK: failed: DTLTO backend compilation: cannot open native object file:
|
|
|
|
;--- t1.ll
|
|
target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
|
|
target triple = "x86_64-unknown-linux-gnu"
|
|
|
|
define void @t1() {
|
|
entry:
|
|
ret void
|
|
}
|
|
|
|
;--- t2.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-unknown-linux-gnu"
|
|
|
|
define void @t2() {
|
|
entry:
|
|
ret void
|
|
}
|