Subject: Re: [stella] A warning to newbies -- every cycle becomes sacred! From: "Matthew Ozor" <matt@xxxxxxxx> Date: Tue, 6 May 2003 10:30:30 -0400 |
Visual Basic is for writing programs faster not writing fast programs. Worrying about cycles in 2 GHZ machines is unnecessary. In VB you have no control on cycles, timing depends on other applications and which ones have priority. I know what your saying programming makes you think different.. so take a week off evernow and then :-) ----- Original Message ----- From: "RUFFIN BAILEY" <rufbo1@xxxxxxxxxxx> To: <stella@xxxxxxxxxxx> Sent: Tuesday, May 06, 2003 10:00 AM Subject: [stella] A warning to newbies -- every cycle becomes sacred! > For newbies that haven't written a line of 2600 asm (not that that puts > you that far behind me), be careful! After you've started counting > cycles and working with 128 bytes of RAM, it's hard to go back "to real > life". > > Just today I found myself commenting somebody else's code and seeing > this line of VB6 over and over in a particular function: > > If Err.Number <> 0 Then Err.Clear > > Hrm. If err.number isn't 0, make it 0. Couldn't you save cycles -- and > make things easier to count -- by just err.clear-ing each time without > the if-check? Aren't cycles sacred too? And then the big question has > to come up, "Are cycles more sacred than bits?" > > Of course I think Err.Clear-ing each time makes for easier to read code > as well, and a simple "On Error Resume Next" followed by a single > Err.Clear at the end with a restart of error handling (in this case, it > factors to the same thing) is best, but I'm overly anal when it comes to > this sort of thing. > > Thanks so much, Stella. ;^) > > Ruffin Bailey > > -------------------------------------------------------------------------- -------------------- > Archives (includes files) at http://www.biglist.com/lists/stella/archives/ > Unsub & more at http://www.biglist.com/lists/stella/ ---------------------------------------------------------------------------------------------- Archives (includes files) at http://www.biglist.com/lists/stella/archives/ Unsub & more at http://www.biglist.com/lists/stella/
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[stella] A warning to newbies -- ev, RUFFIN BAILEY | Thread | Re: [stella] A warning to newbies -, Mark Graybill |
[stella] A warning to newbies -- ev, RUFFIN BAILEY | Date | Re: [stella] A warning to newbies -, Dennis Debro |
Month |