[PATCH] D43542: [CodeGen][FastRegAlloc] Disable registers spilling for a naked function (PR28641)

Matthias Braun via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jul 13 18:24:14 PDT 2018


MatzeB added a comment.

I think fastregalloc/-O0 isn't really expecting all liveness flags to be complete (unfortunately hard to tell/not written down).

In any case I'd tend to not add an instance of LiveVariables to the O0 pipeline just for this. I'd rather vote for some workaround code in fast regalloc to detect obviously dead defs (see above).

In https://reviews.llvm.org/D43542#1133722, @qcolombet wrote:

> Hi Konstantin,
>
> > We can add Live Variable Analysis pass prior of execution of Fast Register Allocator pass, but this will cause ~59 LIT tests to fail.
>
> IIRC we were trying to get rid of the Live Variable Analysis pass all together. Therefore, adding uses of this pass is not recommended.
>  That said, for O0 I don't know what would be the alternative.
>
> Anyway, if that pass does what we want, adding it at O0 works. Fixing LIT tests is fine.
>
> Cheers,
> -Quentin





https://reviews.llvm.org/D43542





More information about the llvm-commits mailing list