[PATCH] D31262: MIParser/MIRPrinter: Compute block successors if not explicitely specified

Matthias Braun via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 22 14:39:05 PDT 2017


MatzeB created this revision.
Herald added a subscriber: mcrosier.

- MIParser: If the successor list is not specified successors will be added based on basic block operands in the block and possible fallthrough.
- MIRPrinter: Skip printing of block successor lists in cases where the parser is guaranteed to reconstruct it. This means we still print the list if some successor cannot be determined (happens for example for jump tables), if the successor order changes or branch probabilities being unequal.


Repository:
  rL LLVM

https://reviews.llvm.org/D31262

Files:
  lib/CodeGen/MIRParser/MIParser.cpp
  lib/CodeGen/MIRPrinter.cpp
  lib/CodeGen/MIRPrinter.h
  test/CodeGen/MIR/X86/auto-successor.mir
  test/CodeGen/MIR/X86/newline-handling.mir
  test/CodeGen/MIR/X86/successor-basic-blocks.mir

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D31262.92714.patch
Type: text/x-patch
Size: 11174 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170322/20fc48ad/attachment.bin>


More information about the llvm-commits mailing list