home *** CD-ROM | disk | FTP | other *** search
- /* soup_in.h 28-10-91 Artificial Life simulator setup routines */
- /** Tierra Simulator V3.0: Copyright (c) 1991 Thomas S. Ray **/
-
- #include "license.h"
-
- /*
- #ifndef lint
- static char sccsid[] = "@(#)soup_in.h 1.4 10/8/91";
- #endif
- */
-
- #ifndef SOUP_IN_H
- #define SOUP_IN_H
-
- I32s alive = 100; /* how many millions of instruction will we run */
- I32s BrkupSiz = 5120; /* size of output file in K: break.1, break.2 ... */
- I32s CellsSize = 300; /* initial size of cells array of structures */
- I32s debug = 0; /* 0 = off, 1 = on, printf statements for debugging */
- I32s DiskOut = 1; /* output data to disk (1 = on, 0 = off) */
- float DistFreq = 1; /* frequency of disturbance, factor of recovery time */
- float DistProp = .2; /* proportion of population affected by distrubance */
- I32s DivSameSiz = 0; /* produce offspring of same size, stop size change */
- I32s DivSameGen = 0; /* produce offspring of same genotype, stop evolution */
- I32s DropDead = 5; /* stop system if no reproduction in the last x million */
- I32s GeneBnker = 1; /* turn genebanker on and off */
- I8s GenebankPath[80] = "geneban1/"; /* path for genebanker output */
- float GenPerBkgMut = 24.; /* mut rate control by generations ("cosmic ray") */
- float GenPerFlaw = 48.; /* flaw control by generations */
- float GenPerMovMut = 12.;/* mutation rate control by generations (copy mut) */
- I32s hangup = 1; /* 0 = exit on error, 1 = hangup on error for debugging */
- I32s MaxFreeBlocks = 500; /* initial # of structure for memory allocation */
- float MaxMalMult = 3; /* multiple of cell size allowed for mal() */
- I32s MinCellSize = 8; /* minimum size for cells */
- I32s MinTemplSize = 3; /* minimum size for templates */
- float MovPropThrDiv = .7; /* min proportion of daughter cell filled by mov */
- I32s new_soup = 1; /* 1 = this a new soup, 0 = restarting an old run */
- I32s NumCells = 1; /* # of creatures and gaps used to inoculate new soup */
- I8s OutPath[80] = "tiedat/"; /* path for data output */
- double PhotonPow = 1.5; /* power for photon match slice size */
- I32s PhotonWidth = 8; /* amount by which photons slide to find best fit */
- I8s PhotonWord[80] = "chlorophill"; /* word used to define photon */
- I32s RamBankSiz = 30000; /* max num genotypes in ram, use with genebanker */
- I32s SaveFreq = 100; /* frequency of saving core_out, soup_out and list */
- float SavThrMem = .015; /* threshold memory occupancy to save genotype */
- float SavThrPop = .015; /* threshold population proportion to save genotype */
- Ind SearchLimit = 5; /* */
- I32s seed = 0;/* seed for random number generator, 0 uses time to set seed */
- I32s SizDepSlice = 1; /* set slice size by size of creature */
- double SlicePow = 1; /* set power for slice size, use when SizDepSlice = 1 */
- I32s SliceSize = 25; /* slice size when SizDepSlice = 0 */
- I32s SliceStyle = 2; /* choose style of determining slice size */
- float SlicFixFrac = 0; /* fixed fraction of slice size */
- float SlicRanFrac = 2; /* random fraction of slice size */
- Ind SoupSize = 40000; /* size of soup in instructions */
- I32s WatchExe = 0; /* mark executed instructions in genome in genebank */
- I32s WatchMov = 0; /* set mov bits in genome in genebank */
- I32s WatchTem = 0; /* set template bits in genome in genebank */
-
- /* an edited version of the id[INSTNUM] array must be created and placed in
- the arginst.h file, for use by the assembler/disassembler of arg.c */
-
- #if INST == 1
-
- struct InstDef id[INSTNUM] =
- {{ 0x00, "nop_0", nop, pnop },
- { 0x01, "nop_1", nop, pnop },
- { 0x02, "or1", or1, por1 },
- { 0x03, "shl", shl, pshl },
- { 0x04, "zero", movdd, pzero },
- { 0x05, "if_cz", if_cz, pif_cz },
- { 0x06, "sub_ab", math, psub_ab },
- { 0x07, "sub_ac", math, psub_ac },
- { 0x08, "inc_a", math, pinc_a },
- { 0x09, "inc_b", math, pinc_b },
- { 0x0a, "dec_c", math, pdec_c },
- { 0x0b, "inc_c", math, pinc_c },
- { 0x0c, "push_ax", push, ppush_ax },
- { 0x0d, "push_bx", push, ppush_bx },
- { 0x0e, "push_cx", push, ppush_cx },
- { 0x0f, "push_dx", push, ppush_dx },
- { 0x10, "pop_ax", pop, ppop_ax },
- { 0x11, "pop_bx", pop, ppop_bx },
- { 0x12, "pop_cx", pop, ppop_cx },
- { 0x13, "pop_dx", pop, ppop_dx },
- { 0x14, "jmp", adr, ptjmp },
- { 0x15, "jmpb", adr, ptjmpb },
- { 0x16, "call", tcall, ptcall },
- { 0x17, "ret", pop, pret },
- { 0x18, "mov_cd", movdd, pmov_dc },
- { 0x19, "mov_ab", movdd, pmov_ba },
- { 0x1a, "mov_iab", movii, pmov_iab },
- { 0x1b, "adr", adr, padr },
- { 0x1c, "adrb", adr, padrb },
- { 0x1d, "adrf", adr, padrf },
- { 0x1e, "mal", malchm, pmal },
- { 0x1f, "divide", divide, pdivide }};
-
- #endif /* INST == 1 */
-
- #endif
-