summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>2008-01-09 10:33:55 +0000
committerrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>2008-01-09 10:33:55 +0000
commit3e6bab0cf790ef77c6ed7767243b39670d5b3c58 (patch)
treeb765794632bde46810ae91b0c2c260a33329ad71
parentf72a5ea4302274e9c3337a0d4f87e02a942f4a4b (diff)
downloadppe42-gcc-3e6bab0cf790ef77c6ed7767243b39670d5b3c58.tar.gz
ppe42-gcc-3e6bab0cf790ef77c6ed7767243b39670d5b3c58.zip
2008-01-09 Steven Bosscher <stevenb.gcc@gmail.com>
PR debug/26364 * opts.c (decode_options): Disable inlining of functions called once if not in unit-at-a-time mode. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@131423 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/opts.c10
2 files changed, 16 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 619053cb520..b1fca9bf777 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,9 @@
+2008-01-09 Steven Bosscher <stevenb.gcc@gmail.com>
+
+ PR debug/26364
+ * opts.c (decode_options): Disable inlining of functions called
+ once if not in unit-at-a-time mode.
+
2008-01-09 Alexandre Oliva <aoliva@redhat.com>
* Makefile.in (dse.o): Remove duplicate $(RECOG_H) dependency.
diff --git a/gcc/opts.c b/gcc/opts.c
index 90408b5938d..5d952c6304e 100644
--- a/gcc/opts.c
+++ b/gcc/opts.c
@@ -950,6 +950,16 @@ decode_options (unsigned int argc, const char **argv)
if (flag_really_no_inline == 2)
flag_really_no_inline = flag_no_inline;
+ /* Inlining of functions called just once will only work if we can look
+ at the complete translation unit. */
+ if (flag_inline_functions_called_once && !flag_unit_at_a_time)
+ {
+ flag_inline_functions_called_once = 0;
+ warning (OPT_Wdisabled_optimization,
+ "-funit-at-a-time is required for inlining of functions "
+ "that are only called once");
+ }
+
/* The optimization to partition hot and cold basic blocks into separate
sections of the .o and executable files does not work (currently)
with exception handling. This is because there is no support for
OpenPOWER on IntegriCloud