Re: Just Faster

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

Eventually, code will run on all machines anyway.

Take "Wine" for instance.

Xanax

----- Original Message ----- 
From: <acran at readout.fsnet.co.uk>
To: "EUforum" <EUforum at topica.com>
Subject: Re: Just Faster


: 
: Hello Xanax,
: 
: What are the results of the benchmarks you have made?
: 
: These routines are Windows based as well Yes?  I assuming this from the
: kernel32 and xCopyMemory references.
: 
: While no one likes inefficent code there are always trade offs.  For
: example (on a personal preference basis) code that works unmodified on
: different platforms and/or hardware is worth more to me because I consider
: porting it to other environments.
: 
: Always write for your target audience but bear in mind you may have just
: created a "smash hit" and everyone on all those "unfashionable types of
: computer" will want to run your software and, if so, you'll be glad you put
: the platform specific stuff into one Euphoria include file smile
: 
: Rapidly prototype, robustly build for the future.
: 
: Here endeth the ramble.
: 
: Best regards,
: 
: Andy Cranston.
: 
: At 06:26 PM 12/11/02 -0500, you wrote:
: >
: >Just out of curiosity, anyone want to test the speed of these routines
: >against the built-in routines Euphoria has.
: >
: >constant
: >  xlstrlen = define_c_func(kernel32,"lstrlen",{C_POINTER},C_INT)
: >  ,xCopyMemory =
: define_c_proc(kernel32,"RtlMoveMemory",{C_POINTER,C_POINTER,C_LONG})
: >  ,xFillMemory = define_c_proc(kernel32,"RtlFillMemory",{C_LONG, C_LONG,
: C_INT})
: >
: >global procedure memCopy(atom dest, atom from, atom size)
: > c_proc(xCopyMemory,{dest, from, size})
: >end procedure
: >
: >global procedure memSet(atom dest, atom len, integer fill)
: > c_proc(xFillMemory,{dest, fill, len})
: >end procedure
: >
: >global function peek_zstring(atom lpzString)
: >  return peek({lpzString,c_func(xlstrlen,{lpzString})})
: >end function
: >
: >I would suggest that version 2.4 get rid of the console mode for windows
: >and use API directly because obviously the guys at Microsoft have teaked
: >these particular API's for max speed....hint to Rob.
: >
: >Oh yeah, Im working on getting peek, poke and allocate_string to be
: much,much faster.
: >guess you could say that these will obviously be part of my ESP
: contributions.
: >
: >Xanax
: >
: >
: >
: >
: 
: 
: 
:

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

Search



Quick Links

User menu

Not signed in.

Misc Menu