From patchwork Tue Dec 12 08:59:09 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "REIX, Tony" X-Patchwork-Id: 847420 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-469008-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="CvWhe7dY"; dkim-atps=neutral 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 3ywv090RqRz9s7g for ; Tue, 12 Dec 2017 19:59:33 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:cc:subject:date:message-id:content-type:mime-version; q=dns; s=default; b=qZdWnAyd/qLvEglAce3jeIvqxW3mDQUr5HR6T/YJZBmn+2UgNs z3uV70YSNewLt9vwX9veTwcv7VmOEoo0ptzHfa64BMotPqlGfHJeGGAQ4kEgNJrl CET822x+NfRdduPh4a3Y+vCrOzz0eMNCk9wI7Loy2BUgLpVFmyBrmHQrM= 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 :to:cc:subject:date:message-id:content-type:mime-version; s= default; bh=3ja5DQY4RPqnDbtTA0pACJsnUhY=; b=CvWhe7dYwrQJPBdjG0PR 2TMRoArp5n0ndJ21pnOUiu5SesjFYZRvn+wsfkeRnIvdoRbJIrRupw2huRyYDHAc dhzU/wEYJFjucwgIswmyilAvT+Jzun6gjbp8ZhARvcXTBsYpnLt9fMnaVv/T9GIK PMEvPKoVvOYq1X1Yf360c5Q= Received: (qmail 70462 invoked by alias); 12 Dec 2017 08:59:24 -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 66019 invoked by uid 89); 12 Dec 2017 08:59:21 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-8.0 required=5.0 tests=AWL, BAYES_50, GIT_PATCH_2, GIT_PATCH_3, KAM_LAZY_DOMAIN_SECURITY, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.2 spammy=bull, H*RU:14.03.0361.001, Hx-spam-relays-external:14.03.0361.001, provence X-HELO: smtppost.atos.net Received: from smtppost.atos.net (HELO smtppost.atos.net) (193.56.114.164) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 12 Dec 2017 08:59:19 +0000 Received: from mail1-ext.my-it-solutions.net (mail1-ext.my-it-solutions.net) by smarthost1.atos.net with smtp (TLS: TLSv1/SSLv3,256bits,ECDHE-RSA-AES256-GCM-SHA384) id 14fe_01ab_509ce77c_30be_4f91_86bb_fd2a58679376; Tue, 12 Dec 2017 09:59:13 +0100 Received: from mail1-int.my-it-solutions.net ([10.92.32.11]) by mail1-ext.my-it-solutions.net (8.15.2/8.15.2) with ESMTPS id vBC8xBuh018118 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 12 Dec 2017 09:59:11 +0100 Received: from FRCRPVV9ET2MSX.ww931.my-it-solutions.net ([172.23.231.43]) by mail1-int.my-it-solutions.net (8.15.2/8.15.2) with ESMTPS id vBC8x3Ba027227 (version=TLSv1 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL); Tue, 12 Dec 2017 09:59:11 +0100 Received: from FRCRPVV9ET4MSX.ww931.my-it-solutions.net (172.23.231.47) by FRCRPVV9ET2MSX.ww931.my-it-solutions.net (172.23.231.43) with Microsoft SMTP Server (TLS) id 14.3.361.1; Tue, 12 Dec 2017 09:59:10 +0100 Received: from FRCRPVV9EX3MSX.ww931.my-it-solutions.net ([169.254.6.217]) by FRCRPVV9ET4MSX.ww931.my-it-solutions.net ([172.23.231.47]) with mapi id 14.03.0361.001; Tue, 12 Dec 2017 09:59:09 +0100 From: "REIX, Tony" To: "gcc-patches@gcc.gnu.org" CC: "dje.gcc@gmail.com" , "thanm@google.com" Subject: [PATCH,AIX] Nil check size threshold control for AIX Date: Tue, 12 Dec 2017 08:59:09 +0000 Message-ID: MIME-Version: 1.0 Description: * This patch tells the Go frontend to insert explicit guards (check for nil -> panic) for AIX since relying on a fault does not work on AIX for page 0. Tests: * AIX: Build: SUCCESS - build made by means of gmake. ChangeLog: * go-lang.c (go_langhook_init): Handle AIX case for nil_check_size_threshold. Cordialement, Tony Reix ATOS / Bull SAS ATOS Expert IBM Coop Architect & Technical Leader Office : +33 (0) 4 76 29 72 67 1 rue de Provence - 38432 Échirolles - France www.atos.net Index: gcc/go/go-lang.c =================================================================== --- ./gcc/go/go-lang.c (revision 255466) +++ ./gcc/go/go-lang.c (working copy) @@ -112,7 +112,11 @@ go_langhook_init (void) args.check_divide_overflow = go_check_divide_overflow; args.compiling_runtime = go_compiling_runtime; args.debug_escape_level = go_debug_escape_level; +#ifdef TARGET_AIX + args.nil_check_size_threshold = -1; +#else args.nil_check_size_threshold = 4096; +#endif args.linemap = go_get_linemap(); args.backend = go_get_backend(); go_create_gogo (&args);