Skip to content

Commit

Permalink
moved common header files to common/
Browse files Browse the repository at this point in the history
  • Loading branch information
rmanohar committed Mar 28, 2021
1 parent a2a7014 commit f0cac7d
Show file tree
Hide file tree
Showing 80 changed files with 194 additions and 182 deletions.
8 changes: 4 additions & 4 deletions act/act.cc
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,14 @@
#include <act/tech.h>
#include "act_parse.h"
#include "act_walk_X.h"
#include <config.h>
#include "array.h"
#include <common/config.h>
#include <common/array.h>

#ifdef DEBUG_PERFORMANCE
#include "mytime.h"
#include <common/mytime.h>
#endif

#include <log.h>
#include <common/log.h>

struct command_line_defs {
char *varname;
Expand Down
1 change: 1 addition & 0 deletions act/act.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
#include <act/lang.h>
#include <act/body.h>
#include <act/value.h>
#include <common/config.h>
#include <map>
#include <unordered_set>

Expand Down
2 changes: 1 addition & 1 deletion act/act_array.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
#define __ACT_ARRAY_H__

#include <act/expr.h>
#include "list.h"
#include <common/list.h>

class ActNamespace;
class Scope;
Expand Down
10 changes: 5 additions & 5 deletions act/act_walk.extra.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,11 @@

#include <stdio.h>
#include <string.h>
#include "list.h"
#include "except.h"
#include "qops.h"
#include "misc.h"
#include "config.h"
#include <common/list.h>
#include <common/except.h>
#include <common/qops.h>
#include <common/misc.h>
#include <common/config.h>
#include <act/lang.h>
#include <act/path.h>
#include <act/namespaces.h>
Expand Down
6 changes: 3 additions & 3 deletions act/array.cc
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,9 @@
#include <act/body.h>
#include <act/value.h>
#include <string.h>
#include "list.h"
#include "misc.h"
#include "hash.h"
#include <common/list.h>
#include <common/misc.h>
#include <common/hash.h>


#if 0
Expand Down
6 changes: 3 additions & 3 deletions act/body.cc
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,9 @@
#include <act/body.h>
#include <act/value.h>
#include <string.h>
#include "misc.h"
#include "config.h"
#include "log.h"
#include <common/misc.h>
#include <common/config.h>
#include <common/log.h>

ActBody::ActBody()
{
Expand Down
2 changes: 1 addition & 1 deletion act/connect.cc
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
*/
#include <act/act.h>
#include <string.h>
#include "config.h"
#include <common/config.h>

static int set_suboffset_limit = -1;

Expand Down
4 changes: 2 additions & 2 deletions act/error.cc
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@
*/
#include <stdio.h>
#include <act/types.h>
#include "misc.h"
#include "qops.h"
#include <common/misc.h>
#include <common/qops.h>

struct err_ctxt {
const char *s;
Expand Down
4 changes: 2 additions & 2 deletions act/expr_extra.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@
**************************************************************************
*/
#include <act/expr.h>
#include <file.h>
#include <misc.h>
#include <common/file.h>
#include <common/misc.h>
#include <string.h>

/*--- WARNING: replicated here ---*/
Expand Down
2 changes: 1 addition & 1 deletion act/int.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
#ifndef __ACT_INT_H__
#define __ACT_INT_H__

#include <misc.h>
#include <common/misc.h>


#define ACT_BIGINT_BITS_ONE (8*sizeof (unsigned long))
Expand Down
4 changes: 2 additions & 2 deletions act/lang.cc
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@
#include <act/body.h>
#include <act/value.h>
#include "prs.h"
#include "qops.h"
#include "config.h"
#include <common/qops.h>
#include <common/config.h>
#include <string.h>

/*---
Expand Down
6 changes: 3 additions & 3 deletions act/lang.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@
#define __LANG_H__

#include "expr.h"
#include <mstring.h>
#include <list.h>
#include <array.h>
#include <common/mstring.h>
#include <common/list.h>
#include <common/array.h>

class ActId;

Expand Down
2 changes: 1 addition & 1 deletion act/mangle.cc
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
#include <stdarg.h>
#include <string.h>
#include <act/act.h>
#include "misc.h"
#include <common/misc.h>

/*
Code for mangling/unmangling special characters to sanitize output
Expand Down
4 changes: 2 additions & 2 deletions act/namespaces.cc
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@
#include <act/act.h>
#include <act/body.h>
#include <string.h>
#include "misc.h"
#include "array.h"
#include <common/misc.h>
#include <common/array.h>

ActNamespace *ActNamespace::global = NULL;
int ActNamespace::creating_global = 0;
Expand Down
8 changes: 4 additions & 4 deletions act/namespaces.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,10 @@
#ifndef __NAMESPACES_H__
#define __NAMESPACES_H__

#include "hash.h"
#include "list.h"
#include "bitset.h"
#include "array.h"
#include <common/hash.h>
#include <common/list.h>
#include <common/bitset.h>
#include <common/array.h>

class Act;
class ActBody;
Expand Down
11 changes: 10 additions & 1 deletion act/pass.cc
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
#include <act/tech.h>
#include <string.h>
#include <dlfcn.h>
#include "config.h"
#include <common/config.h>


ActPass::ActPass (Act *_a, const char *s)
Expand Down Expand Up @@ -275,6 +275,15 @@ ActDynamicPass::ActDynamicPass (Act *a, const char *name, const char *lib,

lib_ptr = NULL;

_d._init = NULL;
_d._run = NULL;
_d._recursive = NULL;
_d._proc = NULL;
_d._data = NULL;
_d._chan = NULL;
_d._free = NULL;
_d._done = NULL;

for (li = list_first (_sh_libs); li; li = list_next (li)) {
act_sh_passlib_info *tmp = (act_sh_passlib_info *) list_value (li);
if (strcmp (lib, tmp->lib) == 0) {
Expand Down
2 changes: 1 addition & 1 deletion act/path.c
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
#include <string.h>
#include <pwd.h>
#include <ctype.h>
#include "misc.h"
#include <common/misc.h>
#include "path.h"

static int first = 1;
Expand Down
4 changes: 2 additions & 2 deletions act/prs.cc
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@
**************************************************************************
*/
#include <stdio.h>
#include "misc.h"
#include "file.h"
#include <common/misc.h>
#include <common/file.h>
#include "expr.h"

#include "prs.h"
Expand Down
2 changes: 1 addition & 1 deletion act/prs.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@

#include <stdio.h>
#include <act/lang.h>
#include "file.h"
#include <common/file.h>
#include "treetypes.h"

#ifdef __cplusplus
Expand Down
11 changes: 7 additions & 4 deletions act/tech.cc
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@
*/
#include <stdio.h>
#include <string.h>
#include <config.h>
#include <misc.h>
#include <array.h>
#include <common/config.h>
#include <common/misc.h>
#include <common/array.h>
#include <act/act.h>
#include <act/lang.h>
#include <act/passes/netlist.h>
#include "tech.h"

#define BUF_SZ 10240
Expand Down Expand Up @@ -67,6 +67,9 @@ static void verify_range_table (const char *nm)
}
}

#define EDGE_PFET 1
#define EDGE_NFET 0

#define PTYPE EDGE_PFET
#define NTYPE EDGE_NFET

Expand Down
4 changes: 2 additions & 2 deletions act/types.cc
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@
#include <act/value.h>
#include <act/iter.h>
#include <string.h>
#include "misc.h"
#include "hash.h"
#include <common/misc.h>
#include <common/hash.h>

/**
* Create all the static members
Expand Down
2 changes: 1 addition & 1 deletion act/types.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
#include <act/namespaces.h>
#include <act/act_array.h>
#include <act/expr.h>
#include <mstring.h>
#include <common/mstring.h>
#include <act/inst.h>

class ActBody;
Expand Down
2 changes: 1 addition & 1 deletion act/wrap.cc
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
#include "act_walk_X.h"
#include "act_parse_int.h"
#include <act/lang.h>
#include "config.h"
#include <common/config.h>

static char **dev_flavors = NULL;
static int num_devs = -1;
Expand Down
2 changes: 2 additions & 0 deletions common/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ SHLIB1=libvlsilib_sh_$(EXT).so

TARGETLIBS=$(LIB1) $(LIB2) $(LIB3) $(LIB4) $(SHLIB1) $(SHLIB4)

TARGETINCSUBDIR=common

TARGETINCS=array.h bitset.h misc.h hash.h qops.h config.h atrace.h \
avl.h lzw.h lex.h file.h heap.h except.h pp.h list.h bool.h \
names.h mstring.h mytime.h \
Expand Down
2 changes: 1 addition & 1 deletion common/agraph.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
#define __ACT_GRAPH_H__

#include <iterator>
#include "array.h"
#include <common/array.h>

class AGinfo {
public:
Expand Down
2 changes: 1 addition & 1 deletion common/array.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
#ifndef __ARRAY_H__
#define __ARRAY_H__

#include "misc.h"
#include <common/misc.h>

/*
*
Expand Down
2 changes: 1 addition & 1 deletion common/atrace.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
#ifndef __ATRACE_H__
#define __ATRACE_H__

#include "hash.h"
#include <common/hash.h>

#ifdef __cplusplus
extern "C" {
Expand Down
2 changes: 1 addition & 1 deletion common/ext.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
#define __EXT_FILE_H__

#include <stdio.h>
#include "hash.h"
#include <common/hash.h>

#ifdef __cplusplus
extern "C" {
Expand Down
2 changes: 1 addition & 1 deletion common/file.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
#define __FILE_H__

#include <stdio.h>
#include "lex.h"
#include <common/lex.h>

#ifdef __cplusplus
extern "C" {
Expand Down
4 changes: 2 additions & 2 deletions common/log.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@
*/
#include <stdio.h>
#include <iostream>
#include "mytime.h"
#include "sim.h"
#include <common/mytime.h>
#include <common/sim.h>

using std::ostream;

Expand Down
2 changes: 1 addition & 1 deletion common/mem.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@

#include <stdio.h>
#include <stdlib.h>
#include "machine.h"
#include <common/machine.h>

/*
* Physical memory: Assumes big-endian format!
Expand Down
2 changes: 1 addition & 1 deletion common/mutex.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
#ifndef __MUTEX_H__
#define __MUTEX_H__

#include "thread.h"
#include <common/thread.h>

#ifdef __cplusplus
extern "C" {
Expand Down
8 changes: 4 additions & 4 deletions common/sim.h
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,10 @@
*
*/
#include <stdio.h>
#include "misc.h"
#include "mytime.h"
#include "hconfig.h"
#include "machine.h"
#include <common/misc.h>
#include <common/mytime.h>
#include <common/hconfig.h>
#include <common/machine.h>

class Sim {
public:
Expand Down
Loading

0 comments on commit f0cac7d

Please sign in to comment.