* cgraphunit.c (cgraph_decide_is_function_needed): Really return false
for nested functions in non-optimized compilation.
From-SVN: r160068
+2010-05-31 Eric Botcazou <ebotcazou@adacore.com>
+
+ * cgraphunit.c (cgraph_decide_is_function_needed): Really return false
+ for nested functions in non-optimized compilation.
+
2010-05-31 Richard Guenther <rguenther@suse.de>
* tree-ssa-structalias.c (find_func_aliases): Handle
2010-05-31 Richard Guenther <rguenther@suse.de>
* tree-ssa-structalias.c (find_func_aliases): Handle
2010-05-30 Jan Hubicka <jh@suse.cz>
* toplev.c (wrapup_global_declaration_2): Avoid creation of new varpool
2010-05-30 Jan Hubicka <jh@suse.cz>
* toplev.c (wrapup_global_declaration_2): Avoid creation of new varpool
2010-05-30 Richard Guenther <rguenther@suse.de>
2010-05-30 Richard Guenther <rguenther@suse.de>
When not optimizing, also output the static functions. (see
PR24561), but don't do so for always_inline functions, functions
When not optimizing, also output the static functions. (see
PR24561), but don't do so for always_inline functions, functions
- declared inline and nested functions. These was optimized out
+ declared inline and nested functions. These were optimized out
in the original implementation and it is unclear whether we want
to change the behavior here. */
if (((TREE_PUBLIC (decl)
in the original implementation and it is unclear whether we want
to change the behavior here. */
if (((TREE_PUBLIC (decl)
- || (!optimize && !node->local.disregard_inline_limits
+ || (!optimize
+ && !node->local.disregard_inline_limits
&& !DECL_DECLARED_INLINE_P (decl)
&& !DECL_DECLARED_INLINE_P (decl)
+ && !(DECL_CONTEXT (decl)
+ && TREE_CODE (DECL_CONTEXT (decl)) == FUNCTION_DECL)))
&& !flag_whole_program
&& !flag_lto
&& !flag_whopr)
&& !flag_whole_program
&& !flag_lto
&& !flag_whopr)
+2010-05-31 Eric Botcazou <ebotcazou@adacore.com>
+
+ * gcc.dg/nested-func-7.c: New test.
+ * gnat.dg/frame_overflow.adb: Adjust directives.
+
2010-05-30 Eric Botcazou <ebotcazou@adacore.com>
* gnat.dg/prot2.ad[sb]: New test.
2010-05-30 Eric Botcazou <ebotcazou@adacore.com>
* gnat.dg/prot2.ad[sb]: New test.
--- /dev/null
+/* { dg-do compile } */
+/* { dg-options "-fdump-tree-optimized" } */
+
+void foo (void)
+{
+ int a;
+
+ void bar (void)
+ {
+ a = 1;
+ }
+}
+
+/* { dg-final { scan-tree-dump-not "bar" "optimized" } } */
+/* { dg-final { cleanup-tree-dump "optimized" } } */
--- { dg-xfail-if "missing late warning" { *-*-* } { "-flto" } { "" } }
type Bitmap_T is record
Bits : Bitmap_Array_T := (others => False);
end record;
type Bitmap_T is record
Bits : Bitmap_Array_T := (others => False);
end record;
-
- function -- { dg-error "too large" }
Set_In (Bitmap : Bitmap_T; Bitpos : Bitpos_Range_T) return Bitmap_T
is
Result: Bitmap_T := Bitmap; -- { dg-error "Storage_Error" }
Set_In (Bitmap : Bitmap_T; Bitpos : Bitpos_Range_T) return Bitmap_T
is
Result: Bitmap_T := Bitmap; -- { dg-error "Storage_Error" }