This is the mail archive of the cgen@sources.redhat.com mailing list for the CGEN project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Patch to add ifield number to cgen_operand (1/2)


Richard,

In cgen_ifield_lookup_by_num, how about testing the assertion that `ifnum'
is within range?

Ben

   ****************
   *** 298,303 ****
   --- 298,313 ----
       return NULL;
     }

   + /* Instruction fields.  */
   +
   + const CGEN_IFLD *
   + cgen_ifield_lookup_by_num (cd, ifnum)
   +      CGEN_CPU_DESC cd;
   +      unsigned int ifnum;
   + {
   +   return &cd->ifld_table[ifnum];
   + }
   +
     /* Operand support.  */

     /* Lookup an operand by its name.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]