HomePhabricator

[PowerPC] Materialize i64 constants by enumerated patterns.

Authored by Esme on Dec 20 2020, 9:21 PM.

Description

[PowerPC] Materialize i64 constants by enumerated patterns.

Summary: Some constants can be handled with less instructions than our current results. And it seems our original approach is not very easy to extend. Therefore this patch proposes to materialize all 64-bit constants by enumerated patterns.
I traversed almost all constants to verified the functionality of these pattens. A traversed comparison of the number of instructions used by the original method and the new method has also been completed, where no degradation was caused by this patch. This patch also passed Bootstrap test and SPEC test.
Improvements of this patch are shown in llvm/test/CodeGen/PowerPC/constants-i64.ll

Reviewed By: steven.zhang, stefanp

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

Details

Committed
EsmeDec 20 2020, 9:21 PM
Reviewer
steven.zhang
Differential Revision
D92089: [PowerPC] Materialize i64 constants by enumerated patterns.
Parents
rGe4c360a897fe: [MC][ELF] Drop MCSymbol::isExternal call sites
Branches
Unknown
Tags
Unknown