From patchwork Thu Dec 10 14:13:42 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chen Gang X-Patchwork-Id: 555274 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id DD91B1402A1 for ; Fri, 11 Dec 2015 05:24:02 +1100 (AEDT) Received: from localhost ([::1]:43752 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a75sm-0006rS-NZ for incoming@patchwork.ozlabs.org; Thu, 10 Dec 2015 13:24:00 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:53483) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a71w2-0005kY-CO for qemu-devel@nongnu.org; Thu, 10 Dec 2015 09:11:12 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a71vx-0007Cr-Du for qemu-devel@nongnu.org; Thu, 10 Dec 2015 09:11:06 -0500 Received: from mail113-248.mail.alibaba.com ([205.204.113.248]:55372 helo=us-alimail-mta1.hst.scl.en.alidc.net) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a71vw-00079b-P9 for qemu-devel@nongnu.org; Thu, 10 Dec 2015 09:11:01 -0500 X-Alimail-AntiSpam: AC=CONTINUE; BC=0.07660683|-1; FP=0|0|0|0|0|-1|-1|-1; HT=e02c03276; MF=chengang@emindsoft.com.cn; NM=1; PH=DS; RN=5; RT=5; SR=0; TI=SMTPD_----4KbsLRk_1449756645; Received: from ShengShiZhuChengdeMacBook-Pro.local(mailfrom:chengang@emindsoft.com.cn ip:223.72.67.91) by smtp.aliyun-inc.com(10.147.42.22); Thu, 10 Dec 2015 22:10:46 +0800 Message-ID: <56698896.1090302@emindsoft.com.cn> Date: Thu, 10 Dec 2015 22:13:42 +0800 From: Chen Gang User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 MIME-Version: 1.0 To: "rth@twiddle.net" , Peter Maydell , Chris Metcalf References: <56698865.8050901@emindsoft.com.cn> In-Reply-To: <56698865.8050901@emindsoft.com.cn> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 205.204.113.248 X-Mailman-Approved-At: Thu, 10 Dec 2015 13:05:13 -0500 Cc: chenwei@emindsoft.com.cn, qemu-devel Subject: [Qemu-devel] [PATCH v3 1/4] target-tilegx: Add floating point shared functions X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org They are used by fsingle and fdouble helpers. Signed-off-by: Chen Gang --- target-tilegx/helper-fshared.c | 53 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 target-tilegx/helper-fshared.c diff --git a/target-tilegx/helper-fshared.c b/target-tilegx/helper-fshared.c new file mode 100644 index 0000000..d669f58 --- /dev/null +++ b/target-tilegx/helper-fshared.c @@ -0,0 +1,53 @@ +/* + * TILE-Gx virtual Floating point shared functions + * + * Copyright (c) 2015 Chen Gang + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, see . + */ + +static inline uint64_t create_fsfd_flag_un(void) +{ + return 1 << 25; +} + +static inline uint64_t create_fsfd_flag_lt(void) +{ + return 1 << 26; +} + +static inline uint64_t create_fsfd_flag_le(void) +{ + return 1 << 27; +} + +static inline uint64_t create_fsfd_flag_gt(void) +{ + return 1 << 28; +} + +static inline uint64_t create_fsfd_flag_ge(void) +{ + return 1 << 29; +} + +static inline uint64_t create_fsfd_flag_eq(void) +{ + return 1 << 30; +} + +static inline uint64_t create_fsfd_flag_ne(void) +{ + return 1ULL << 31; +}