[PATCH] D17429: Don't mark convergent instructions as trivially rematerializable.

Owen Anderson via llvm-commits llvm-commits at lists.llvm.org
Thu Feb 18 20:20:08 PST 2016


My targets have convergent instructions that are rematerializable.

—Owen

> On Feb 18, 2016, at 5:48 PM, Justin Lebar via llvm-commits <llvm-commits at lists.llvm.org> wrote:
> 
> jlebar created this revision.
> jlebar added a reviewer: echristo.
> jlebar added subscribers: tra, llvm-commits.
> 
> No testcase, as all convergent MIs I'm aware of already have unmodeled
> side-effects, which is sufficient.
> 
> http://reviews.llvm.org/D17429
> 
> Files:
>  lib/CodeGen/TargetInstrInfo.cpp
> 
> Index: lib/CodeGen/TargetInstrInfo.cpp
> ===================================================================
> --- lib/CodeGen/TargetInstrInfo.cpp
> +++ lib/CodeGen/TargetInstrInfo.cpp
> @@ -846,7 +846,7 @@
> 
>   // Avoid instructions obviously unsafe for remat.
>   if (MI->isNotDuplicable() || MI->mayStore() ||
> -      MI->hasUnmodeledSideEffects())
> +      MI->hasUnmodeledSideEffects() || MI->isConvergent())
>     return false;
> 
>   // Don't remat inline asm. We have no idea how expensive it is
> 
> 
> <D17429.48440.patch>_______________________________________________
> llvm-commits mailing list
> llvm-commits at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits



More information about the llvm-commits mailing list