diff src/share/vm/adlc/output_h.cpp @ 17791:ad3b94907eed

8030863: PPC64: (part 220): ConstantTableBase for calls between args and jvms Summary: Add ConstantTableBase node edge after parameters and before jvms. Adapt jvms offsets. Reviewed-by: kvn
author goetz
date Fri, 20 Dec 2013 13:51:14 +0100
parents 41b780b43b74
children abec000618bf
line wrap: on
line diff
--- a/src/share/vm/adlc/output_h.cpp	Mon Dec 23 10:26:08 2013 -0800
+++ b/src/share/vm/adlc/output_h.cpp	Fri Dec 20 13:51:14 2013 +0100
@@ -1665,7 +1665,15 @@
 
     if (instr->needs_constant_base() &&
         !instr->is_mach_constant()) {  // These inherit the funcion from MachConstantNode.
-      fprintf(fp,"  virtual uint           mach_constant_base_node_input() const { return req()-1; }\n");
+      fprintf(fp,"  virtual uint           mach_constant_base_node_input() const { ");
+      if (instr->is_ideal_call() != Form::invalid_type &&
+          instr->is_ideal_call() != Form::JAVA_LEAF) {
+        // MachConstantBase goes behind arguments, but before jvms.
+        fprintf(fp,"assert(tf() && tf()->domain(), \"\"); return tf()->domain()->cnt();");
+      } else {
+        fprintf(fp,"return req()-1;");
+      }
+      fprintf(fp," }\n");
     }
 
     // Allow machine-independent optimization, invert the sense of the IF test