1 #ifdef RCSID
2 static char RCSid[] =
3 "$Header$";
4 #endif
5
6 /*
7 * Copyright (c) 1999, 2002 Michael J. Roberts. All Rights Reserved.
8 *
9 * Please see the accompanying license file, LICENSE.TXT, for information
10 * on using and copying this software.
11 */
12 /*
13 Name
14 vminitsw.cpp - VM initialization - swapping pool implementation
15 Function
16
17 Notes
18
19 Modified
20 07/21/99 MJRoberts - Creation
21 */
22
23 #include "vminit.h"
24 #include "vmpool.h"
25
26
27 /* ------------------------------------------------------------------------ */
28 /*
29 * Initialize the VM with swapping page pools
30 */
vm_init_swap(vm_globals ** vmg,size_t max_pages_in_mem,class CVmHostIfc * hostifc,class CVmMainClientIfc * clientifc,const char * charset)31 void vm_init_swap(vm_globals **vmg, size_t max_pages_in_mem,
32 class CVmHostIfc *hostifc,
33 class CVmMainClientIfc *clientifc,
34 const char *charset)
35 {
36 vm_globals *vmg__;
37
38 /* initialize the base VM structures */
39 vm_init_base(vmg, hostifc, clientifc, charset);
40
41 /*
42 * assign the global pointer to the special vmg__ local for
43 * globals-on-stack configuration
44 */
45 vmg__ = *vmg;
46
47 /* create the in-memory pools */
48 G_code_pool = new CVmPoolSwap(max_pages_in_mem);
49 G_const_pool = new CVmPoolSwap(max_pages_in_mem);
50 }
51
52