From patchwork Thu Oct 22 16:45:21 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: max X-Patchwork-Id: 534490 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 2C4B7141322 for ; Fri, 23 Oct 2015 03:45:37 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b=lne/p6VR; dkim-atps=neutral DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :subject:to:cc:message-id:date:mime-version:content-type; q=dns; s=default; b=vr1kNqmCDtjfZBhCELZkh9g8Z5ZmO+WVayMezFx5AOhgpcKEsR gcIW0DGkAGZRRVV01hHzpKiZi+IC/H0UOuJU4DYPVzCM9RZ3eG0o927wxAtFCKGf UqoZS3WUMsx4xvxGevjmKICTgdRLTD1XFA9SXzQb9wfIZ8VXUljuTbEOM= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :subject:to:cc:message-id:date:mime-version:content-type; s= default; bh=sBEdAUzM5izk2ZFO12qZ3Rzztuo=; b=lne/p6VR1mq4d4DVCpFq 81avbeZgl0JoSXe7blmBpDeyxzTmP9OcR42WYyp5qYBMI0FJYGTbw8vIVg7OXzT9 vcwnnjX0YbqqFjnbUJGpRFRs3e0VtYs7xP7yPQAYH8zJsbyUAFn37mTILKQeJehE CkfM+/yIiQugO0KDgj7pLog= Received: (qmail 79832 invoked by alias); 22 Oct 2015 16:45:28 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 79815 invoked by uid 89); 22 Oct 2015 16:45:28 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=0.9 required=5.0 tests=AWL, BAYES_00, KAM_ASCII_DIVIDERS, KAM_LAZY_DOMAIN_SECURITY, RP_MATCHES_RCVD, SPF_HELO_PASS, T_HDRS_LCASE, T_MANY_HDRS_LCASE, UNWANTED_LANGUAGE_BODY autolearn=no version=3.3.2 X-HELO: mailout1.w1.samsung.com Received: from mailout1.w1.samsung.com (HELO mailout1.w1.samsung.com) (210.118.77.11) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-SHA encrypted) ESMTPS; Thu, 22 Oct 2015 16:45:26 +0000 Received: from eucpsbgm1.samsung.com (unknown [203.254.199.244]) by mailout1.w1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTP id <0NWM009B4RVMO870@mailout1.w1.samsung.com> for gcc-patches@gcc.gnu.org; Thu, 22 Oct 2015 17:45:22 +0100 (BST) Received: from eusync2.samsung.com ( [203.254.199.212]) by eucpsbgm1.samsung.com (EUCPMTA) with SMTP id B2.BC.04846.1A219265; Thu, 22 Oct 2015 17:45:21 +0100 (BST) Received: from [106.109.128.167] by eusync2.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0NWM006RFRVLEN60@eusync2.samsung.com>; Thu, 22 Oct 2015 17:45:21 +0100 (BST) From: Maxim Ostapenko Subject: [PATCH] Fix sanitizer/68042 To: GCC Patches Cc: Dominique Dhumieres Message-id: <562912A1.8080104@partner.samsung.com> Date: Thu, 22 Oct 2015 19:45:21 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.2.0 MIME-version: 1.0 Content-type: multipart/mixed; boundary=------------000602070607020001070101 X-IsSubscribed: yes Hi, currently we have memcmp-1.c and sanity-check-pure-c-1.c (ASan testsuite) output pattern test failures on x86_64-apple-darwin14. This patch adjusts their expecting patterns to match real ones. Tested by me on x86_64-unknown-linux-gnu and by Dominique on x86_64-apple-darwin14. Ok to apply? -Maxim gcc/testsuite/ChangeLog: 2015-10-22 Maxim Ostapenko PR sanitizer/68042 * c-c++-common/asan/memcmp-1.c: Adjust test to pass on Darwin. * c-c++-common/asan/sanity-check-pure-c-1.c: Likewise. Index: gcc/testsuite/c-c++-common/asan/memcmp-1.c =================================================================== --- gcc/testsuite/c-c++-common/asan/memcmp-1.c (revision 229169) +++ gcc/testsuite/c-c++-common/asan/memcmp-1.c (working copy) @@ -16,5 +16,5 @@ } /* { dg-output "ERROR: AddressSanitizer: stack-buffer-overflow.*(\n|\r\n|\r)" } */ -/* { dg-output " #0 0x\[0-9a-f\]+ +(in _*(interceptor_|wrap_|)memcmp |\[(\])\[^\n\r]*(\n|\r\n|\r)" } */ +/* { dg-output " #0 0x\[0-9a-f\]+ +(in _*(interceptor_|wrap_|)memcmp|\[(\])\[^\n\r]*(\n|\r\n|\r)" } */ /* { dg-output " #1 0x\[0-9a-f\]+ +(in _*main|\[(\])\[^\n\r]*(\n|\r\n|\r)" } */ Index: gcc/testsuite/c-c++-common/asan/sanity-check-pure-c-1.c =================================================================== --- gcc/testsuite/c-c++-common/asan/sanity-check-pure-c-1.c (revision 229169) +++ gcc/testsuite/c-c++-common/asan/sanity-check-pure-c-1.c (working copy) @@ -10,7 +10,7 @@ } /* { dg-output "heap-use-after-free.*(\n|\r\n|\r)" } */ -/* { dg-output " #0 \[^\n\r]*(in _*(interceptor_|)free|\[(\])\[^\n\r]*(\n|\r\n|\r)" } */ +/* { dg-output " #0 \[^\n\r]*(in _*(interceptor_|wrap_)free|\[(\])\[^\n\r]*(\n|\r\n|\r)" } */ /* { dg-output " #1 \[^\n\r]*(in _*main (\[^\n\r]*sanity-check-pure-c-1.c:8|\[^\n\r]*:0)|\[(\]).*(\n|\r\n|\r)" } */ -/* { dg-output " #0 \[^\n\r]*(in _*(interceptor_|)malloc|\[(\])\[^\n\r]*(\n|\r\n|\r)" } */ +/* { dg-output " #0 \[^\n\r]*(in _*(interceptor_|wrap_)malloc|\[(\])\[^\n\r]*(\n|\r\n|\r)" } */ /* { dg-output " #1 \[^\n\r]*(in _*main (\[^\n\r]*sanity-check-pure-c-1.c:7|\[^\n\r]*:0)|\[(\])\[^\n\r]*(\n|\r\n|\r)" } */