summaryrefslogtreecommitdiff
path: root/test/CodeGen/PowerPC/pr24546.ll
diff options
context:
space:
mode:
authorPeter Collingbourne <peter@pcc.me.uk>2015-11-05 22:03:56 +0000
committerPeter Collingbourne <peter@pcc.me.uk>2015-11-05 22:03:56 +0000
commit5f220beefcb655de6aae7c80b456fd4e5cb76ac0 (patch)
treed478c6bd28ca4a860f194ccd49ec67aa8f6b062e /test/CodeGen/PowerPC/pr24546.ll
parentcc5dc01d7f7b6acdc7160fe30fda00e3b1b48687 (diff)
DI: Reverse direction of subprogram -> function edge.
Previously, subprograms contained a metadata reference to the function they described. Because most clients need to get or set a subprogram for a given function rather than the other way around, this created unneeded inefficiency. For example, many passes needed to call the function llvm::makeSubprogramMap() to build a mapping from functions to subprograms, and the IR linker needed to fix up function references in a way that caused quadratic complexity in the IR linking phase of LTO. This change reverses the direction of the edge by storing the subprogram as function-level metadata and removing DISubprogram's function field. Since this is an IR change, a bitcode upgrade has been provided. Fixes PR23367. An upgrade script for textual IR for out-of-tree clients is attached to the PR. Differential Revision: http://reviews.llvm.org/D14265 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@252219 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/PowerPC/pr24546.ll')
-rw-r--r--test/CodeGen/PowerPC/pr24546.ll4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/CodeGen/PowerPC/pr24546.ll b/test/CodeGen/PowerPC/pr24546.ll
index a04edfe65ea..06f6bc93da9 100644
--- a/test/CodeGen/PowerPC/pr24546.ll
+++ b/test/CodeGen/PowerPC/pr24546.ll
@@ -6,7 +6,7 @@
@php_intpow10.powers = external unnamed_addr constant [23 x double], align 8
; Function Attrs: nounwind
-define double @_php_math_round(double %value, i32 signext %places, i32 signext %mode) #0 {
+define double @_php_math_round(double %value, i32 signext %places, i32 signext %mode) #0 !dbg !6 {
entry:
br i1 undef, label %if.then, label %if.else, !dbg !32
@@ -62,7 +62,7 @@ attributes #3 = { nounwind }
!3 = !{!4}
!4 = !DIBasicType(name: "double", size: 64, align: 64, encoding: DW_ATE_float)
!5 = !{!6, !18}
-!6 = distinct !DISubprogram(name: "_php_math_round", scope: !1, file: !1, line: 15, type: !7, isLocal: false, isDefinition: true, scopeLine: 16, flags: DIFlagPrototyped, isOptimized: true, function: double (double, i32, i32)* @_php_math_round, variables: !10)
+!6 = distinct !DISubprogram(name: "_php_math_round", scope: !1, file: !1, line: 15, type: !7, isLocal: false, isDefinition: true, scopeLine: 16, flags: DIFlagPrototyped, isOptimized: true, variables: !10)
!7 = !DISubroutineType(types: !8)
!8 = !{!4, !4, !9, !9}
!9 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed)