Currently job artifacts in CI/CD pipelines on LRZ GitLab never expire. Starting from Wed 26.1.2022 the default expiration time will be 30 days (GitLab default). Currently existing artifacts in already completed jobs will not be affected by the change. The latest artifacts for all jobs in the latest successful pipelines will be kept. More information: https://gitlab.lrz.de/help/user/admin_area/settings/continuous_integration.html#default-artifacts-expiration

mmix-vmb.c 2.45 KB
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
#include <string.h>
#include <signal.h>
#include <setjmp.h>
#include "abstime.h"
#include "libconfig.h"
#include <time.h>
#include "libtype.h"
#include "libglobals.h"
#include "mmixlib.h"
#include "address.h"
#include "mmix-bus.h"
15
#include "breaks.h"
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
#include "vmb.h"
device_info vmb = {0};
static char localhost[]="localhost";
static int busport=9002; /* on which port to connect to the bus */
static char *bushost=localhost; /* on which host to connect to the bus */


int main(argc,argv)
  int argc;
  char *argv[];
{
  char **boot_cur_arg;
  int boot_argc;
  g[255].h=0;
  g[255].l=setjmp(mmix_exit);
  if (g[255].l!=0)
   goto end_simulation;
  mmix_lib_initialize();
  mmix_commandline(argc,argv);

  if (bushost==NULL) panic("No Bus given. Use Option -B[host:]port");
  init_mmix_bus(bushost,busport,"MMIX CPU");

  mmix_initialize();
 
  boot_cur_arg = cur_arg;
  boot_argc = argc;
  if (vmb.power)  
    vmb_raise_reset(&vmb);

boot:

  argc = boot_argc;
  cur_arg = boot_cur_arg;
  
  fprintf(stderr,"Power...");
  while (!vmb.power)
  {  vmb_wait_for_power(&vmb);
     if (!vmb.connected) goto end_simulation;
  }
  fprintf(stderr,"ON\n");
  MMIX_CLEAR_DVTC();
  MMIX_CLEAR_IVTC();
  MMIX_CLEAR_DCACHE();
  MMIX_CLEAR_ICACHE();

  mmix_boot();
  mmix_load_file(*cur_arg);
  mmix_commandline(argc, argv);
  write_all_data_cache();
  clear_all_instruction_cache();
  if (interacting) set_break(g[rWW],exec_bit);

  while (true) {
    if (interrupt && !breakpoint) breakpoint=interacting=true, interrupt=false;
    else if (!(inst_ptr.h&sign_bit) || show_operating_system || 
          (inst_ptr.h==0x80000000 && inst_ptr.l==0))
    { breakpoint=false;
      if (interacting)
		if (!mmix_interact()) goto end_simulation;
    }
    if (halted) break;
    { if (!resuming)
        mmix_fetch_instruction();       
      mmix_perform_instruction();
      mmix_trace();
      mmix_dynamic_trap();
      if (resuming && op!=RESUME) resuming=false; 
84
      if (!resuming && (!vmb.power||!vmb.reset)) break; 
85
86
87
88
89
90
91
92
93
94
95
96
    } while (resuming || (!interrupt && !breakpoint));
    if (interact_after_break) 
       interacting=true, interact_after_break=false;
    if (!vmb.power||(g[rQ].l&g[rK].l&RE_BIT))
      goto boot;
  }
  end_simulation: if (profiling) mmix_profile();
  if (interacting || profiling || showing_stats) show_stats(true);
  mmix_finalize();
  mmix_lib_finalize();
  return g[255].l; /* provide rudimentary feedback for non-interactive runs */
}