CPU Tuning, Throttling

Showcase your Retro PC / Build logs.

CPU Tuning, Throttling

Postby PARUS » 2018-5-29 @ 19:18

MSRED.COM, works with any CPU which has MSR.

For Core 2 there are two MSR which control multiplier.

0x194 r/w controls MAXIMUM and NOMINAL (they are equal) multiplier. Command and keys for write:
MSRED W 194 1XXYY, where XX is multiplier and YY is voltage.
Examples:
MSRED W 194 10A28 - maximum mul is 10, maximum vol is 1,3250v.
MSRED W 194 11228 - maximum mul is 18, maximum vol is 1,3250v.

0x199 r/w controls CURRENT multiplier. Command and keys:
MSRED W 199 XXYY
Examples:
MSRED W 199 728 - current mul is 7, current vol is 1,3250v.
MSRED W 199 F28 - current mul is 15, current vol is 1,3250v.

And one r/o MSR 0x198 for display real values, command:
MSRED R 198

For Pentium 4 and Core 2 there is one MSR which controls throttling - 0x19A. Command:
MSRED W 19A NN
Examples:
MSRED W 19A 18 - 50% CPU speed
MSRED W 19A 14 - 25% CPU speed
MSRED W 19A 12 - 12,5% CPU speed
MSRED W 19A 2 - 100% CPU speed

MSRED.zip
(719 Bytes) Downloaded 60 times


CACHECTL.COM, works with Pentium Pro, Pentium 2, Pentium 3, Core 2. Doesn't work with all NetBurst CPUs!

Commands:
CACHECTL 0 - disable L2 and disable cache system totally with L1
CACHECTL 1 - enable cache system and L1, disable L2
CACHECTL 2 - enable cache system and L1, enable L2
CACHECTL c - check status

CACHECTL.zip
(704 Bytes) Downloaded 59 times
User avatar
PARUS
Member
 
Posts: 459
Joined: 2013-4-14 @ 04:03

Re: CPU Tuning, Throttling

Postby PARUS » 2018-5-29 @ 19:24

I have i865+Core2. Typical inside batch sequence is (example for very old DOS):

MSRED W 194 10828
MSRED W 19A 12
THROTTLE 4 -C
CACHECTL 0
User avatar
PARUS
Member
 
Posts: 459
Joined: 2013-4-14 @ 04:03

Re: CPU Tuning, Throttling

Postby PARUS » 2018-5-29 @ 19:31

Another example:
MSRED W 194 10628
MSRED W 19A 12
- that's all! If FSB400 you'll get about Pentium-1 133 performance. If FSB800 you'll get about Pentium-1 266.
User avatar
PARUS
Member
 
Posts: 459
Joined: 2013-4-14 @ 04:03

Re: CPU Tuning, Throttling

Postby j^aws » 2018-5-29 @ 19:37

Thanks for the thread.

I'm under the impression that the Pentium 4 Prescott mobile can underclock to 6x multi (haven't checked), which is as low as the Core2, so would this MSRED tool work for it, too?
j^aws
Oldbie
 
Posts: 779
Joined: 2013-2-02 @ 19:39
Location: UK

Re: CPU Tuning, Throttling

Postby PARUS » 2018-5-29 @ 19:45

Probably. But for the NetBurst there are another MSRs which control its multiplier. At home I have saved link but don't remember now.
User avatar
PARUS
Member
 
Posts: 459
Joined: 2013-4-14 @ 04:03

Re: CPU Tuning, Throttling

Postby gdjacobs » 2018-5-30 @ 02:08

Have you done some testing on a Core 2? I'm interested in any information you have on how the speed ranges this delivers map onto Speedsys, DOOM, or any benchmark you've tested with. I'd love to compare versatility with the S754 machine I just go my hands on.
User avatar
gdjacobs
l33t++
 
Posts: 6588
Joined: 2015-11-03 @ 05:51
Location: The Great White North

Re: CPU Tuning, Throttling

Postby PARUS » 2018-5-30 @ 07:27

gdjacobs, yes, I have. See one screenshot which is saved in www:
Image
Config: Itox G7S620-N i865G, Core2 X6800, FSB400.
Commands:
MSRED W 194 10628
MSRED W 19A 12
User avatar
PARUS
Member
 
Posts: 459
Joined: 2013-4-14 @ 04:03

Re: CPU Tuning, Throttling

Postby PARUS » 2018-5-30 @ 07:46

When you're slowing down Core 2 to ~486-386 and lower speeds I recommend to use multiplier x8. It is because if we get full synchronization CPU tacts and BUS tacts we will not find a lot of issues like jumps and delays. I explain:
1) maximum CPU throttle 12,5% (1/8), multiplier 8 --- 8x1/8=1
2) CPU throttle 25% (1/4), multiplier 8 --- 8x1/4=2
3) CPU throttle 50% (1/2), multiplier 8 --- 8x1/2=4
I.e. we always have full integer ratio CPU/BUS and probability of issues (jumps, delays) is minimum.

When you're slowing down to Pentium1 or higher speeds you can choose any combinations.

