https://gcc.gnu.org/bugzilla/show_bug.cgi?id=120670
Bug ID: 120670 Summary: vector_loop caused FAIL: go.test/test/fixedbugs/issue13160.go execution, -O2 -g Product: gcc Version: 16.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: target Assignee: unassigned at gcc dot gnu.org Reporter: hjl.tools at gmail dot com CC: hubicka at ucw dot cz, ubizjak at gmail dot com Target Milestone: --- Target: x86-64 Created attachment 61646 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=61646&action=edit A patch to use vector_loop On x86-64, enable vector_loop with diff --git a/gcc/config/i386/x86-tune-costs.h b/gcc/config/i386/x86-tune-costs.h index b08081e37cf..b3a7cb02157 100644 --- a/gcc/config/i386/x86-tune-costs.h +++ b/gcc/config/i386/x86-tune-costs.h @@ -4074,10 +4074,14 @@ static stringop_algs generic_memcpy[2] = { {libcall, {{32, loop, false}, {8192, rep_prefix_8_byte, false}, {-1, libcall, false}}}}; static stringop_algs generic_memset[2] = { - {libcall, {{32, loop, false}, {8192, rep_prefix_4_byte, false}, - {-1, libcall, false}}}, - {libcall, {{32, loop, false}, {8192, rep_prefix_8_byte, false}, - {-1, libcall, false}}}}; + {libcall, + {{256, vector_loop, true}, + {256, unrolled_loop, true}, + {-1, libcall, true}}}, + {libcall, + {{256, vector_loop, true}, + {256, unrolled_loop, true}, + {-1, libcall, true}}}}; static const struct processor_costs generic_cost = { { caused: FAIL: go.test/test/fixedbugs/issue13160.go execution, -O2 -g libgo.so.24 is miscompiled.