[LLVMdev] LiveIntervals invalidates LiveVariables?

Tzu-Chien Chiu tzuchien.chiu at gmail.com
Wed Sep 7 03:24:20 PDT 2005

I though LiveVariables may be invalidated by LiveIntervals, but it's
declared not:

void LiveIntervals::getAnalysisUsage(AnalysisUsage &AU) const

LiveInterval may coalesce virtual registers and remove identity moves

bool LiveIntervals::runOnMachineFunction(MachineFunction &fn) {
  // perform a final pass over the instructions and compute spill
  // weights, coalesce virtual registers and remove identity moves

but the data structure LiveVariables::VirtRegInfo is _not_ updated.
That is, VarInfo::DefInstr may point to an invalid (being coalesced)

Tzu-Chien Chiu,
3D Graphics Hardware Architect

More information about the llvm-dev mailing list