search for: build_class_tree

Displaying 2 results from an estimated 2 matches for "build_class_tree".

2008 Oct 08
1
[LLVMdev] Getting target machine specific information at run-time
...nfo* tri_; > const TargetInstrInfo * tii_; > [...] > bool RA::runOnMachineFunction(MachineFunction &fn) { > mf_ = &fn; > tm_ = &fn.getTarget(); > tri_ = tm_->getRegisterInfo(); > tii_ = tm_->getInstrInfo(); > > if (!initialized) { > build_class_tree(); > initialized = true; > > The "initialized" flag is there to make sure it only happens once per module. This solved my problem! Thanks! It was not obvious that the MachineFunctionPass objects are created only once per module. Therefore didn't use this trick right...
2008 Oct 07
2
[LLVMdev] Getting target machine specific information at run-time
Hi, I'm playing with some experimental register allocators for LLVM. One of them needs to build a so-called register class tree for representing the aliasing information among register classes. This tree is not function or module specific. It is actually target specific, because it depends only on the register classes defined for a machine that is used as a target of the current compilation.