This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Allow -fsanitize=thread without -pie


On 11/26/14 12:43, Jakub Jelinek wrote:
On Fri, Nov 21, 2014 at 04:20:44PM +0400, Dmitry Vyukov wrote:
Yes, I think it's the way to go.
I've just committed the following revision to clang that removes -pie
when compiling with tsan:
http://llvm.org/viewvc/llvm-project?view=revision&revision=222526
The tests in llvm tree pass with this change.

Ok, here it is.  I think -static still doesn't work, for static linking
symbols might not be interposed as libtsan wants, so I've changed it
to match what we do for -fsanitize=address.

Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk?

2014-11-26  Jakub Jelinek  <jakub@redhat.com>

	* gcc.c (SANITIZER_SPEC): Don't error on -fsanitize=thread
	without -pie or -shared, error on -fsanitize=thread -static instead.

	* lib/tsan-dg.exp (check_effective_target_fsanitize_thread,
	tsan_init): Don't use -fPIE or -pie.
OK.
jeff


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]