Index: osprey/be/cg/x8664/cgtarget.cxx
===================================================================
--- osprey/be/cg/x8664/cgtarget.cxx     (revision 3796)
+++ osprey/be/cg/x8664/cgtarget.cxx     (working copy)
@@ -4040,6 +4043,15 @@

 TN* CGTARG_Gen_Dedicated_Subclass_TN( OP* op, int idx, BOOL is_result )
 {
+  // If idx is out of fixed number of operands or results, there is no
+  // register set info in the targ_info for the op. In this case, return
+  // tn if it is dedicated.
+  int opnd_result_cnt = is_result ? OP_fixed_results(op) : OP_fixed_opnds(op);
+  if (idx >= opnd_result_cnt) {
+    TN* tn = is_result ? OP_result( op, idx ) : OP_opnd( op, idx );
+    return TN_is_dedicated(tn) ? tn : NULL;
+  }
+
   const ISA_REGISTER_SUBCLASS subclass = is_result ?
     OP_result_reg_subclass( op, idx ) : OP_opnd_reg_subclass( op, idx );
   const REGISTER_SET subclass_regs = REGISTER_SUBCLASS_members(subclass);
