Mehdi Amini | ae64eaf | 2016-04-23 23:38:17 +0000 | [diff] [blame] | 1 | ; Test to check the callgraph in summary |
| 2 | ; RUN: opt -module-summary %s -o %t.o |
| 3 | ; RUN: llvm-lto -thinlto-action=thinlink -o %t.index.bc %t.o |
| 4 | ; RUN: llvm-bcanalyzer -dump %t.index.bc | FileCheck %s --check-prefix=COMBINED |
| 5 | |
| 6 | ; COMBINED: <GLOBALVAL_SUMMARY_BLOCK |
Mehdi Amini | 02fa652 | 2016-04-24 00:25:15 +0000 | [diff] [blame^] | 7 | ; COMBINED-DAG: <COMBINED |
| 8 | ; COMBINED-DAG: <COMBINED_ORIGINAL_NAME op0=6699318081062747564/> |
| 9 | ; COMBINED-DAG: <COMBINED_GLOBALVAR_INIT_REFS |
| 10 | ; COMBINED-DAG: <COMBINED_ORIGINAL_NAME op0=-2012135647395072713/> |
| 11 | ; COMBINED-DAG: <COMBINED_ALIAS |
| 12 | ; COMBINED-DAG: <COMBINED_ORIGINAL_NAME op0=-4170563161550796836/> |
Mehdi Amini | ae64eaf | 2016-04-23 23:38:17 +0000 | [diff] [blame] | 13 | ; COMBINED-NEXT: </GLOBALVAL_SUMMARY_BLOCK> |
Mehdi Amini | 363d83f | 2016-04-24 00:03:57 +0000 | [diff] [blame] | 14 | ; COMBINED-NEXT: <VALUE_SYMTAB |
| 15 | ; COMBINED-NEXT: <COMBINED_GVDEFENTRY {{.*}} op2=4947176790635855146/> |
| 16 | ; COMBINED-NEXT: <COMBINED_GVDEFENTRY {{.*}} op2=-6591587165810580810/> |
| 17 | ; COMBINED-NEXT: <COMBINED_GVDEFENTRY {{.*}} op2=-4377693495213223786/> |
| 18 | ; COMBINED-NEXT: </VALUE_SYMTAB> |
| 19 | |
| 20 | source_filename = "/path/to/source.c" |
Mehdi Amini | ae64eaf | 2016-04-23 23:38:17 +0000 | [diff] [blame] | 21 | |
| 22 | ; ModuleID = 'thinlto-function-summary-callgraph.ll' |
| 23 | target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128" |
| 24 | target triple = "x86_64-unknown-linux-gnu" |
| 25 | |
| 26 | @bar = internal global i32 0 |
| 27 | @fooalias = internal alias void (...), bitcast (void ()* @foo to void (...)*) |
| 28 | |
| 29 | define internal void @foo() { |
| 30 | ret void |
| 31 | } |