One more: to slow down lower than Pentium1 speeds you should disable L2 or L2+L1 via cachectl.com and slow down BUS via throttle.exe with -C key. Usual value is throttle 4 -c (but of course you try it yourself for your config).
User avatar
PARUS
Member
 
Posts: 459
Joined: 2013-4-14 @ 04:03

Re: CPU Tuning, Throttling

Postby gdjacobs » 2018-5-30 @ 15:01

PARUS wrote:gdjacobs, yes, I have. See one screenshot which is saved in www:
Image
Config: Itox G7S620-N i865G, Core2 X6800, FSB400.
Commands:
MSRED W 194 10628
MSRED W 19A 12


Nice. What's the jump between max multi/FSB with caches disabled and min multi/FSB with caches enabled? Can you manipulate L1 and L2 individually and does that provide intermediate tunings?
User avatar
gdjacobs
l33t++
 
Posts: 6588
Joined: 2015-11-03 @ 05:51
Location: The Great White North

Re: CPU Tuning, Throttling

Postby PARUS » 2018-5-30 @ 16:18

I forgot to say, MSRED and CACHECTL are working only with HIMEM without EMM386. In future it would be nice to recompile them to work with any memory managers.

The max multi/FSB with caches disabled is buggy variant. I didn't even try it. Min multi/FSB with caches enabled gives us about Pentium1 speed, I have shown this on screenshot.
Yes, sure, we can manipulate them individually: L1- L2-; L1+ L2-; L1+ L2+. Variant L1- L2+ is impossible. More precisely it's technically possible but L2 will be unavailable if L1 disabled because L1 is disabling always with all cache subsystem together.
User avatar
PARUS
Member
 
Posts: 459
Joined: 2013-4-14 @ 04:03

Re: CPU Tuning, Throttling

Postby Falcosoft » 2018-5-30 @ 18:29

Hi, just some observations:
PARUS wrote:I forgot to say, MSRED and CACHECTL are working only with HIMEM without EMM386. In future it would be nice to recompile them to work with any memory managers.

1. No recompiling can help here. These utilities use WRMSR/MOV CR0,<REG> instructions that are privileged instructions under protected/V86 mode. Once EMM386 is loaded it switches the CPU to protected/V86 mode so no user mode programs can use privileged instructions anymore. The only solution is when the memory manager itself can handle privileged instructions of user programs. Such a memory manger is JEMM386.
From JEMM386 documentation:
5. Emulation of privileged Opcodes

To provide Expanded Memory an EMM Emulator like Jemm runs the cpu in
so-called v86-mode. This mode does not allow to run privileged opcodes.
Some of these opcodes which might be useful for application programs
are emulated by Jemm, however. These are:

- mov <special_reg>, <reg> ;special_reg = CRn, DRn, TRn
- mov <reg>, <special_reg> ;reg = eax, ebx, ecx, edx, esi, edi, ebp
- WBINVD
- INVD
- WRMSR
- RDMSR
- RDTSC


2. IA32_PERF_STATUS MSR (0x198) and IA32_PERF_CTL MSR (0x199) are not Core 2 specific registers. They are standard SpeedStep registers that are available on all Intel CPU that use SpeedStep. So in order to make them work you should enable SpeedStep in BIOS or by setting bit 16 in IA32_MISC_ENABLE MSR (0x1A0).
The FID (multiplier setting) seems to be model independent but the VID value (voltage) depends on the CPU type.

I have also written a speedstep setting utility for DOS earlier (source is included):
http://falcosoft.hu/dos_softwares.html#sstep
About my findings:
https://sourceforge.net/p/freedos/mailm ... /31894268/
User avatar
Falcosoft
Oldbie
 
Posts: 906
Joined: 2016-5-21 @ 13:46
Location: Pécs, Hungary

Re: CPU Tuning, Throttling

Postby PARUS » 2018-5-31 @ 06:53

Wow, thanks a lot! You gave very valuable and useful information. OK, 198h/199h are not Core 2 specific but they are not for BetBurst, only for Pentium M/Core families. I have recalled! I saw it here: https://wenku.baidu.com/view/919c9849e5 ... 47c86.html for Northwood it's MSR 0x2C and 0x2D. I tried to rewrite values these MSR on my two unlocked Northwood CPUs in pure DOS via MSRED but unsuccessfully :(.
When I'll be back home I'll try 0x1A0 on my unlocked P4 and then 0x2C/2D.
User avatar
PARUS
Member
 
Posts: 459
Joined: 2013-4-14 @ 04:03

Re: CPU Tuning, Throttling

Postby agent_x007 » 2018-5-31 @ 07:47

So, how Nehalem fits into this ?
I did test my Core i7 980X with SetMUL (w/L1D option) :
Image
and here is "default" score :
Image
Interesting part is that 4,3GHz i7 can be between 386dx and 486dx2... or is it an error ?
Image
User avatar
agent_x007
Oldbie
 
Posts: 1169
Joined: 2016-1-19 @ 11:06

Re: CPU Tuning, Throttling

Postby PARUS » 2018-6-06 @ 08:06

