Arvind Sankar 33d0f96ffd lib/string.c: Use freestanding environment
gcc can transform the loop in a naive implementation of memset/memcpy
etc into a call to the function itself.  This optimization is enabled by
-ftree-loop-distribute-patterns.

This has been the case for a while, but gcc-10.x enables this option at
-O2 rather than -O3 as in previous versions.

Add -ffreestanding, which implicitly disables this optimization with
gcc.  It is unclear whether clang performs such optimizations, but
hopefully it will also not do so in a freestanding environment.

Signed-off-by: Arvind Sankar <nivedita@alum.mit.edu>
Link: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=56888
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2020-08-19 11:23:45 -07:00
..
2020-08-09 14:10:26 -07:00
2020-08-14 19:56:56 -07:00
2020-05-24 20:48:11 +02:00
2018-08-16 12:14:42 -07:00
2020-06-01 08:23:42 -04:00
2014-04-30 19:49:37 +01:00
2017-02-24 17:46:57 -08:00
2020-05-07 14:54:26 +08:00
2018-10-16 13:45:44 +02:00
2020-06-15 18:22:43 -07:00
2019-07-11 15:17:41 -07:00
2018-06-27 18:58:49 +03:00
2020-06-29 10:02:23 +02:00
2018-10-15 16:31:29 -04:00
2020-06-07 10:53:36 -07:00
2020-06-09 10:03:12 -07:00
2020-06-04 19:06:28 -07:00