[BOLT][NFC] Use colors in CFG dumps
authorAmir Ayupov <aaupov@fb.com>
Thu, 2 Jun 2022 07:26:23 +0000 (00:26 -0700)
committerAmir Ayupov <aaupov@fb.com>
Thu, 2 Jun 2022 07:27:12 +0000 (00:27 -0700)
commit6333e5dde9872ae56d7979432a76f83cf7ac6820
tree255ab558edbb7ef26ab4fad1a9c6075dbd15d89d
parentc6ad6901734f8fa7c1ecd3aeb7de651b07ab21a6
[BOLT][NFC] Use colors in CFG dumps

Use color coding to distinguish nodes:
- Entry nodes have bold border
- Scalar (non-loopy) code is milk white
- Outer loops are light yellow
- Innermost loops are light blue

`-print-loops` needs to be enabled to provide BinaryLoopInfo.
Examples:
{F23170673}
{F23170680}

Reviewed By: rafauler

Differential Revision: https://reviews.llvm.org/D126248
bolt/lib/Core/BinaryFunction.cpp
bolt/lib/Rewrite/RewriteInstance.cpp