llvm.org GIT mirror llvm / 9c48837
Set DW_AT_APPLE_omit_frame_ptr in endFunction() where MachineFunction is available all the time. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@103001 91177308-0d34-0410-b5e6-96231b3b80d8 Devang Patel 10 years ago
2 changed file(s) with 40 addition(s) and 4 deletion(s). Raw diff Collapse all Expand all
13321332
13331333 if (SP.isOptimized())
13341334 addUInt(SPDie, dwarf::DW_AT_APPLE_optimized, dwarf::DW_FORM_flag, 1);
1335
1336 if (!DisableFramePointerElim(*Asm->MF))
1337 addUInt(SPDie, dwarf::DW_AT_APPLE_omit_frame_ptr, dwarf::DW_FORM_flag, 1);
13381335
13391336 // DW_TAG_inlined_subroutine may refer to this DIE.
13401337 ModuleCU->insertDIE(SP.getNode(), SPDie);
25322529 AE = AbstractScopesList.end(); AI != AE; ++AI)
25332530 constructScopeDIE(*AI);
25342531
2535 constructScopeDIE(CurrentFnDbgScope);
2532 DIE *CurFnDIE = constructScopeDIE(CurrentFnDbgScope);
25362533
2534 if (!DisableFramePointerElim(*MF))
2535 addUInt(CurFnDIE, dwarf::DW_AT_APPLE_omit_frame_ptr,
2536 dwarf::DW_FORM_flag, 1);
2537
2538
25372539 DebugFrames.push_back(FunctionDebugFrameInfo(Asm->getFunctionNumber(),
25382540 MMI->getFrameMoves()));
25392541 }
0 ; RUN: llc -o /dev/null -disable-non-leaf-fp-elim < %s
1 ; Radar 7937664
2 %struct.AppleEvent = type opaque
3
4 define void @DisposeDMNotificationUPP(void (%struct.AppleEvent*)* %userUPP) nounwind ssp {
5 entry:
6 %userUPP_addr = alloca void (%struct.AppleEvent*)* ; [#uses=1]
7 %"alloca point" = bitcast i32 0 to i32 ; [#uses=0]
8 call void @llvm.dbg.declare(metadata !{void (%struct.AppleEvent*)** %userUPP_addr}, metadata !0), !dbg !13
9 store void (%struct.AppleEvent*)* %userUPP, void (%struct.AppleEvent*)** %userUPP_addr
10 br label %return, !dbg !14
11
12 return: ; preds = %entry
13 ret void, !dbg !14
14 }
15
16 declare void @llvm.dbg.declare(metadata, metadata) nounwind readnone
17
18 !0 = metadata !{i32 524545, metadata !1, metadata !"userUPP", metadata !2, i32 7, metadata !6} ; [ DW_TAG_arg_variable ]
19 !1 = metadata !{i32 524334, i32 0, metadata !2, metadata !"DisposeDMNotificationUPP", metadata !"DisposeDMNotificationUPP", metadata !"DisposeDMNotificationUPP", metadata !2, i32 7, metadata !4, i1 false, i1 true, i32 0, i32 0, null, i1 false} ; [ DW_TAG_subprogram ]
20 !2 = metadata !{i32 524329, metadata !"t.c", metadata !"/Users/echeng/LLVM/radars/r7937664/", metadata !3} ; [ DW_TAG_file_type ]
21 !3 = metadata !{i32 524305, i32 0, i32 1, metadata !"t.c", metadata !"/Users/echeng/LLVM/radars/r7937664/", metadata !"4.2.1 (Based on Apple Inc. build 5658) (LLVM build 9999)", i1 true, i1 false, metadata !"", i32 0} ; [ DW_TAG_compile_unit ]
22 !4 = metadata !{i32 524309, metadata !2, metadata !"", metadata !2, i32 0, i64 0, i64 0, i64 0, i32 0, null, metadata !5, i32 0, null} ; [ DW_TAG_subroutine_type ]
23 !5 = metadata !{null, metadata !6}
24 !6 = metadata !{i32 524310, metadata !2, metadata !"DMNotificationUPP", metadata !2, i32 6, i64 0, i64 0, i64 0, i32 0, metadata !7} ; [ DW_TAG_typedef ]
25 !7 = metadata !{i32 524303, metadata !2, metadata !"", metadata !2, i32 0, i64 64, i64 64, i64 0, i32 0, metadata !8} ; [ DW_TAG_pointer_type ]
26 !8 = metadata !{i32 524309, metadata !2, metadata !"", metadata !2, i32 0, i64 0, i64 0, i64 0, i32 0, null, metadata !9, i32 0, null} ; [ DW_TAG_subroutine_type ]
27 !9 = metadata !{null, metadata !10}
28 !10 = metadata !{i32 524303, metadata !2, metadata !"", metadata !2, i32 0, i64 64, i64 64, i64 0, i32 0, metadata !11} ; [ DW_TAG_pointer_type ]
29 !11 = metadata !{i32 524310, metadata !2, metadata !"AppleEvent", metadata !2, i32 4, i64 0, i64 0, i64 0, i32 0, metadata !12} ; [ DW_TAG_typedef ]
30 !12 = metadata !{i32 524307, metadata !2, metadata !"AEDesc", metadata !2, i32 1, i64 0, i64 0, i64 0, i32 4, null, null, i32 0, null} ; [ DW_TAG_structure_type ]
31 !13 = metadata !{i32 7, i32 0, metadata !1, null}
32 !14 = metadata !{i32 8, i32 0, metadata !15, null}
33 !15 = metadata !{i32 524299, metadata !1, i32 7, i32 0} ; [ DW_TAG_lexical_block ]