From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10492 invoked by alias); 15 Aug 2018 11:55:16 -0000 Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org Received: (qmail 10480 invoked by uid 89); 15 Aug 2018 11:55:15 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: mail-oi0-f44.google.com Received: from mail-oi0-f44.google.com (HELO mail-oi0-f44.google.com) (209.85.218.44) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 15 Aug 2018 11:55:14 +0000 Received: by mail-oi0-f44.google.com with SMTP id q11-v6so1436041oic.12 for ; Wed, 15 Aug 2018 04:55:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:reply-to:from:date:message-id:subject:to; bh=QCoXWGAk3ADD39a5Pt0ObT06TkCOQx8pOYomIfo8F94=; b=ML8iSAfTxkvZ6sYz2Bd0H8M5Mlm9ro02gz5kVQdCBoPCcopDm0Tj2ybf9HsSySEWX4 domcBXw+cZA2sYT5QQ+QDF/R7nuFAGwus2Klau+k7TGIZ2BS6xAo6Y93jgI8MPij/oFJ gfGFHjmj3tfrgOh+LacewGQH4KquFBQYFHUxn5GEoSw5cQMUMQZiHuJqQf5L0q70ZyAe xo0PpgihdsZs4w7deYT11SpC7j3NVt7tkdse1OSIsACz/wKdvczAymZuCfJbnl9VbF6i 8Obgpbh4PH2bQf4ishOq/5IFCw8QJGtcQ7wcOOhjFcBF3xRjv3ogGojb5zXg2ihp5orF xUvw== MIME-Version: 1.0 Received: by 2002:a4a:c712:0:0:0:0:0 with HTTP; Wed, 15 Aug 2018 04:55:11 -0700 (PDT) Reply-To: noloader@gmail.com From: Jeffrey Walton Date: Wed, 15 Aug 2018 11:55:00 -0000 Message-ID: Subject: Enable one ISA for my code, and another ISA for GCC code? To: gcc-help Content-Type: text/plain; charset="UTF-8" X-IsSubscribed: yes X-SW-Source: 2018-08/txt/msg00037.txt.bz2 I'm catching a SIGILL on POWER7 ppc64-le machine. I compiled the source with -mcpu=power8 so I could enable some builtins I may need. Use of the builtins is guarded at runtime. (This is the classic distro model, where most source code is compiled for a minimum machine but higher ISAs are guarded at runtime). GCC converted some C code into POWER8 code. The SIGILL is happening in the function prologue due to use of mtfprwz. Apparently mtfprwz is a ISA 2.07B/POWER8 instruction. My question is, how do I tell GCC to use a different ISA than I am using? I need a solution for compielrs found in the field, and that includes GCC 4.8: Jeff