summaryrefslogtreecommitdiff
path: root/gcc/lto
diff options
context:
space:
mode:
authoraldyh <aldyh@138bc75d-0d04-0410-961f-82ee72b054a4>2011-11-22 18:37:16 +0000
committeraldyh <aldyh@138bc75d-0d04-0410-961f-82ee72b054a4>2011-11-22 18:37:16 +0000
commitea0e88d1e2658f33c84769c883246c1e686827f8 (patch)
treed9c627efeb62217e0942238cce58b0177ffc0e93 /gcc/lto
parentd387a10addf1181f5247772c1fce9a688955b583 (diff)
downloadgcc-ea0e88d1e2658f33c84769c883246c1e686827f8.tar.gz
* opts.c (finish_options): Do not fail for -fgnu-tm.
* gimple-streamer-out.c (output_gimple_stmt): Handle GIMPLE_TRANSACTION. * gimple-streamer-in.c (input_gimple_stmt): Same. * lto-cgraph.c (input_overwrite_node): Read tm_clone bit. (lto_output_node): Write tm_clone bit. lto/ * lto-lang.c (lto_attribute_table): Handle transaction_pure. (handle_transaction_pure_attribute): New. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@181629 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/lto')
-rw-r--r--gcc/lto/ChangeLog5
-rw-r--r--gcc/lto/lto-lang.c17
2 files changed, 22 insertions, 0 deletions
diff --git a/gcc/lto/ChangeLog b/gcc/lto/ChangeLog
index d8bbd9ca8dd..af849540ea8 100644
--- a/gcc/lto/ChangeLog
+++ b/gcc/lto/ChangeLog
@@ -1,3 +1,8 @@
+2011-11-21 Aldy Hernandez <aldyh@redhat.com>
+
+ * lto-lang.c (lto_attribute_table): Handle transaction_pure.
+ (handle_transaction_pure_attribute): New.
+
2011-11-03 Richard Guenther <rguenther@suse.de>
PR lto/44965
diff --git a/gcc/lto/lto-lang.c b/gcc/lto/lto-lang.c
index c702b9a2d24..2536f26ebf0 100644
--- a/gcc/lto/lto-lang.c
+++ b/gcc/lto/lto-lang.c
@@ -46,6 +46,7 @@ static tree handle_nonnull_attribute (tree *, tree, tree, int, bool *);
static tree handle_nothrow_attribute (tree *, tree, tree, int, bool *);
static tree handle_sentinel_attribute (tree *, tree, tree, int, bool *);
static tree handle_type_generic_attribute (tree *, tree, tree, int, bool *);
+static tree handle_transaction_pure_attribute (tree *, tree, tree, int, bool *);
static tree handle_format_attribute (tree *, tree, tree, int, bool *);
static tree handle_format_arg_attribute (tree *, tree, tree, int, bool *);
@@ -75,6 +76,8 @@ const struct attribute_spec lto_attribute_table[] =
handle_sentinel_attribute, false },
{ "type generic", 0, 0, false, true, true,
handle_type_generic_attribute, false },
+ { "transaction_pure", 0, 0, false, true, true,
+ handle_transaction_pure_attribute, false },
{ NULL, 0, 0, false, false, false, NULL, false }
};
@@ -402,6 +405,20 @@ handle_type_generic_attribute (tree *node, tree ARG_UNUSED (name),
return NULL_TREE;
}
+/* Handle a "transaction_pure" attribute. */
+
+static tree
+handle_transaction_pure_attribute (tree *node, tree ARG_UNUSED (name),
+ tree ARG_UNUSED (args),
+ int ARG_UNUSED (flags),
+ bool * ARG_UNUSED (no_add_attrs))
+{
+ /* Ensure we have a function type. */
+ gcc_assert (TREE_CODE (*node) == FUNCTION_TYPE);
+
+ return NULL_TREE;
+}
+
/* Handle a "format" attribute; arguments as in
struct attribute_spec.handler. */