Can someone explain what this function is supposed to do? I've looked at PowerPC, Sparc, etc.. and can't really figure out what I should be doing here. Thanks, Micah Villmow Systems Engineer Advanced Technology & Performance Advanced Micro Devices Inc. 4555 Great America Pkwy, Santa Clara, CA. 95054 P: 408-572-6219 F: 408-572-6596 -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20081120/9a21725b/attachment.html>
On Thu, Nov 20, 2008 at 6:19 PM, Villmow, Micah <Micah.Villmow at amd.com> wrote:> Can someone explain what this function is supposed to do? I've looked at > PowerPC, Sparc, etc.. and can't really figure out what I should be doing > here. >Here's what the comment in X86/X86ISelLowering.h has to say: /// computeMaskedBitsForTargetNode - Determine which of the bits specified /// in Mask are known to be either zero or one and return them in the /// KnownZero/KnownOne bitsets. -bw
On Thu, Nov 20, 2008 at 6:19 PM, Villmow, Micah <Micah.Villmow at amd.com> wrote:> Can someone explain what this function is supposed to do? I've looked at > PowerPC, Sparc, etc.. and can't really figure out what I should be doing > here.It's an optimization: it allows the target-independent passes like DAGCombine to get information about which bits of a value are known at compile-time to be set or known to be unset. The conservative assumption is that nothing is known, so the default implementation is always correct. -Eli
Possibly Parallel Threads
- [LLVMdev] Determining the register type of a MachineOperand
- [LLVMdev] Determining the names of all the functions in a module
- [LLVMdev] 32 bit boolean results
- [LLVMdev] Going from argument to register and back
- [LLVMdev] Virtual Register allocation across functions