https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93130
Bug ID: 93130 Summary: PCC simple memset not inlined Product: gcc Version: 8.3.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: target Assignee: unassigned at gcc dot gnu.org Reporter: jens.seifert at de dot ibm.com Target Milestone: --- Input: void memspace16(char *p) { memset(p, ' ', 16); } Expected result: li 4,0x2020 rldimi 4,4,16,0 rldimi 4,4,32,0 std 4,0(3) Splatting the memset input to 64-bit can be done using li + 2xrldimi. But also ._Z13memspace16OptPc: LFB..3: lis 9,0x2020 ori 9,9,0x2020 sldi 9,9,32 oris 9,9,0x2020 ori 9,9,0x2020 std 9,0(3) std 9,8(3) blr would perform better than the function call to memset.