Allocating Local Memory
During installation, the PRGSIZE configuration option is set to 512 (meaning 512 Kilobytes) in the EslConfig.ini file. This specifies that the amount of memory in kilobytes to be initially allocated to the program's .WEB file, along with any runtime expansion is 512Kb. The PRGMAX configuration option is set to 32768 (meaning 32 Megabytes) in the EslConfig.ini file, which specifies the memory space available for the program's .WEB file, along with any runtime expansion, cannot exceed 32Mb.
Whilst an ESL application is running, more physical memory can be requested from Windows, in blocks of the size specified by the MEMINCR parameter, which is initially set to 64 (meaning 64 Kilobytes). The MEMINCR is rounded up to a multiple of the system page size, as it is essential that complete system pages are allocated. The PRGSIZE and PRGMAX are also rounded up to ensure they are a multiple of the MEMINCR configuration option. Once a block of memory has been allocated to the ESL application, it is not released back to Windows until the application closes.
Depending on the amount of available physical memory, if you want to run many (or large) ESL applications or other Windows applications simultaneously, you may need to lower the PRGSIZE configuration to allow more memory for them. You can do this by editing the EslConfig.ini file or by invoking ESL with the -m command line option, which changes the PRGSIZE for this invocation only. For example:
eslrun.exe c:\eis\db.web -m 300000
If the PRGSIZE is greater than the PRGMAX specification, the PRGMAX will be increased to match the value. As the maximum amount of memory will be allocation when the ESL application is started, no further requests for physical memory will be made.
Allocating Global Memory
During installation, the GLBSIZE configuration option is set to 128 (meaning 128 Kilobytes). This specifies that the amount of memory initially allocated for global data is 128Kb. The GLBMAX configuration option is set to 32768 (meaning 32 Megabytes) in the EslConfig.ini file, which specifies the memory space available for global variables and control blocks, cannot exceed 32Mb. If this amount is not sufficient for all programs, especially if your application uses many global variables. If you need to increase the amount of space allocated to global data, you can either edit the EslConfig.ini file and change the GLBMAX entry to make the change permanent, or for individual instances, invoke ESL with the -g command line option. For example:
eslrun.exe c:\eis\db.web -g 150000
As with PRGSIZE and PRGMAX parameters, whilst an ESL application is running, more physical memory can be requested for global variables etc. from Windows, in blocks of the size specified by the MEMINCR.
PRGSIZE and GLBSIZE specify memory size in kilobytes; the -m and -g command line options specify memory size in bytes.