qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: chengang@emindsoft.com.cn
To: rth@twiddle.net, peter.maydell@linaro.org, cmetcalf@ezchip.com
Cc: Chen Gang <chengang@emindsoft.com.cn>,
	qemu-devel@nongnu.org, Chen Gang <gang.chen.5i5j@gmail.com>
Subject: [Qemu-devel] [PATCH v4 1/4] target-tilegx: Add floating point shared functions
Date: Thu, 24 Dec 2015 05:48:32 +0800	[thread overview]
Message-ID: <1450907315-10135-2-git-send-email-chengang@emindsoft.com.cn> (raw)
In-Reply-To: <1450907315-10135-1-git-send-email-chengang@emindsoft.com.cn>

From: Chen Gang <chengang@emindsoft.com.cn>

They are used by fsingle and fdouble helpers.

Signed-off-by: Chen Gang <gang.chen.5i5j@gmail.com>
---
 target-tilegx/helper-fshared.c | 22 +++++++++++++++++
 target-tilegx/helper-fshared.h | 55 ++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 77 insertions(+)
 create mode 100644 target-tilegx/helper-fshared.c
 create mode 100644 target-tilegx/helper-fshared.h

diff --git a/target-tilegx/helper-fshared.c b/target-tilegx/helper-fshared.c
new file mode 100644
index 0000000..bad1c9a
--- /dev/null
+++ b/target-tilegx/helper-fshared.c
@@ -0,0 +1,22 @@
+/*
+ *  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 <http://www.gnu.org/licenses/>.
+ */
+
+#include "fpu/softfloat.h"
+
+float_status fp_status;
diff --git a/target-tilegx/helper-fshared.h b/target-tilegx/helper-fshared.h
new file mode 100644
index 0000000..5f4926e
--- /dev/null
+++ b/target-tilegx/helper-fshared.h
@@ -0,0 +1,55 @@
+/*
+ *  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 <http://www.gnu.org/licenses/>.
+ */
+
+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;
+}
+
+extern float_status fp_status;
-- 
1.9.3

  reply	other threads:[~2015-12-23 21:50 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-12-23 21:48 [Qemu-devel] [PATCH v4 0/4] target-tilegx: Implement floating point instructions chengang
2015-12-23 21:48 ` chengang [this message]
2015-12-23 22:51   ` [Qemu-devel] [PATCH v4 1/4] target-tilegx: Add floating point shared functions Richard Henderson
2015-12-24 15:38     ` Chen Gang
2015-12-24 20:01       ` Richard Henderson
2015-12-25 13:05         ` Chen Gang
2015-12-23 21:48 ` [Qemu-devel] [PATCH v4 2/4] target-tilegx: Add single floating point implementation chengang
2015-12-23 23:07   ` Richard Henderson
2015-12-24 15:52     ` Chen Gang
2015-12-27  8:31       ` Chen Gang
2015-12-23 21:48 ` [Qemu-devel] [PATCH v4 3/4] target-tilegx: Add double " chengang
2015-12-23 21:48 ` [Qemu-devel] [PATCH v4 4/4] target-tilegx: Integrate floating pointer implementation chengang

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1450907315-10135-2-git-send-email-chengang@emindsoft.com.cn \
    --to=chengang@emindsoft.com.cn \
    --cc=cmetcalf@ezchip.com \
    --cc=gang.chen.5i5j@gmail.com \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-devel@nongnu.org \
    --cc=rth@twiddle.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).