Fix linker option for -fprofile-arcs -ftest-coverage
authorMarco Castelluccio <mcastelluccio@mozilla.com>
Tue, 27 Nov 2018 17:31:08 +0000 (17:31 +0000)
committerMarco Castelluccio <mcastelluccio@mozilla.com>
Tue, 27 Nov 2018 17:31:08 +0000 (17:31 +0000)
commit9123bfddd7a0aa5a1c4f6184d2f668e531e24c00
tree91cc4e7bc994863f8f9ab77f46c61b1ea0532cf5
parent1b2ead17d6292e6813f9a934f4f62d65f171964d
Fix linker option for -fprofile-arcs -ftest-coverage

Summary:
Linux toolchain accidentally added "-u__llvm_runtime_variable" when "-fprofile-arcs -ftest-coverage", this is not added when "--coverage" option is used.
Using "-u__llvm_runtime_variable" generates an empty default.profraw file while an application built with  "-fprofile-arcs -ftest-coverage" is running.

Reviewers: calixte, marco-c, sylvestre.ledru

Reviewed By: marco-c

Subscribers: vsk, cfe-commits

Differential Revision: https://reviews.llvm.org/D54195

llvm-svn: 347677
clang/lib/Driver/ToolChains/Linux.cpp
clang/test/Driver/clang_f_opts.c