HomePhabricator

[LoopIdiomRecognizePass] Options to disable part or the entire Loop Idiom…

Authored by anhtuyen on Sep 1 2020, 6:59 AM.

Description

[LoopIdiomRecognizePass] Options to disable part or the entire Loop Idiom Recognize Pass

Loop Idiom Recognize Pass (LIRP) attempts to transform loops with subscripted arrays
into memcpy/memset function calls. In some particular situation, this transformation
introduces negative impacts. For example: https://bugs.llvm.org/show_bug.cgi?id=47300

This patch will enable users to disable a particular part of the transformation, while
he/she can still enjoy the benefit brought about by the rest of LIRP. The default
behavior stays unchanged: no part of LIRP is disabled by default.

Reviewed By: etiotto (Ettore Tiotto)

Differential Revision: https://reviews.llvm.org/D86262