+2010-09-07 Richard Henderson <rth@redhat.com>
+
+ * target.def (unwind_emit_before_insn): New hook.
+ * doc/tm.texi.in: Add @hook marker for it.
+ * doc/tm.texi: Rebuild.
+ * final.c (final_scan_insn): Respect unwind_emit_before_insn.
+
2010-09-07 Martin Jambor <mjambor@suse.cz>
PR fortran/43665
2010-09-07 Jan Hubicka <jh@suse.cz>
- * tree-ssa-ccp.c (fold_const_aggregate_ref): Fix handling of array_ref_low_bound
- in string access folding.
+ * tree-ssa-ccp.c (fold_const_aggregate_ref): Fix handling of
+ array_ref_low_bound in string access folding.
2010-09-07 Uros Bizjak <ubizjak@gmail.com>
given instruction. This is only used when TARGET_UNWIND_INFO is set.
@end deftypefn
+@deftypevr {Target Hook} bool TARGET_ASM_UNWIND_EMIT_BEFORE_INSN
+True if the @code{TARGET_ASM_UNWIND_EMIT} hook should be called before the assembly for @var{insn} has been emitted, false if the hook should be called afterward.
+@end deftypevr
+
@node Exception Region Output
@subsection Assembler Commands for Exception Regions
given instruction. This is only used when TARGET_UNWIND_INFO is set.
@end deftypefn
+@hook TARGET_ASM_UNWIND_EMIT_BEFORE_INSN
+
@node Exception Region Output
@subsection Assembler Commands for Exception Regions
/* ??? This will put the directives in the wrong place if
get_insn_template outputs assembly directly. However calling it
before get_insn_template breaks if the insns is split. */
- if (targetm.asm_out.unwind_emit)
+ if (targetm.asm_out.unwind_emit_before_insn
+ && targetm.asm_out.unwind_emit)
targetm.asm_out.unwind_emit (asm_out_file, insn);
if (CALL_P (insn))
dwarf2out_frame_debug (insn, true);
#endif
+ if (!targetm.asm_out.unwind_emit_before_insn
+ && targetm.asm_out.unwind_emit)
+ targetm.asm_out.unwind_emit (asm_out_file, insn);
+
current_output_insn = debug_insn = 0;
}
}
void, (FILE *stream, rtx insn),
NULL)
+DEFHOOKPOD
+(unwind_emit_before_insn,
+ "True if the @code{TARGET_ASM_UNWIND_EMIT} hook should be called before\
+ the assembly for @var{insn} has been emitted, false if the hook should\
+ be called afterward.",
+ bool, true)
+
/* Output an internal label. */
DEFHOOK
(internal_label,