From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 56124 invoked by alias); 21 Sep 2015 14:15:19 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 56047 invoked by uid 89); 21 Sep 2015 14:15:12 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.1 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mail-io0-f177.google.com Received: from mail-io0-f177.google.com (HELO mail-io0-f177.google.com) (209.85.223.177) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-GCM-SHA256 encrypted) ESMTPS; Mon, 21 Sep 2015 14:15:07 +0000 Received: by iofb144 with SMTP id b144so121285875iof.1 for ; Mon, 21 Sep 2015 07:15:05 -0700 (PDT) X-Received: by 10.107.128.41 with SMTP id b41mr25910589iod.74.1442844905022; Mon, 21 Sep 2015 07:15:05 -0700 (PDT) Received: from msticlxl57.ims.intel.com (fmdmzpr01-ext.fm.intel.com. [192.55.54.36]) by smtp.gmail.com with ESMTPSA id qd2sm5580518igb.19.2015.09.21.07.15.02 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 21 Sep 2015 07:15:03 -0700 (PDT) Date: Mon, 21 Sep 2015 14:15:00 -0000 From: Kirill Yukhin To: Uros Bizjak Cc: GCC Patches Subject: [PATCH, i386] Introduce switch for Skylake Server CPU. Message-ID: <20150921141442.GD49423@msticlxl57.ims.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.23 (2014-03-12) X-IsSubscribed: yes X-SW-Source: 2015-09/txt/msg01574.txt.bz2 Hello, This patch introduces switches necessary for new Intel Server CPU (code-named Skylake). Bootstrapped & regtested. Is it ok for trunk? gcc/ * config.gcc: Support "skx". * config/i386/i386-c.c (ix86_target_macros_internal): Handle PROCESSOR_SKX. * config/i386/i386.c (m_SKX): Define. (processor_target_table): Add "skx". (PTA_SKX): Define. (ix86_option_override_internal): Add "skx". (fold_builtin_cpu): Handle "skx". * config/i386/i386.h (TARGET_SKX): Define. (processor_type): Add PROCESSOR_SKX. * config/i386/i386.md (attr "cpu"): Add knl. * config/i386/x86-tune.def: Add m_KNL. gcc/testsuite/ * gcc.target/i386/funcspec-5.c: Test avx512vl, avx512bw, avx512dq, avx512cd, avx512er, avx512pf and skx. -- Thanks, K commit ffaaf5ad0460cd5bd85f6fd4b360fb1171eb273e Author: Kirill Yukhin Date: Fri Sep 18 14:03:54 2015 +0300 AVX-512. Introduce SKX CPU. diff --git a/gcc/config.gcc b/gcc/config.gcc index 75807f5..18da001 100644 --- a/gcc/config.gcc +++ b/gcc/config.gcc @@ -595,7 +595,7 @@ x86_64_archs="amdfam10 athlon64 athlon64-sse3 barcelona bdver1 bdver2 \ bdver3 bdver4 btver1 btver2 k8 k8-sse3 opteron opteron-sse3 nocona \ core2 corei7 corei7-avx core-avx-i core-avx2 atom slm nehalem westmere \ sandybridge ivybridge haswell broadwell bonnell silvermont knl x86-64 \ -native" +native skx" # Additional x86 processors supported by --with-cpu=. Each processor # MUST be separated by exactly one space. diff --git a/gcc/config/i386/i386-c.c b/gcc/config/i386/i386-c.c index 35cecd0..09670bb 100644 --- a/gcc/config/i386/i386-c.c +++ b/gcc/config/i386/i386-c.c @@ -177,6 +177,10 @@ ix86_target_macros_internal (HOST_WIDE_INT isa_flag, def_or_undef (parse_in, "__knl"); def_or_undef (parse_in, "__knl__"); break; + case PROCESSOR_SKX: + def_or_undef (parse_in, "__skx"); + def_or_undef (parse_in, "__skx__"); + break; /* use PROCESSOR_max to not set/unset the arch macro. */ case PROCESSOR_max: break; @@ -286,6 +290,9 @@ ix86_target_macros_internal (HOST_WIDE_INT isa_flag, case PROCESSOR_KNL: def_or_undef (parse_in, "__tune_knl__"); break; + case PROCESSOR_SKX: + def_or_undef (parse_in, "__tune_skx__"); + break; case PROCESSOR_IAMCU: def_or_undef (parse_in, "__tune_iamcu__"); break; diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c index 00e7006..d34bb62 100644 --- a/gcc/config/i386/i386.c +++ b/gcc/config/i386/i386.c @@ -2098,6 +2098,7 @@ const struct processor_costs *ix86_cost = &pentium_cost; #define m_BONNELL (1<