Re: I need a memory eater

new topic     » goto parent     » topic index » view thread      » older message » newer message

Craig Gilbert wrote:

> At 05:50 PM 10/21/97 -0700, you wrote:
> >On Tue, 21 Oct 1997, James Powell wrote:
> >> You might just edit the msdos session properties for the program
> you
> >> are testing, assuming you are using win95 or os/2, and not dos.
> (This
> >> will work under os/2, but I'm not sure what steps to go through)
> >
> >I use DOS only.  win95 sucks.

    It sure does, did you know MS pays gaming companies money to develop
their games for win95, examples are: -All Sega Games- (Sega Rally, SOnic
& Knuckles) Destruction Derby 2, Need4Speed  2, Pod, etc.    And all
those games run a lot smoother on DOS, but know their Win95-only, thank
god Carmageddon isn't Win95 only!!
    For this I hate but has to use win95....

>         Why not write your own memory eater in euphoria?  have it
> accept on the
> command line two parameters:  bytes/kbytes to eat and the name of the
> program to run after mem has been eaten.
>         Then allocate bytes/kbytes and lock them; they should be then
> 'eaten'.
>         Then execute the program you want to test via system().
>
>         The only thing  i'm not sure of is how to tell how much memory
> has already
> been used up by the euphoria session instigated by the memory eater
> program
> (i.e. how much used up before allocation).  I imagine something of
> Jacques
> Deschenes' addresses that.

Do it the other way around, have a program with 2 command line
parametes: how much memory should be available: XMS-LOW-EMS-etc.Use
Jaques Deschenes routine to figure out how much memory available is, and
allocate (either high or low, you should specify this) the memory that
we don't want to be able to acces.
If you put all this in *one* routine, Euphoria will not change the
amount of memory available. (that is, before checking thus) Also note
that you should give the atoms that hold the amount of memory available,
a 31-bit integer value already (else more memory is allocate after the
checking for available memory, because the 4-byte integer is converted
to 31-bit-integer.

I think this should work.... .. try!

Ralf Nieuwenhuijsen
nieuwen at xs4all.nl

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu