aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteven Bosscher <stevenb@suse.de>2004-01-11 23:05:49 +0000
committerSteven Bosscher <stevenb@suse.de>2004-01-11 23:05:49 +0000
commit1ce6cc62b5775e12233aea5eda74d858aba3b50c (patch)
tree3f32a25a3339b44675d391be35196638125e0b72
parent1c5de13bcb4f953b03219282e832da548164650f (diff)
PR fortran/9972
* toplev.c (rest_of_handle_inlining): Also consider functions for deferral if the language is GNU F77. testsuite: * 980520-1.x: Removed. git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@75692 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/testsuite/g77.f-torture/execute/980520-1.x11
-rw-r--r--gcc/toplev.c8
3 files changed, 12 insertions, 12 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 07b0bca6d32..030417dd8be 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2004-01-11 Steven Bosscher <stevenb@suse.de>
+
+ * toplev.c (rest_of_handle_inline): Also consider functions
+ for deferral if the language is GNU F77.
+
2004-01-11 Zack Weinberg <zack@codesourcery.com>
* c-decl.c (diagnose_arglist_conflict): Add missing space to
diff --git a/gcc/testsuite/g77.f-torture/execute/980520-1.x b/gcc/testsuite/g77.f-torture/execute/980520-1.x
deleted file mode 100644
index 595de5e1911..00000000000
--- a/gcc/testsuite/g77.f-torture/execute/980520-1.x
+++ /dev/null
@@ -1,11 +0,0 @@
-set torture_eval_before_compile {
-
- set compiler_conditional_xfail_data {
- "PR fortran/9972" \
- { "*-*-*" } \
- { "-O0" } \
- { "" }
- }
-}
-
-return 0
diff --git a/gcc/toplev.c b/gcc/toplev.c
index 478193951e3..3ac7d737393 100644
--- a/gcc/toplev.c
+++ b/gcc/toplev.c
@@ -2678,7 +2678,13 @@ rest_of_handle_inlining (tree decl)
if (inlinable
|| (DECL_INLINE (decl)
- && flag_inline_functions
+ /* Egad. This RTL deferral test conflicts with Fortran assumptions
+ for unreferenced symbols. See g77.f-torture/execute/980520-1.f.
+ But removing this line from the check breaks all languages that
+ use the call graph to output symbols. This hard-coded check is
+ the least invasive work-around. */
+ && (flag_inline_functions
+ || strcmp (lang_hooks.name, "GNU F77") == 0)
&& ((! TREE_PUBLIC (decl) && ! TREE_ADDRESSABLE (decl)
&& ! TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl))
&& ! flag_keep_inline_functions)