mirror of
https://github.com/llvm/llvm-project.git
synced 2025-04-26 05:46:06 +00:00

Specify blocks order used in YAML profile. Needed to ensure profile backwards compatibility with pre-D155514 DFS order by default. Reviewed By: #bolt, maksfb Differential Revision: https://reviews.llvm.org/D156176
14 lines
556 B
C
14 lines
556 B
C
/* This test checks the handling of YAML profile with different block orders.
|
|
# RUN: %clang %cflags %s -o %t.exe
|
|
# RUN: link_fdata %s %t.exe %t.fdata
|
|
# RUN: llvm-bolt %t.exe -o /dev/null -data %t.fdata -w %t.yaml
|
|
# RUN: FileCheck %s --input-file %t.yaml --check-prefix=CHECK-BINARY
|
|
# CHECK-BINARY: dfs-order: false
|
|
# RUN: llvm-bolt %t.exe -o /dev/null -data %t.fdata -w %t.yaml --profile-use-dfs
|
|
# RUN: FileCheck %s --input-file %t.yaml --check-prefix=CHECK-DFS
|
|
# CHECK-DFS: dfs-order: true
|
|
|
|
# FDATA: 0 [unknown] 0 1 main 0 0 0
|
|
*/
|
|
int main() { return 0; }
|