[PATCH] D35844: Correct dwarf unwind information in function epilogue

Violeta Vukobrat via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 3 08:47:58 PDT 2017


violetav updated this revision to Diff 117536.
violetav added a comment.

Here is the new patch written based on the comments received and the previously implemented solution.
What is changed:

- Removed all changes from MachineBasicBlock.
- Removed changes related to updating in/out CFI information from common passes (BranchFolding.cpp and TailDuplicator.cpp).
- Merged CFIInfoVerifier and CFIInstrInserter into one pass that now calculates in/out CFI info for BBs, verifies it and inserts additional CFI instructions if needed. This pass isn't added in TargetPassConfig.cpp if the target does not maintain CFA info.

These are the tests that still haven't been updated (and that currently fail with this patch):

O0-pipeline.ll
avx512vl-vec-masked-cmp.ll
cmp.ll
frame-lowering-debug-intrinsic-2.ll
mul-constant-result.ll
pr29061.ll
pr34088.ll
select-mmx.ll
x86-interleaved-access.ll

They need to have appropriate .cfi directives added.
I will add these changes when this patch gets approved.


Repository:
  rL LLVM

https://reviews.llvm.org/D35844

Files:
  include/llvm/CodeGen/MachineInstr.h
  include/llvm/CodeGen/Passes.h
  include/llvm/InitializePasses.h
  include/llvm/Target/Target.td
  include/llvm/Target/TargetFrameLowering.h
  include/llvm/Target/TargetMachine.h
  lib/CodeGen/BranchFolding.cpp
  lib/CodeGen/CFIInstrInserter.cpp
  lib/CodeGen/CMakeLists.txt
  lib/CodeGen/CodeGen.cpp
  lib/CodeGen/MachineInstr.cpp
  lib/CodeGen/TailDuplicator.cpp
  lib/CodeGen/TargetFrameLoweringImpl.cpp
  lib/CodeGen/TargetPassConfig.cpp
  lib/Target/X86/X86FrameLowering.cpp
  lib/Target/X86/X86FrameLowering.h
  lib/Target/X86/X86TargetMachine.cpp
  lib/Target/X86/X86TargetMachine.h
  test/CodeGen/X86/2009-03-16-PHIElimInLPad.ll
  test/CodeGen/X86/2011-10-19-widen_vselect.ll
  test/CodeGen/X86/GlobalISel/add-scalar.ll
  test/CodeGen/X86/GlobalISel/brcond.ll
  test/CodeGen/X86/GlobalISel/callingconv.ll
  test/CodeGen/X86/GlobalISel/frameIndex.ll
  test/CodeGen/X86/TruncAssertZext.ll
  test/CodeGen/X86/avx512-schedule.ll
  test/CodeGen/X86/avx512-select.ll
  test/CodeGen/X86/avx512-vbroadcast.ll
  test/CodeGen/X86/avx512bw-intrinsics-fast-isel.ll
  test/CodeGen/X86/avx512bw-intrinsics-upgrade.ll
  test/CodeGen/X86/avx512bw-intrinsics.ll
  test/CodeGen/X86/avx512vl-intrinsics-fast-isel.ll
  test/CodeGen/X86/avx512vl-vbroadcast.ll
  test/CodeGen/X86/bitcast-and-setcc-512.ll
  test/CodeGen/X86/bitcast-int-to-vector-bool-zext.ll
  test/CodeGen/X86/bitcast-setcc-512.ll
  test/CodeGen/X86/emutls-pie.ll
  test/CodeGen/X86/emutls.ll
  test/CodeGen/X86/epilogue-cfi-fp.ll
  test/CodeGen/X86/epilogue-cfi-no-fp.ll
  test/CodeGen/X86/fast-isel-store.ll
  test/CodeGen/X86/frame-lowering-debug-intrinsic.ll
  test/CodeGen/X86/haddsub-2.ll
  test/CodeGen/X86/hipe-cc64.ll
  test/CodeGen/X86/illegal-bitfield-loadstore.ll
  test/CodeGen/X86/imul.ll
  test/CodeGen/X86/lea-opt-cse1.ll
  test/CodeGen/X86/lea-opt-cse2.ll
  test/CodeGen/X86/lea-opt-cse3.ll
  test/CodeGen/X86/lea-opt-cse4.ll
  test/CodeGen/X86/legalize-shift-64.ll
  test/CodeGen/X86/live-out-reg-info.ll
  test/CodeGen/X86/load-combine.ll
  test/CodeGen/X86/masked_gather_scatter.ll
  test/CodeGen/X86/memset-nonzero.ll
  test/CodeGen/X86/merge-consecutive-loads-128.ll
  test/CodeGen/X86/movtopush.ll
  test/CodeGen/X86/mul-i256.ll
  test/CodeGen/X86/pr21792.ll
  test/CodeGen/X86/pr29112.ll
  test/CodeGen/X86/pr30430.ll
  test/CodeGen/X86/pr32241.ll
  test/CodeGen/X86/pr32256.ll
  test/CodeGen/X86/pr32282.ll
  test/CodeGen/X86/pr32329.ll
  test/CodeGen/X86/pr32345.ll
  test/CodeGen/X86/pr32451.ll
  test/CodeGen/X86/pr9743.ll
  test/CodeGen/X86/push-cfi-debug.ll
  test/CodeGen/X86/push-cfi-obj.ll
  test/CodeGen/X86/push-cfi.ll
  test/CodeGen/X86/return-ext.ll
  test/CodeGen/X86/rtm.ll
  test/CodeGen/X86/setcc-lowering.ll
  test/CodeGen/X86/statepoint-call-lowering.ll
  test/CodeGen/X86/statepoint-gctransition-call-lowering.ll
  test/CodeGen/X86/statepoint-invoke.ll
  test/CodeGen/X86/throws-cfi-fp.ll
  test/CodeGen/X86/throws-cfi-no-fp.ll
  test/CodeGen/X86/vector-sext.ll
  test/CodeGen/X86/vector-shuffle-avx512.ll
  test/CodeGen/X86/vector-shuffle-v1.ll
  test/CodeGen/X86/wide-integer-cmp.ll
  test/CodeGen/X86/x86-framelowering-trap.ll
  test/CodeGen/X86/x86-no_caller_saved_registers-preserve.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D35844.117536.patch
Type: text/x-patch
Size: 146004 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20171003/45b098b1/attachment-0001.bin>


More information about the llvm-commits mailing list