From 18af8d16cf71b75081f20184d34206ff4ebce025 Mon Sep 17 00:00:00 2001 From: Yury Gribov Date: Fri, 17 Apr 2015 07:51:02 +0000 Subject: asan.c (set_sanitized_sections): New function. 2015-04-17 Yury Gribov gcc/ * asan.c (set_sanitized_sections): New function. (section_sanitized_p): Ditto. (asan_protect_global): Optionally sanitize user-defined sections. * asan.h (set_sanitized_sections): Declare new function. * common.opt (fsanitize-sections): New option. * doc/invoke.texi (-fsanitize-sections): Document new option. * opts-global.c (handle_common_deferred_options): Handle new option. gcc/testsuite/ * c-c++-common/asan/user-section-1.c: New test. From-SVN: r222168 --- gcc/asan.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'gcc/asan.h') diff --git a/gcc/asan.h b/gcc/asan.h index 51fd9cc..10ffaca 100644 --- a/gcc/asan.h +++ b/gcc/asan.h @@ -79,6 +79,8 @@ asan_red_zone_size (unsigned int size) extern bool set_asan_shadow_offset (const char *); +extern void set_sanitized_sections (const char *); + /* Return TRUE if builtin with given FCODE will be intercepted by libasan. */ -- cgit v1.1