Removed last change, did not work with fltcalc
[libfirm] / ir / ir / irvrfy.c
index 68342bb..608c4f2 100644 (file)
@@ -391,6 +391,7 @@ vrfy_Proj_proj(ir_node *p, ir_graph *irg) {
       if (proj == pn_Load_res) {
        ir_node *ptr = get_Load_ptr(pred);
        entity *ent = get_ptr_entity(ptr);
+
        if (vrfy_entities && ent && get_irg_phase_state(current_ir_graph) == phase_high) {
          /* do NOT check this for lowered phases, see comment on Store */
          ASSERT_AND_RET_DBG(
@@ -401,7 +402,7 @@ vrfy_Proj_proj(ir_node *p, ir_graph *irg) {
        }
        else {
          ASSERT_AND_RET_DBG(
-                            mode_is_data(mode),
+                            mode_is_data(mode) && mode == get_Load_mode(pred),
                             "wrong data Proj from Load", 0,
                             show_proj_failure(p);
                             );
@@ -744,12 +745,17 @@ int irn_vrfy_irg(ir_node *n, ir_graph *irg)
       /* Call: BB x M x ref x data1 x ... x datan
          --> M x datan+1 x ... x data n+m */
       ASSERT_AND_RET( op1mode == mode_M && mode_is_reference(op2mode), "Call node", 0 );  /* operand M x ref */
+
+      mt = get_Call_type(n);
+      if(get_unknown_type() == mt) {
+       break;
+      }
+
       for (i=3; i < get_irn_arity(n); i++) {
         ASSERT_AND_RET( mode_is_data(get_irn_mode(in[i])), "Call node", 0 );  /* operand datai */
       };
       ASSERT_AND_RET( mymode == mode_T, "Call result not a tuple", 0 );   /* result T */
       /* Compare arguments of node with those of type */
-      mt = get_Call_type(n);
 
       if (get_method_variadicity(mt) == variadicity_variadic) {
         ASSERT_AND_RET_DBG(