# Visual Basic > Visual Basic 6 and Earlier >  VB6 Question: hyperthreading enabled on your development system?

## yereverluvinuncleber

I was upgrading from a 3.2ghz 4x core i5 to 4x core i7 6700 (with 8 threads) on my gen. 6 Optiplex SFF motherboard. Creating a Windows 10 system for VB6 development.

When I first booted the i7, it was extremely quick to compile, seemingly snappier than my other system (with a full and fast motherboard Asus Maximus VIII hero using a slightly better CPU core i7 6700K). Note both have a 256gb SSD to boot and the code sits on an equivalent HDD using 6gb SATA.

Benchmarks below. I know the comparison is not completely equivalent but I had expected the small form factor motherboard with the less powerful CPU to be significantly slower. However, it isn't. It is significantly quicker and I was both surprised and impressed.

VB6 compilation time comparison, Optiplex first, Asus after.

iconSettings (18KLoc)   4 secs vs 7.5secs
dock (7.5KLoc)            3 secs vs 4 secs
dockSettings (5.7KLoc) 2 secs vs 4 secs
fireCall (24KLoc)          9 secs vs 8.5 secs

I noticed using CPU-Z that the Optiplex was only showing 4 threads and some research into the BIOS showed that hyperthreading was disabled... I enabled hyperthreading and all those Optiplex benchmarks slowed by 0.5 to 1.5 secs - so not quite so snappy but still faster than the Asus mobo/cpu.

Regarding non-compilation tasks, starting Photoshop CS on the Optiplex is 5 seconds compared to 8 secs on the Asus so it is not just VB6 compilation times that are snappy. Overall performance for the Optiplex is surprisingly good. 

I clearly need to do some digging to find out why the Asus Maximus is performing slower, it has a lot of overclocking options that need to be checked before the comparison is good.

Still though, impressed by the old Optiplex 3040 SFF motherboard, and I'd recommend it for a VB6 development system. 

Which begs the question regarding that performance decrease when enabling hyperthreading - when you are compiling very large VB6 programs (50+Kloc), do any of you compile with hyperthreading disabled to gain performance improvements on VB6 compilation times ? Is this a real thing?

----------


## VanGoghGaming

What's the point of using old hardware for VB6 development? It works just as well on the latest hardware which is orders of magnitude faster...

----------


## dilettante

Considering that the product was designed for 24 to 48MB 90Mhz Pentium systems with hard drives well under 1GB this all sounds very silly.

A $100 mini-PC should be more than adequate.

----------


## yereverluvinuncleber

Sorry?your comments seem to be non sequitur. I was making an observation that might be helpful to others re: suggestion for a cheap development platform and then as a result, asking a question which I was hoping to get an answer from re: hyperthreading.

So, back on track.

----------


## dilettante

All hat, no cattle.

----------


## wqweto

You can use */runexit* option on *vb6.exe* to full-compile a project group, register Ax-DLL projects and run the startup Std-EXE project.

I'm usually preparing a BAT file with something like *ptime.exe "C:\Program Files (x86)\Microsoft Visual Studio\VB98\VB6.EXE" /runexit MyProjectGroup.vbg* where ptime.exe is an utility which measures elapsed time.

Upon starting the project I immediately hit Cancel on login form or close main form so that IDE can unregister Ax-DLL projects and exit into command prompt.

Just measured a second run (for disk cache to be hot) *Execution time: 17.504 s* on a project group of 891187 lines of code total, this is on an i9-12900 CPU with 8 performance cores enabled only w/ hyper threading.

I disabled the other low-powered "efficient" cores not for performance reasons but because I tested hacking the BIOS to enable AVX-512 instructions (and failed). I just don't need more cores, more complexity and uncertainty, always watching which app is running on low-powered ones and so on.

Btw, you should always change machine's power plan to "High performance" before taking any performance measurements.

cheers,
</wqw>

----------


## Schmidt

> Just measured a second run (for disk cache to be hot) *Execution time: 17.504 s* 
> ...on an i9-12900 CPU with 8 performance cores enabled only w/ hyper threading.


I assume, your "w/" above means: "without" HyperThreading enabled in the BIOS?

Anyways, no matter if it meant "with" or "without" ... the "other timing" would be interesting.

Last time I've checked this myself, was over 10 years ago - and my results were similar to UncleBer's.

HyperThreading (when enabled in the BIOS, as is usually the default) - 
was affecting the "performance per Core" negatively...
(and thus also the SingleThread-Performance when compiling with VB6.exe) ...
With "HT-enabled", I was only achieving ~80% of the performance, compared to "HT-disabled" in the BIOS.

Disabling HT in the BIOS will leave you with only "half the Cores" of course when the OS comes up -
but this affects only those Apps which are able to use "massively parallel calculations" -
(as e.g. Blender or Video-Encoder-Apps).

Olaf

----------


## wqweto

> I assume, your "w/" above means: "without" HyperThreading enabled in the BIOS?


The i9-12900 has 8 performance cores and 8 efficient cores which I disabled for my AVX-512 experiments some time ago so I'm using only 8 cores total *with* HT.

The efficient cores are not something I look forward to using at all but I should definately disable HT on the performance cores first thing on Monday.

Although power settings (not using "High performance" power plan) and OS compatibility shims (XP compatible on the VB6.exe) are the greatest performance killers for IDE.

cheers,
</wqw>

----------


## Schmidt

> The i9-12900 has 8 performance cores and 8 efficient cores which I disabled for my AVX-512 experiments some time ago so I'm using only 8 cores total *with* HT.


I'm aware of these "efficiency-cores" in the new Intel-CPUs.

However, there should also be an option in your BIOS, to disable HT as well (on the performance-cores).

If you configure your TaskManager-PerformanceView to "show Load for each CPU separately", you should see:
- 24 CPU-SubSections in that View (when "everything is enabled" (including the efficiency-cores)
- 16 CPU-SubSections in that View (when the efficiency-cores are disabled and HT is enabled)
- 8 CPU-SubSections in that View (when both, efficiency-cores *and* HT are disabled)

It is that last mode, which should give you an additional "SingleThreaded-Performance-Boost".

Olaf

----------


## wqweto

Yes, I'm seeing the *16 CPU-SubSections in that View (when the efficiency-cores are disabled and HT is enabled)* in ProcessHacker actually but will disable HT soon.

cheers,
</wqw>

----------


## wqweto

> Just measured a second run (for disk cache to be hot) *Execution time: 17.504 s* on a project group of 891187 lines of code total, this is on an i9-12900 CPU with 8 performance cores enabled only w/ hyper threading.


*Execution time: 15.667 s* w/ hyper-threading *disabled*

cheers,
</wqw>

----------


## Schmidt

> *Execution time: 15.667 s* w/ hyper-threading *disabled*


Thanks for running this comparison on a modern CPU.

And it seems "the effect is still there" with roughly 12% boost instead of the ~20% I observed 10 years ago -
but the smaller effect is as expected - due to the modern CPUs having larger+faster caches -
but especially "deeper pipelines" (which Hyper-Threading was invented for, to ensure a higher "fill-grade" of that infrastructure).

Olaf

----------

