[llvm-commits] [Review request] Tweaking Win64 Codegen

Jakob Stoklund Olesen stoklund at 2pi.dk
Thu Jan 13 21:29:59 PST 2011


On Jan 13, 2011, at 8:41 PM, NAKAMURA Takumi wrote:

> And I will show two new patches.
> (Other attached patches are regenerated. I saw merge in some point.)
> 
> * 0008-TableGen-PointerLikeRegClass-can-be-accepted-to-.patch.txt
> 
>  For example, it was invalid on ToT;
> 
>  def TCRETURNri64 : PseudoI<(outs),
>                      (ins ptr_rc_tailcall:$dst, i32imm:$offset,
> variable_ops), []>;
> 
>  When I looked into CodeGen, I got confidence I might let it valid, and I did.

Yes, that looks fine.

> * 0009-Target-X86-Tweak-win64-s-tailcall.patch.txt
> 
>  I got rid of instructions "TAIL****W64".
>  I can specify input register class with ptr_rc_tailcall,

Very nice!

>  but I wonder how to specify alternative Defs to instructions.
>  Let me know if there were a way without "custom expand".

Your custom inserter is correct, but I don't think it is necessary.

Since these are return instructions, there isn't going to be any live registers across them, and only the call arguments will be live into the return instructions.

That means it is OK to have too many registers in "Defs = [...]" for win64. You can just keep the lists as they are.

> Please take a look, thank you.

Your patches #8 and #9 look good to me.

/jakob

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 1929 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20110113/2f71bc3f/attachment.bin>


More information about the llvm-commits mailing list