Remove HTemporary when building the SSA graph.

- They are useless afterwards. If we keep them around, they can
  crash the dump of the graph, where they always assume a previous
  instruction.

- In the call to HTemporary::GetType, check that the previous
  instruction exists.

Change-Id: Ie7bf44d05cb61e3654a69725c1980925580dd3a6
diff --git a/compiler/optimizing/ssa_builder.cc b/compiler/optimizing/ssa_builder.cc
index e83c528..fec40f9 100644
--- a/compiler/optimizing/ssa_builder.cc
+++ b/compiler/optimizing/ssa_builder.cc
@@ -253,4 +253,9 @@
   instruction->SetEnvironment(environment);
 }
 
+void SsaBuilder::VisitTemporary(HTemporary* temp) {
+  // Temporaries are only used by the baseline register allocator.
+  temp->GetBlock()->RemoveInstruction(temp);
+}
+
 }  // namespace art