AVX support

We have been using LLVM 3.1 to support JITing of AVX. From dumping the MC generating by the MCJIT I noticed it always emits ‘VZEROUPPER’ to clear the high 128 bit before calling another function. In some cases I know the function called either only use AVX or does not use SSE. I will like to inform the backend it is safe not to emit that instruction.

Have not been able to figure out how to do that.

Any suggestion will be greatly appreciated.


I don't think there's any way at the moment. The relevant function is
VZeroUpperInserter::processBasicBlock; we could possibly special case
certain calls (maybe based on the calling convention?).