VBA speed on the Intel-chip Macs: Any faster?

J

jvbeaupre

I'm a dedicated Mac and Excel and VBA user.

Right now my current Mac (1-GHz PowerPC) is about 10x slower than the
comparable windows machine for executing VBA macros in Excel.

My question is: Do the new Intel-chip Macs do VBA any faster than the
PowerPCs? (Scaled by processor speed, of course)

Anyone interested in helping me do the comparison by doing the
benchmark below on an Intel-chip Mac?

Here's the results (printed in the immediate window) for a 1-GHz
PowerPC G4 executioning the VBA code at the bottom:

1D: n= 100 Time= 7 -sec
1D: n= 200 Time= 24 -sec
1D: n= 400 Time= 97 -sec

Hoping to hear from some of you,
Jim

'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
Sub TEST_NN1DBF()
Dim d(), id()

ntrial = 100
n0 = 50
For m = 1 To 3
n = n0 * 2 ^ m
ReDim d(n), id(n)

t1 = Timer
For ii = 1 To ntrial
GoSub Get_Data_1
GoSub Eval_1
Next ii
Debug.Print "1D: n="; n, "Time="; Timer - t1
Next m
Exit Sub

Get_Data_1:
For i = 1 To n
d(i) = (1000 * Rnd())
Next i
Return

Eval_1: 'Brute force Nearest Neighbor ~ n^2 in execution time
For i = 1 To n
umin = 1e+37
x1 = d(i)
For j = 1 To n
If j <> i Then
If Abs(x1 - d(j)) < umin Then
umin = Abs(x1 - d(j))
id(i) = j
End If
End If
Next j
Next i
Return

End Sub
 
B

Bernard Rey

As you may know from the mactopia page, the current version of Office for
the Mac has not been (and won't be) re-written to Universal Binary. It runs
through Rosetta which is a PowerPC emulator, so it can't be running faster
than it would on a G5.

In the independent study by MacTech Magazine (link is on the mactopia page),
you'll see the results comparing MacIntels and a PowerBook.

http://www.microsoft.com/mac/default.aspx?pid=macIntelQA

If you really want to have the macros run fast on a MacIntel, just run the
Windows version through Parallels Desktop or BootCamp ;-)


--
Bernard Rey - Toulouse / France
MVP - office:macintosh http://faq.office.macintosh.free.fr



(e-mail address removed) :
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top