VPR-7.0
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros
libarchfpga/main.c File Reference
#include <stdio.h>
#include <stdlib.h>
#include "read_xml_arch_file.h"
+ Include dependency graph for libarchfpga/main.c:

Go to the source code of this file.

Functions

void print_help ()
 
int main (int argc, char **argv)
 

Function Documentation

int main ( int  argc,
char **  argv 
)

Definition at line 15 of file libarchfpga/main.c.

15  {
16  struct s_arch arch;
17  t_type_descriptor *types;
18  int numTypes;
19  ;
20 
21  if (argc - 1 != 3) {
22  printf(
23  "Error: Unexpected # of arguments. Expected 3 found %d arguments\n",
24  argc);
25  print_help();
26  }
27 
28  printf(
29  "------------------------------------------------------------------------------\n");
30  printf(
31  "- Read architecture file and print library data structures into an output file\n");
32  printf(
33  "------------------------------------------------------------------------------\n\n");
34 
35  printf("Inputs: \n"
36  "architecture %s \n"
37  "timing_driven %d \n"
38  "output file %s\n", argv[1], atoi(argv[2]), argv[3]);
39  printf("Reading in architecture\n");
40 
41  /* function declarations */
42  XmlReadArch(argv[1], (boolean) atoi(argv[2]), &arch, &types, &numTypes);
43 
44  printf("Printing Results\n");
45 
46  EchoArch(argv[3], types, numTypes, &arch);
47 
48  printf("Done\n");
49 
50  return 0;
51 }
void EchoArch(INP const char *EchoFile, INP const t_type_descriptor *Types, INP int NumTypes, struct s_arch *arch)
void XmlReadArch(INP const char *ArchFile, INP boolean timing_enabled, OUTP struct s_arch *arch, OUTP t_type_descriptor **Types, OUTP int *NumTypes)
void print_help()

+ Here is the call graph for this function:

void print_help ( )

Definition at line 53 of file libarchfpga/main.c.

53  {
54  printf(
55  "\n---------------------------------------------------------------------------------------\n");
56  printf(
57  "read_arch: Read a VPR architecture file and output internal data structures");
58  printf(
59  "Usage: read_arch <arch_file.xml> <timing_driven (0|1)> <output_file>\n");
60  printf(" ex: read_arch k4_n10.xml 1 arch_data.out\n");
61  printf(
62  " Read timing-driven architecture k4_n10.xml and output the results to arch_data.out\n");
63  printf(
64  "\n---------------------------------------------------------------------------------------\n");
65 }

+ Here is the caller graph for this function: