strict aliasing warning in x86 land

/Volumes/mrs5/net/llvm/llvm/llvm/lib/Target/X86/X86ISelLowering.cpp: In member function 'llvm::SDOperand llvm::X86TargetLowering::LowerTRAMPOLINE(llvm::SDOperand, llvm::SelectionDAG&)':
/Volumes/mrs5/net/llvm/llvm/llvm/lib/Target/X86/X86ISelLowering.cpp:5305: warning: dereferencing type-punned pointer will break strict-aliasing rules

:frowning:

Can you please paste the line (line number 5305 isn't in LowerTRAMPOLINE
in my tree...).

Thanks,

Duncan.

You have to run svn update for it to have that line... :slight_smile:

     unsigned char N86Reg = ((X86RegisterInfo&)RegInfo).getX86RegNum(NestReg);

I've not thought long or hard about the validity of the warning... I'm hoping that it is accurate. Let me know if you think otherwise.

Yep, clearly bogus. Fixed:
http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20071210/056376.html

Thanks,

-Chris