Xojo benchmark

Syntactically I think Vb.Net is very familiar to VB6 users, but the true cross platform capabilities of Xojo is hard to compete with. It just makes business sense to me to write once and deploy EASILY to many platforms.

One of the features sorely lacking in VB _all versions _ is autocomplete. We take it for granted, but using VB after Xojo is like driving in the night without lights.

Add to that a documentation often lacking the most elementary example, and VB can be a cruel experience.

[quote=115208:@Michel Bujardet]One of the features sorely lacking in VB _all versions _ is autocomplete. We take it for granted, but using VB after Xojo is like driving in the night without lights.

Add to that a documentation often lacking the most elementary example, and VB can be a cruel experience.[/quote]

Yes! One thing I really liked early on was the autocomplete, and for global variable names too, not just the language commands themselves. Has saved me thousands of keystrokes in the last few months.

Autocomplete is definitely one of the Xojo IDE’s most powerful features.

But this does raise an eyebrow about when LLVM will make the cut.
Its used for script already, Im sure there must be some pressing reason why it doesn’t get used for app compilation…

And oddly, these days I actually do quite a lot of coding in VBScript. (no runtimes, easy deployment, but Windows only and not forms based)

I use VBSEdit to edit the code, and guess what… autocomplete!

[quote=115265:@Jeff Tullin]But this does raise an eyebrow about when LLVM will make the cut.
Its used for script already, Im sure there must be some pressing reason why it doesn’t get used for app compilation…

And oddly, these days I actually do quite a lot of coding in VBScript. (no runtimes, easy deployment, but Windows only and not forms based)

I use VBSEdit to edit the code, and guess what… autocomplete![/quote]

LLVM has been on its way for a while, but integration within Xojo does not seem that simple. So in the meantime, using XojoScript is a nice way to enjoy the fast execution time. Search for LLVM and you will see it has been an ongoing topic for a while :wink:

Thank you for the VBSEdit pointer. Indeed the Alt-Right arrow features ressembles the Xojo Tab. I did not notice it was able to complete variable names, though. Their Snippets function is also a nice idea, not unlike the Xojo LR examples.

Too bad this exists only for VBScript. MS has still some way to go before VS gains as much ease of use as Xojo :wink:

The iOS compiler uses LLVM, so they are making progress.

[quote=115208:@Michel Bujardet]One of the features sorely lacking in VB _all versions _ is autocomplete. We take it for granted, but using VB after Xojo is like driving in the night without lights.

Add to that a documentation often lacking the most elementary example, and VB can be a cruel experience.[/quote]

I wonder what version of VS people are referring to, I use both environments daily and VS definitely has autocomplete. You may want to check your autocomplete delay settings.

The VS IDE in my opinion is superior but falls short due to being Windows only without jumping through hoops.

From someone who used to program in BASIC on a Mac IIe, RealBasic was a godsend. When Microsoft went went with VB.NET, I felt lost as so many things were changed that it all looked like Greek. I chose RealBasic not only because it was cross-platform but because most of my VB6 knowledge could still be put to use. I started with RealBasic in the early 2000’s and haven’t looked back.

My first, and only, VB6 app was a simple card library for the Yu-Gi-Oh TCG which can be found on Planet Source Code:
YuGiOh Card Library v2

I’ve since completely redesigned it in RealBasic and I am much happier.

I got 0.24 on a i7 @ 2.6 Ghz running OS X 10.9.4, using a modified version of Michel’s Xojo Script.

[code]#pragma BackgroundTasks False
#pragma DisableBoundsChecking
#pragma DisableAutoWaitCursor
#pragma StackOverflowchecking False
#pragma NilObjectChecking False

Dim x As double
Dim y As Double
Dim i As int32
Dim t As double

x = 1
y = 1.000001
t = Microseconds

For i = 1 To 100000000 step 2
x = x * y
x = x * y
Next

t = (microseconds - t)/1000000

Print “X= " + str(x) + " T= " + format(t,”#0.00")+ " Sec"
[/code]

I got 0.31 on a Quad Core Intel Xeon @ 2x2.8 Ghz running OS X 10.8.5.

Well, out of the box, yes. But if you install the CodeSmart IDE add on, it adds a ton of functionality to VB6. I still have to maintain a couple of projects in VB6, I still think the IDE is great with CodeSmart.

I was talking about the program as it comes as default. I know VB can have great add ons. Thank you for mentioning CodeSmart, though. If I ever needed to code in VB6 again (which I doubt), I will consider it :wink:

[quote=118218:@Sam Rowlands]I got 0.24 on a i7 @ 2.6 Ghz running OS X 10.9.4, using a modified version of Michel’s Xojo Script.

[code]#pragma BackgroundTasks False
#pragma DisableBoundsChecking
#pragma DisableAutoWaitCursor
#pragma StackOverflowchecking False
#pragma NilObjectChecking False

Dim x As double
Dim y As Double
Dim i As int32
Dim t As double

x = 1
y = 1.000001
t = Microseconds

For i = 1 To 100000000 step 2
x = x * y
x = x * y
Next

t = (microseconds - t)/1000000

Print “X= " + str(x) + " T= " + format(t,”#0.00")+ " Sec"
[/code][/quote]

I used the code posted by Djamel to have a good comparison with the benchmark he had conducted in different languages, but indeed, your optimization produces even more impressive results. Which is to show how beneficial XojoScript can be for long operations. Running that code on a Mac is yet another demonstration that Xojo is a fantastic cross platform solution.