diff options
author | jamborm <jamborm@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-09-07 17:00:44 +0000 |
---|---|---|
committer | jamborm <jamborm@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-09-07 17:00:44 +0000 |
commit | 77b05e95f248aac266f7a699737ced319d7c50de (patch) | |
tree | 98335c170eb38e3ce630d5cdb2dad1f329a1bd8c /gcc/ipa-cp.c | |
parent | cbdababb9b72a255d4f9d336ad7b14647747a36b (diff) | |
download | gcc-77b05e95f248aac266f7a699737ced319d7c50de.tar.gz |
2010-09-07 Martin Jambor <mjambor@suse.cz>
PR fortran/43665
* ipa-cp.c (ipcp_versionable_function_p): Return false if there
are any type attributes.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@163960 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ipa-cp.c')
-rw-r--r-- | gcc/ipa-cp.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/gcc/ipa-cp.c b/gcc/ipa-cp.c index e6c67d62653..e94fdca9d3b 100644 --- a/gcc/ipa-cp.c +++ b/gcc/ipa-cp.c @@ -427,8 +427,11 @@ ipcp_versionable_function_p (struct cgraph_node *node) { struct cgraph_edge *edge; - /* There are a number of generic reasons functions cannot be versioned. */ - if (!node->local.versionable) + /* There are a number of generic reasons functions cannot be versioned. We + also cannot remove parameters if there are type attributes such as fnspec + present. */ + if (!node->local.versionable + || TYPE_ATTRIBUTES (TREE_TYPE (node->decl))) return false; /* Removing arguments doesn't work if the function takes varargs |