Am a big fan of PB and have been using it for a while and will keep using it when necessary, but there are certain limitations we've experienced while doing the prototype and VB.NET addresses them nicely. I'm pretty sure you all are aware of them, but here are some I find really annoying:
1. IDE (PB has a compact, swift and easy to use environment, but I find it rather basic for such a huge project we're doing)
2. Gadgets (Hands down VB.NET has a lot more to offer here and unless you want to rely on third-party developers PB fails to be as useful)
3. Inconsistencies (Here and there I find PB to bee a little rough around the edges for example no way to color a button unless you use PureColor which in turn falss under previous point)
4. User Base (PB has extremely helpful and knowledgeable community of developers, unfortunately we're nothing (quantitative) compared to .NET user base and some of the libraries we wanted to implement where not available directly for PB and time was spent wrapping them or fixing problems with existing wrappers)
People been complaining about how bloated Windows and .NET framework is and I totally agree. Luckily for all .NET developers Vista and 7 comes with pre-installed framework so I don't think thats an issue I should worry about unless I do games, but then I can use good old PB

Anyhow I'll stop my rant and return back to topic. I wanted to find out how VB.NET compares to PB in terms of pure runtime speed. As I was Googling this I stumbled upon an old thread that compared the speeds of VB6 to VB.NET using simple math calculations. Needless to say .NET was a lot faster.
So here it is ....
VB.NET source code:
Code: Select all
Declare Function GetTickCount Lib "kernel32.dll" () As Long
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
'Program to test relative speed of VB6 vs VB.NET
'Tests mathematical operations
'Coded 10.8.02
Dim x As Long
Dim z As Double
Dim start As Long
MessageBox.Show("Press OK to begin mathematical operations. Tests should take <1 minute.")
start = GetTickCount
'Basic operations, integer & floating point
For x = 0 To 10000000
z = 17 + 56 / (9 * 263) - 78 / (2.2 * 9)
Next
'Rnd
For x = 0 To 1000000
z = Rnd()
Next
'Trig functions
For x = 0 To 10000000
z = System.Math.Sin(23.5687)
z = System.Math.Cos(23.5687)
z = System.Math.Tan(23.5687)
z = System.Math.Atan(23.5687)
Next
'Sqr
For x = 0 To 10000000
z = System.Math.Sqrt(2315.126)
Next
'Exp & log
For x = 0 To 10000000
z = System.Math.Exp(22.561)
z = System.Math.Log(22.561)
Next x
MessageBox.Show((GetTickCount() - start) / 1000 & " seconds elapsed.")
End Sub
Code: Select all
Define x.l,z.d,start.l
MessageRequester("","Press OK To begin mathematical operations. Tests should take <1 minute.")
start = ElapsedMilliseconds()
;Basic operations, integer & floating point
For x = 0 To 10000000
z = 17 + 56 / (9 * 263) - 78 / (2.2 * 9)
Next
;Rnd
For x = 0 To 1000000
z = Random(1)
Next
;Trig functions
For x = 0 To 10000000
z = Sin(23.5687)
z = Cos(23.5687)
z = Tan(23.5687)
z = ATan(23.5687)
Next
;Sqr
For x = 0 To 10000000
z = Sqr(2315.126)
Next
;Exp & log
For x = 0 To 10000000
z = Exp(22.561)
z = Log(22.561)
Next x
MessageRequester("",StrF((ElapsedMilliseconds() - start) / 1000,2) + " seconds elapsed.")
Visual Basic .NET Express 2008 - ~2.7 seconds
PureBasic v4.60 - ~4.77 seconds
I know such test are purely for "fanboys" and usually don't represent the real-life speed of the binary but I always thought that PB would beat VB.NET by a thick margin so this was quite a surprise for me.