https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70773
Bug ID: 70773 Summary: Profiling makes sudoku solver slower Product: gcc Version: 5.3.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: gcov-profile Assignee: unassigned at gcc dot gnu.org Reporter: tulipawn at gmail dot com Target Milestone: --- Created attachment 38334 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=38334&action=edit .c, .i and .gcda files Compiling the attached sudoku solver the usual way and running the benchmark: $ gcc -O3 -Wall sudoku.c -o sudokuC $ time ./sudokuC 1>&2 > /dev/null takes 1.25s, whereas doing a profile build: $ gcc -O3 -Wall sudoku.c -o sudokuC -fprofile-generate $ time ./sudokuC 1>&2 > /dev/null $ gcc -O3 -Wall sudoku.c -o sudokuC -fprofile-use $ time ./sudokuC 1>&2 > /dev/null takes 1.5s which means it's 20% slower. Probably shouldn't happen.