X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=ir%2Fir%2Firopt_dbg.h;h=7d0d5f7a13b76088b2190474d2be5c31e6cbde7d;hb=a09e658c8142719ef2be114547455bb5a68f480d;hp=44e47e8bc9b588ca712e1b1e4c40aae035b0db5d;hpb=0dff1e408fcf06c3d6701cc5969a037caeb38195;p=libfirm diff --git a/ir/ir/iropt_dbg.h b/ir/ir/iropt_dbg.h index 44e47e8bc..7d0d5f7a1 100644 --- a/ir/ir/iropt_dbg.h +++ b/ir/ir/iropt_dbg.h @@ -29,13 +29,10 @@ * @param oldn the block that it is eliminated * @param n the new node for this block, may be equal to oldn */ -#define DBG_OPT_DEAD_BLOCK(oldn, n) \ - do { \ - ir_node *ons[2]; \ - ons[0] = oldn; \ - ons[1] = get_Block_cfgpred(oldn, 0); \ - hook_merge_nodes(&n, 1, ons, SIZ(ons), HOOK_OPT_DEAD_BLOCK); \ - __dbg_info_merge_sets(&n, 1, ons, SIZ(ons), dbg_dead_code); \ +#define DBG_OPT_DEAD_BLOCK(oldn, n) \ + do { \ + hook_merge_nodes(&n, 1, &oldn, 1, HOOK_OPT_DEAD_BLOCK); \ + __dbg_info_merge_pair(n, oldn, dbg_dead_code); \ } while(0) @@ -156,7 +153,7 @@ } while(0) /** - * Merge the debuig info due to a Phi optimization. + * Merge the debug info due to a Phi optimization. * A Phi node was replaced by one of its input (the only meaningful) * * @param phi the Phi node that will be replaced @@ -169,6 +166,20 @@ } while(0) +/** + * Merge the debug info due to a Sync optimization. + * A Sync node was replaced by one of its input (the only meaningful) + * + * @param sync the Sync node that will be replaced + * @param n in Sync Input that will replace Sync + */ +#define DBG_OPT_SYNC(sync, n) \ + do { \ + hook_merge_nodes(&n, 1, &sync, 1, HOOK_OPT_SYNC); \ + __dbg_info_merge_sets(&n, 1, &sync, 1, dbg_opt_ssa); \ + } while(0) + + /** * Merge the debug info due to Write-after-Write optimization: * Store oldst will be removed, because Store st overwrites it. @@ -254,7 +265,7 @@ * Merge the debug info after a tuple optimization. * a Proj(Tuple) is replaced by the associated tuple value. * - * @param oldn the Proj node + * @param proj the Proj node * @param tuple the Tuple node * @param n the Proj(Tuple) value */ @@ -332,7 +343,7 @@ * A node was replaced by a constant due to a Confimation. * * @param oldn the old node - * @param c the new constnt node + * @param c the new constant node */ #define DBG_OPT_CONFIRM_C(oldn, c) \ do { \ @@ -340,6 +351,16 @@ __dbg_info_merge_pair(c, oldn, dbg_opt_confirm); \ } while(0) +/** + * A exception exdge was removed due to a Confirmation prove. + * + * @param oldn the old node + */ +#define DBG_OPT_EXC_REM(oldn) \ + do { \ + hook_merge_nodes(NULL, 0, &oldn, 1, HOOK_OPT_EXC_REM); \ + } while(0) + /** * A node could be evaluated to a value due to a Confirm. * This will lead to a constant evaluation.