GCC Middle and Back End API Reference
genflags.c File Reference


static void max_operand_1 (rtx)
static int num_operands (rtx)
static void gen_proto (rtx)
static void gen_macro (const char *, int, int)
static void gen_insn (int, rtx)
static void max_operand_1 ()
static int num_operands ()
static void gen_macro ()
static void gen_proto ()
static void gen_insn ()
int main ()


static struct obstack obstack
static int max_id_len
static int max_opno

Function Documentation

static void gen_insn ( int  ,
static void gen_insn ( )
     Don't mention instructions whose names are the null string
     or begin with '*'.  They are in the machine description just
     to be recognized.  
       Emit nothing.  
         Write the macro definition, putting \'s at the end of each line,
         if more than one.  

References have_error, and message_with_line().

static void gen_macro ( const char *  ,
int  ,

Referenced by gen_proto().

static void gen_macro ( )
   Print out a wrapper macro for a function which corrects the number
   of arguments it takes.  Any missing arguments are assumed to be at
   the end.  
     #define GEN_CALL(A, B, C, D) gen_call((A), (B)) 
static void gen_proto ( rtx  )
static void gen_proto ( )
   Print out prototype information for a generator function.  If the
   insn pattern has been elided, print out a dummy generator that
   does nothing.  
     Many md files don't refer to the last two operands passed to the
     call patterns.  This means their generator functions will be two
     arguments too short.  Instead of changing every md file to touch
     those operands, we wrap the prototypes in macros that take the
     correct number of arguments.  
     Some back ends want to take the address of generator functions,
     so we cannot simply use #define for these dummy definitions.  

References gen_macro().

int main ( )
     We need to see all the possibilities.  Elided insns may have
     direct calls to their generators in C code.  
     Read the machine description.  
     Print out the prototypes now.  
static void max_operand_1 ( rtx  )
static void max_operand_1 ( )
   Count the number of match_operand's found.  
static int num_operands ( rtx  )
static int num_operands ( )

Variable Documentation

int max_id_len
   Max size of names encountered.  
int max_opno
   Max operand encountered in a scan over some insn.  
struct obstack obstack

Generate from machine description:

  • some flags HAVE_... saying which simple standard instructions are available for this machine. Copyright (C) 1987-2013 Free Software Foundation, Inc.

This file is part of GCC.

GCC is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3, or (at your option) any later version.

GCC is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with GCC; see the file COPYING3. If not see http://www.gnu.org/licenses/.

   Obstack to remember insns with.