From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 73616 invoked by alias); 25 Sep 2015 13:59:52 -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 72865 invoked by uid 89); 25 Sep 2015 13:59:51 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.6 required=5.0 tests=AWL,BAYES_00,KAM_LAZY_DOMAIN_SECURITY,RP_MATCHES_RCVD autolearn=no version=3.3.2 X-HELO: e06smtp12.uk.ibm.com Received: from e06smtp12.uk.ibm.com (HELO e06smtp12.uk.ibm.com) (195.75.94.108) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (CAMELLIA256-SHA encrypted) ESMTPS; Fri, 25 Sep 2015 13:59:50 +0000 Received: from localhost by e06smtp12.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Fri, 25 Sep 2015 14:59:46 +0100 Received: from d06dlp01.portsmouth.uk.ibm.com (9.149.20.13) by e06smtp12.uk.ibm.com (192.168.101.142) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Fri, 25 Sep 2015 14:59:44 +0100 X-IBM-Helo: d06dlp01.portsmouth.uk.ibm.com X-IBM-MailFrom: vogt@linux.vnet.ibm.com X-IBM-RcptTo: gcc-patches@gcc.gnu.org Received: from b06cxnps3075.portsmouth.uk.ibm.com (d06relay10.portsmouth.uk.ibm.com [9.149.109.195]) by d06dlp01.portsmouth.uk.ibm.com (Postfix) with ESMTP id 3E3CF17D8056 for ; Fri, 25 Sep 2015 15:01:37 +0100 (BST) Received: from d06av05.portsmouth.uk.ibm.com (d06av05.portsmouth.uk.ibm.com [9.149.37.229]) by b06cxnps3075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id t8PDxhAd30540000 for ; Fri, 25 Sep 2015 13:59:44 GMT Received: from d06av05.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av05.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id t8PDxhGR008328 for ; Fri, 25 Sep 2015 07:59:43 -0600 Received: from bl3ahm9f.de.ibm.com (sig-9-83-89-168.evts.uk.ibm.com [9.83.89.168]) by d06av05.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with ESMTP id t8PDxhGv008313; Fri, 25 Sep 2015 07:59:43 -0600 Received: from dvogt by bl3ahm9f.de.ibm.com with local (Exim 4.76) (envelope-from ) id 1ZfTXJ-0004Pd-Ss; Fri, 25 Sep 2015 15:59:41 +0200 Date: Fri, 25 Sep 2015 14:16:00 -0000 From: Dominik Vogt To: gcc-patches@gcc.gnu.org Cc: Andreas Krebbel , Ulrich Weigand Subject: [PATCH] s/390: Implement "target" attribute. Message-ID: <20150925135941.GA14892@linux.vnet.ibm.com> Reply-To: vogt@linux.vnet.ibm.com Mail-Followup-To: gcc-patches@gcc.gnu.org, Andreas Krebbel , Ulrich Weigand MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.21 (2010-09-15) X-TM-AS-MML: disable X-Content-Scanned: Fidelis XPS MAILER x-cbid: 15092513-0009-0000-0000-000005BC21E5 X-SW-Source: 2015-09/txt/msg01959.txt.bz2 The following set of two patches implements the function __attribute__ ((target("..."))) and the corresponding #pragma GCC target("...") on S/390. It comes with certain limitations: * It is not possible to change any options that affect the ABI or the definition of target macros by using the attribute (vx, htm, zarch and others). Some of them are still supported but unable to change the definition of the corresponding target macros. In these cases, the pragma has to be used. One reason for this is that it is not possible to change the definition of the target macros with the attribute, but the implementation of some features relies on them. * Even with the pragma it is not possible to switch between zarch and esa architecture because internal data typed would have to be changed at Gcc run time. The second patch contains a long term change in the interface with the assembler. Currently, the compiler wrapper passes the same -march= and -mtune= options to the compiler and the assembler. The patch makes this obsolete by emitting ".machine" and ".machinemode" dirctives to the top of the assembly language file. The old way ist still supported but may be removed once the ".machine" feature is supported by all as versions in the field. The second patch depends on the first one, and both require the (latest) change proposed in this thread: https://gcc.gnu.org/ml/gcc-patches/2015-09/msg01546.html Ciao Dominik ^_^ ^_^ -- Dominik Vogt IBM Germany