+2007-07-01 Daniel Berlin <dberlin@dberlin.org>
+
+ * tree-ssa-sccvn.c (copy_reference_ops_from_ref): Handle constants
+ and other expected operations explicitly, change default to
+ gcc_unreachable.
+
2007-07-01 Daniel Jacobowitz <dan@codesourcery.com>
* config/arm/arm.c (arm_cannot_copy_insn_p): Do not expect a
temp.op0 = TREE_OPERAND (ref, 1);
temp.op1 = TREE_OPERAND (ref, 3);
break;
+ case STRING_CST:
+ case INTEGER_CST:
+ case COMPLEX_CST:
+ case VECTOR_CST:
case VALUE_HANDLE:
case VAR_DECL:
case PARM_DECL:
case SSA_NAME:
temp.op0 = ref;
break;
- default:
+ /* These are only interesting for their operands, their
+ existence, and their type. They will never be the last
+ ref in the chain of references (IE they require an
+ operand), so we don't have to put anything
+ for op* as it will be handled by the iteration */
+ case IMAGPART_EXPR:
+ case REALPART_EXPR:
+ case VIEW_CONVERT_EXPR:
+ case ADDR_EXPR:
break;
+ default:
+ gcc_unreachable ();
+
}
VEC_safe_push (vn_reference_op_s, heap, *result, &temp);
- if (REFERENCE_CLASS_P (ref))
+ if (REFERENCE_CLASS_P (ref) || TREE_CODE (ref) == ADDR_EXPR)
ref = TREE_OPERAND (ref, 0);
else
ref = NULL_TREE;