[llvm-dev] Does anything depend on reg2mem?
Russell Wallace via llvm-dev
llvm-dev at lists.llvm.org
Sun Jan 16 05:09:41 PST 2022
According to the documentation,
> This file demotes all registers to memory references. It is intended to
be the inverse of mem2reg. By converting to load instructions, the only
values live across basic blocks are alloca instructions and load
instructions before phi nodes. It is intended that this should make CFG
hacking much easier. To make later hacking easier, the entry block is split
into two, such that all introduced alloca instructions (and nothing else)
are in the entry block.
It does make sense that converting everything back to memory references,
would make CFG hacking easier. For example, simplifycfg would have an
easier job if it requires reg2mem to have been run first.
Does simplifycfg, or any other pass, actually have a 'reg2mem must have
been run first' dependency?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20220116/91ccdcb6/attachment.html>
More information about the llvm-dev
mailing list