From patchwork Thu Nov 3 02:27:21 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paul Hua X-Patchwork-Id: 80576 Delivered-To: patch@linaro.org Received: by 10.140.97.247 with SMTP id m110csp425000qge; Wed, 2 Nov 2016 19:27:46 -0700 (PDT) X-Received: by 10.99.238.17 with SMTP id e17mr10586951pgi.154.1478140066210; Wed, 02 Nov 2016 19:27:46 -0700 (PDT) Return-Path: Received: from sourceware.org (server1.sourceware.org. [209.132.180.131]) by mx.google.com with ESMTPS id u21si6537788pgh.212.2016.11.02.19.27.45 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 02 Nov 2016 19:27:46 -0700 (PDT) Received-SPF: pass (google.com: domain of gcc-patches-return-440269-patch=linaro.org@gcc.gnu.org designates 209.132.180.131 as permitted sender) client-ip=209.132.180.131; Authentication-Results: mx.google.com; dkim=pass header.i=@gcc.gnu.org; spf=pass (google.com: domain of gcc-patches-return-440269-patch=linaro.org@gcc.gnu.org designates 209.132.180.131 as permitted sender) smtp.mailfrom=gcc-patches-return-440269-patch=linaro.org@gcc.gnu.org; dmarc=fail (p=NONE dis=NONE) header.from=gmail.com DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :mime-version:from:date:message-id:subject:to:cc:content-type; q=dns; s=default; b=Wp6/N3jYZK9p0kGrGjB+2yYLfDnG1UFMODbOvk2SEU/ MINoTXlQtoJDOff552CnmQolI0EqA8NijoROnAbbZntdlusPFjQAhWSpGxEAbRs2 zhiFdim/WJ9bBV0mauMYhv2KblODq1SbfSDK3NZ7JYoECcAVUiY0sEEVR9O7rb3s = 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 :mime-version:from:date:message-id:subject:to:cc:content-type; s=default; bh=OuB0iFy82JaAqf9p6kPsUytxYos=; b=WANRTPEpJheH06dgS tvgjZZww6aOJkEom00ijaeYf14PcvmKoJ4ymlvDVBO/AOWYGCNHDyWJva5LxJTWZ GHwxla0K5c+ZD80VZ0VW5YQLMmFDVUb40OaWCh7VpdLSJZ5bs5W1XhnyVF8YD+Fc gWkRdFTTXF4aM7sw9KfuEnKiuE= Received: (qmail 109604 invoked by alias); 3 Nov 2016 02:27:26 -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 109584 invoked by uid 89); 3 Nov 2016 02:27:25 -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, RCVD_IN_SORBS_SPAM, SPF_PASS autolearn=ham version=3.3.2 spammy=2016-11-03, 20161103 X-HELO: mail-qk0-f173.google.com Received: from mail-qk0-f173.google.com (HELO mail-qk0-f173.google.com) (209.85.220.173) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 03 Nov 2016 02:27:24 +0000 Received: by mail-qk0-f173.google.com with SMTP id x190so39612213qkb.0 for ; Wed, 02 Nov 2016 19:27:23 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:from:date:message-id:subject:to:cc; bh=ztVPvu2qzmqhkqHSa4tW39398TgV6piylGis44QH/RE=; b=Fn1fuV3GrLnk4opNwe+INt7mlozEx8j8vbzUHVuZ3+YRcSu5ZTmRpxNev1anGeDAOn SITjzxjI+1sID69r+IuI0rS/OHoQAZYCZZSGw+tAawfFbLM8r/9l0CT//MSnfOqLhNkw Q9LL8b3j5T5vZuaXhqaLiTf2cqZZlxfg3p/An7KfVlcxcM5cZKHivknIJs6c9Sc2bzBN ALaqRrJJmuHnxfxuGFrOHcjFMl7lx9cb54GUQvmr6iX1vET7EnzrLscxe7TyrEzFQBAW aAzYGk9FBW4gZdtbaqrfCS26Ptqh2zFo3fJwwaizXIW9w0KC5JchDWkzbZNjMcBB0Qh4 BtpA== X-Gm-Message-State: ABUngvduqgaRSp116HROIrAQEuVQ39ehPKRRz79HgHeVRJVzPt3aVnF3f04IKrK54X9gnvG0WRt+46y62CVkww== X-Received: by 10.55.27.226 with SMTP id m95mr6265559qkh.143.1478140042528; Wed, 02 Nov 2016 19:27:22 -0700 (PDT) MIME-Version: 1.0 Received: by 10.55.94.65 with HTTP; Wed, 2 Nov 2016 19:27:21 -0700 (PDT) From: Paul Hua Date: Thu, 3 Nov 2016 10:27:21 +0800 Message-ID: Subject: [PATCH,gcc/MIPS] Make loongson3a use fused madd.d To: gcc-patches@gcc.gnu.org Cc: Matthew Fortune , catherine_moore@mentor.com X-IsSubscribed: yes Hi, Loongson3a has 4 operand fused madd instrcution. This patch set loongson3a use fused madd.d. ChangeLog : *** gcc/ChangeLog *** 2016-11-03 Chenghua Xu config/mips/ * mips.h: Set loongson3a use fused madd.d. Tested on loongson3a. PS: I will soon submit some patches, how can i get a copyright assignment. diff --git a/gcc/config/mips/mips.h b/gcc/config/mips/mips.h index 81862a9..5076a2b 100644 --- a/gcc/config/mips/mips.h +++ b/gcc/config/mips/mips.h @@ -1056,11 +1056,11 @@ struct mips_cpu_info { /* ISA has 4 operand fused madd instructions of the form 'd = [+-] (a * b [+-] c)'. */ -#define ISA_HAS_FUSED_MADD4 TARGET_MIPS8000 +#define ISA_HAS_FUSED_MADD4 (TARGET_MIPS8000 || TARGET_LOONGSON_3A) /* ISA has 4 operand unfused madd instructions of the form 'd = [+-] (a * b [+-] c)'. */ -#define ISA_HAS_UNFUSED_MADD4 (ISA_HAS_FP4 && !TARGET_MIPS8000) +#define ISA_HAS_UNFUSED_MADD4 (ISA_HAS_FP4 && !TARGET_MIPS8000 && !TARGET_LOONGSON_3A) /* ISA has 3 operand r6 fused madd instructions of the form 'c = c [+-] (a * b)'. */