[llvm-dev] IR question re: constants

via llvm-dev llvm-dev at lists.llvm.org
Wed Sep 2 11:16:58 PDT 2015


I'm curious.  Is there a specific technical reason that the high-level
IR doesn't have an instruction to simply set a register to a constant?
This limitation means we cannot hoist an "expensive" constant out of a
loop until we lower the IR to MachineInstrs.  Or more to the point, it
forces backends to undo any such hoisting done by frontends.

Or am I not understanding something?

                           -David


More information about the llvm-dev mailing list