Sorry, can't tell anything about it, I never had Core i3/5/7.
User avatar
PARUS
Member
 
Posts: 459
Joined: 2013-4-14 @ 04:03

Re: CPU Tuning, Throttling

Postby ruthan » 2018-7-05 @ 22:59

I read the thread, im missing documentation for THrottle command, need its other utility? This line:
THROTTLE 4 -C

What if anything make sense to test with X58 platform CPU?

Interesting part is that 4,3GHz i7 can be between 386dx and 486dx2... or is it an error ?

Test it with this and we will see, if it would be much slower
viewtopic.php?f=24&t=53769
Or you can try Phils DosBench utils package.
Im old goal oriented goatman, i care about facts and freedom, not about egos+prejudices. Hoarding=sickness. If you want respect, gain it by your behavior. I hate stupid SW limits, SW=virtual world, everything should be possible if you have enough HW.
User avatar
ruthan
Oldbie
 
Posts: 1094
Joined: 2013-3-07 @ 04:01
Location: Schwarz Wald-from France to Ukraine, from Denmark to Austria. Celts+German+Slavs melting pot.

Re: CPU Tuning, Throttling

Postby PARUS » 2018-7-07 @ 10:26

ruthan wrote:I read the thread, im missing documentation for THrottle command, need its other utility? This line:
THROTTLE 4 -C

What if anything make sense to test with X58 platform CPU?

Interesting part is that 4,3GHz i7 can be between 386dx and 486dx2... or is it an error ?

Test it with this and we will see, if it would be much slower
viewtopic.php?f=24&t=53769
Or you can try Phils DosBench utils package.


I see you know now almost nothing about system throttling and too fast systems problem in DOS. It is very hard problem, too much harder than you can imagine with your most optimistic.

I said this not by chance:
PARUS wrote:So I think the king is i865+ISA yet! With Core2 CPU this system is working fine on DOS-Win9X-WinXP/7/8.1, can get XT performance without issues, 286-386-486 performance without issues and so on Pentium-Pentium2 ----- Core 2 3GHz.

And about throttle issues on newer chipsets.
User avatar
PARUS
Member
 
Posts: 459
Joined: 2013-4-14 @ 04:03

Re: CPU Tuning, Throttling

Postby PARUS » 2018-7-07 @ 10:30

ruthan, http://www.oldskool.org/pc/throttle/DOS

Using only this program is not optimal. Using THROTTLE+MSRED+CACHECTL is optimal.
User avatar
PARUS
Member
 
Posts: 459
Joined: 2013-4-14 @ 04:03

Re: CPU Tuning, Throttling

Postby ruthan » 2018-7-07 @ 13:27

I see you know now almost nothing about system throttling and too fast systems problem in DOS. It is very hard problem, too much harder than you can imagine with your most optimistic.

Yeah its right, i have used slowdown some utility 15+ years ago - i dont even remember name, i dont needed it too often and Dosbox had in-build speed control.
I dont know if set of games which i have playing is typical, i had some speed problem with 3 games from 50, which i have tried.

I tested, Cachectl on X58 i got reboot. MSRED - i dont understand voltage control etc - so i dont tried it yet, SetMul is only working thing, it works for L1 cache, not for L2 cache.

Details are in my new compatibility thread:
viewtopic.php?f=61&t=61044
Im old goal oriented goatman, i care about facts and freedom, not about egos+prejudices. Hoarding=sickness. If you want respect, gain it by your behavior. I hate stupid SW limits, SW=virtual world, everything should be possible if you have enough HW.
User avatar
ruthan
Oldbie
 
Posts: 1094
Joined: 2013-3-07 @ 04:01
Location: Schwarz Wald-from France to Ukraine, from Denmark to Austria. Celts+German+Slavs melting pot.

Re: CPU Tuning, Throttling

Postby PARUS » 2018-7-07 @ 18:52

Of course proper CACHECTL work is guaranteed only for 80686 (Pentium Pro, 2, 3) and Core2 family. I have wrote about it already in first topic message. With <1366> and similar CPUs this program is not tested, is not debugged.
User avatar
PARUS
Member
 
Posts: 459
Joined: 2013-4-14 @ 04:03

Re: CPU Tuning, Throttling

Postby ruthan » 2018-7-08 @ 00:47

PARUS wrote:Of course proper CACHECTL work is guaranteed only for 80686 (Pentium Pro, 2, 3) and Core2 family. I have wrote about it already in first topic message. With <1366> and similar CPUs this program is not tested, is not debugged.

Yeah, but it still was worth of try, SetMul was also developed for VIA and K6 mobile, but its working.
Im old goal oriented goatman, i care about facts and freedom, not about egos+prejudices. Hoarding=sickness. If you want respect, gain it by your behavior. I hate stupid SW limits, SW=virtual world, everything should be possible if you have enough HW.
User avatar
ruthan
Oldbie
 
Posts: 1094
Joined: 2013-3-07 @ 04:01
Location: Schwarz Wald-from France to Ukraine, from Denmark to Austria. Celts+German+Slavs melting pot.

Next

Return to System Specs

Who is online

Users browsing this forum: No registered users and 5 guests