From: tbsaunde+gcc@tbsaunde.org
To: gcc-patches@gcc.gnu.org
Subject: [PATCH 7/7] add default for HAVE_tablejump
Date: Sun, 24 May 2015 05:05:00 -0000 [thread overview]
Message-ID: <1432421110-22114-8-git-send-email-tbsaunde+gcc@tbsaunde.org> (raw)
In-Reply-To: <1432421110-22114-1-git-send-email-tbsaunde+gcc@tbsaunde.org>
From: Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
gcc/ChangeLog:
2015-05-23 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
* defaults.h (gen_tablejump): New function.
(HAVE_tablejump): Add default value.
* expr.c: Adjust.
* stmt.c: Likewise.
---
gcc/ChangeLog | 7 +++++++
gcc/defaults.h | 10 ++++++++++
gcc/expr.c | 5 -----
gcc/stmt.c | 4 ----
4 files changed, 17 insertions(+), 9 deletions(-)
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 99ee6dd..864ce02 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,12 @@
2015-05-23 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
+ * defaults.h (gen_tablejump): New function.
+ (HAVE_tablejump): Add default value.
+ * expr.c: Adjust.
+ * stmt.c: Likewise.
+
+2015-05-23 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
+
* defaults.h (gen_store_multiple): New function.
(HAVE_store_multiple): Add default value.
* expr.c (move_block_from_reg): Adjust.
diff --git a/gcc/defaults.h b/gcc/defaults.h
index 566841b..53d6682 100644
--- a/gcc/defaults.h
+++ b/gcc/defaults.h
@@ -1494,6 +1494,16 @@ gen_store_multiple (rtx, rtx, rtx)
}
#endif
+#ifndef HAVE_tablejump
+#define HAVE_tablejump 0
+static inline rtx
+gen_tablejump (rtx, rtx)
+{
+ gcc_unreachable ();
+ return NULL;
+}
+#endif
+
#endif /* GCC_INSN_FLAGS_H */
#endif /* ! GCC_DEFAULTS_H */
diff --git a/gcc/expr.c b/gcc/expr.c
index 0dad737..dccaf8b 100644
--- a/gcc/expr.c
+++ b/gcc/expr.c
@@ -11226,11 +11226,6 @@ try_casesi (tree index_type, tree index_expr, tree minval, tree range,
}
/* Attempt to generate a tablejump instruction; same concept. */
-#ifndef HAVE_tablejump
-#define HAVE_tablejump 0
-#define gen_tablejump(x, y) (0)
-#endif
-
/* Subroutine of the next function.
INDEX is the value being switched on, with the lowest value
diff --git a/gcc/stmt.c b/gcc/stmt.c
index 16a080a..303df72 100644
--- a/gcc/stmt.c
+++ b/gcc/stmt.c
@@ -796,10 +796,6 @@ dump_case_nodes (FILE *f, struct case_node *root,
#define HAVE_casesi 0
#endif
-#ifndef HAVE_tablejump
-#define HAVE_tablejump 0
-#endif
-
/* Return the smallest number of different values for which it is best to use a
jump-table instead of a tree of conditional branches. */
--
2.4.0.78.g7c6ecbf
next prev parent reply other threads:[~2015-05-23 22:45 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-05-23 22:45 [PATCH 0/7] More ifdef reduction tbsaunde+gcc
2015-05-23 22:45 ` [PATCH 6/7] add default for HAVE_store_multiple tbsaunde+gcc
2015-05-23 22:45 ` [PATCH 2/7] provide default for HAVE_mem_thread_fence tbsaunde+gcc
2015-05-23 22:45 ` [PATCH 3/7] always define HAVE_memory_barrier tbsaunde+gcc
2015-05-23 22:45 ` [PATCH 1/7] always define HAVE_lo_sum tbsaunde+gcc
2015-05-24 4:24 ` [PATCH 5/7] add default for HAVE_load_multiple tbsaunde+gcc
2015-05-24 5:05 ` tbsaunde+gcc [this message]
2015-05-24 6:47 ` [PATCH 4/7] provide default for HAVE_mem_signal_fence tbsaunde+gcc
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=1432421110-22114-8-git-send-email-tbsaunde+gcc@tbsaunde.org \
--to=tbsaunde+gcc@tbsaunde.org \
--cc=gcc-patches@gcc.gnu.org \
/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 read-only IMAP folder(s) and NNTP newsgroup(s).