PIPS
movement_main.c File Reference
#include <stdio.h>
#include <string.h>
#include <setjmp.h>
#include "genC.h"
#include "linear.h"
#include "ri.h"
#include "complexity_ri.h"
#include "resources.h"
#include "ri-util.h"
#include "constants.h"
+ Include dependency graph for movement_main.c:

Go to the source code of this file.

Functions

 main (int argc, argv)
 

Variables

jmp_buf pips_top_level
 chunk is defined there, chunk was used by ri.h
More...
 

Function Documentation

◆ main()

main ( int  argc,
argv   
)

get NewGen data type description

case you come back from a user_error

Definition at line 42 of file movement_main.c.

45 {
46  entity mod;
47  char *program_name;
48  char *module_name;
49  char *entities_filename;
50  char *ppf_filename;
51  FILE *fd;
52  int i;
53  bool prettyprint_it = false;
54  statement s,stat;
55  cons *copy_in = NIL;
56  cons *copy_out=NIL;
57 text t;
58 
59 
60  /* get NewGen data type description */
61  gen_read_spec(ALL_SPECS, (char*) NULL);
68 
69 
70  module_name = argv[2];
71 
72  fprintf(stderr, "----------------------in main-----------------------\n");
73 
74  db_open_workspace(argv[1]);
75  if(setjmp(pips_top_level)) {
76  /* case you come back from a user_error */
78  exit(1);
79  }
80  else {
81  db_open_module(module_name);
82 
83  make(DBR_CODE, module_name);
84 
85  s = (statement) db_get_memory_resource(DBR_CODE, module_name, false);
86 
88  search_array_from_statement2(module_name,s,&copy_in,&copy_out);
89 
90 
92  user_log("I have done this: ...\n");
93  }
95  fprintf(stderr, "----------------------out of main-----------------------\n");
96 }
void user_log(const char *format,...)
Definition: message.c:234
struct _newgen_struct_statement_ * statement
Definition: cloning.h:21
const char * module_name(const char *s)
Return the module part of an entity name.
Definition: entity_names.c:296
void gen_init_external(int which, void *(*read)(FILE *, int(*)(void)), void(*write)(FILE *, void *), void(*free)(void *), void *(*copy)(void *), int(*allocated_memory)(void *))
GEN_INIT_EXTERNAL defines entry points for free, read and write functions of external types.
Definition: genClib.c:2276
void gen_read_spec(char *spec,...)
Definition: genClib.c:2218
#define NIL
The empty list (nil in Lisp)
Definition: newgen_list.h:47
string db_get_memory_resource(const char *rname, const char *oname, bool pure)
Return the pointer to the resource, whatever it is.
Definition: database.c:755
#define exit(code)
Definition: misc-local.h:54
jmp_buf pips_top_level
chunk is defined there, chunk was used by ri.h
Definition: movement_main.c:40
Pvecteur vect_gen_copy_tree(Pvecteur)
Definition: Pvecteur.c:163
void vect_gen_write(FILE *, Pvecteur)
Pvecteur.c.
Definition: Pvecteur.c:108
Pvecteur vect_gen_read(FILE *, int(*)(void))
void sc_gen_free(Psysteme)
Definition: Psc.c:198
void vect_gen_free(Pvecteur)
Definition: Pvecteur.c:158
void polynome_gen_free(Ppolynome)
Definition: Ppolynome.c:148
void polynome_gen_write(FILE *, Ppolynome)
Definition: Ppolynome.c:97
Ppolynome polynome_gen_read(FILE *, int(*)(void))
Ppolynome polynome_gen_copy_tree(Ppolynome)
Definition: Ppolynome.c:154
Psysteme sc_gen_copy_tree(Psysteme)
Definition: Psc.c:203
void sc_gen_write(FILE *, Psysteme)
Psc.c.
Definition: Psc.c:82
Psysteme sc_gen_read(FILE *, int(*)(void))
bool db_close_workspace(bool)
Definition: workspace.c:367
bool db_open_workspace(const char *)
Definition: workspace.c:380
static bool make(const char *rname, const char *oname)
Definition: pipsmake.c:893
entity local_name_to_top_level_entity(const char *n)
This function try to find a top-level entity from a local name.
Definition: entity.c:1450
int fprintf()
test sc_min : ce test s'appelle par : programme fichier1.data fichier2.data ...
#define ALL_SPECS
Definition: specs.h:1
The structure used to build lists in NewGen.
Definition: newgen_list.h:41
static void db_close_module(string what, string oname, bool do_free)
stores all resources of module oname.
Definition: workspace.c:318

References ALL_SPECS, db_close_module(), db_close_workspace(), db_get_memory_resource(), db_open_workspace(), exit, fprintf(), gen_init_external(), gen_read_spec(), local_name_to_top_level_entity(), make(), module_name(), NIL, pips_top_level, polynome_gen_copy_tree(), polynome_gen_free(), polynome_gen_read(), polynome_gen_write(), sc_gen_copy_tree(), sc_gen_free(), sc_gen_read(), sc_gen_write(), user_log(), vect_gen_copy_tree(), vect_gen_free(), vect_gen_read(), and vect_gen_write().

+ Here is the call graph for this function:

Variable Documentation

◆ pips_top_level

jmp_buf pips_top_level

chunk is defined there, chunk was used by ri.h

used by ri-util.h useful, because PPOLYNOME is defined there useful, because make is called directly by main useful, because polynome_gen_write is called
useful, because DBR_ is called directly by main

Definition at line 40 of file movement_main.c.

Referenced by main().