[gcov] Add __gcov_dump/__gcov_reset and delete __gcov_flush
authorFangrui Song <i@maskray.me>
Sat, 18 Jul 2020 22:07:46 +0000 (15:07 -0700)
committerFangrui Song <i@maskray.me>
Sat, 18 Jul 2020 22:07:46 +0000 (15:07 -0700)
commit5809a32e7c2d79a9a463eb9c15cde994b42e3002
tree4aeba29cd878d9c4c14c60bf7942516cee9a3d17
parent6a25838be6a0b242443320559cf1f97f466c59cc
[gcov] Add __gcov_dump/__gcov_reset and delete __gcov_flush

GCC r187297 (2012-05) introduced `__gcov_dump` and `__gcov_reset`.
  `__gcov_flush = __gcov_dump + __gcov_reset`

The resolution to https://gcc.gnu.org/PR93623 ("No need to dump gcdas when forking" target GCC 11.0) removed the unuseful and undocumented __gcov_flush.

Close PR38064.

Reviewed By: calixte, serge-sans-paille

Differential Revision: https://reviews.llvm.org/D83149
clang/lib/Driver/ToolChains/Darwin.cpp
clang/test/CodeGen/code-coverage.c
clang/test/Driver/darwin-ld.c
compiler-rt/lib/profile/GCDAProfiling.c
compiler-rt/test/profile/Inputs/instrprof-dlopen-dlclose-main.c
compiler-rt/test/profile/Posix/gcov-dlopen.c
compiler-rt/test/profile/Posix/gcov-shared-flush.c
compiler-rt/test/profile/gcov-__gcov_flush-terminate.c
compiler-rt/test/profile/gcov-dump-and-remove.c
llvm/lib/Transforms/Instrumentation/GCOVProfiling.cpp