Tcl Source Code

Check-in [852b037b2f]
Login
Bounty program for improvements to Tcl and certain Tcl packages.
Tcl 2019 Conference, Houston/TX, US, Nov 4-8
Send your abstracts to [email protected]
or submit via the online form by Sep 9.

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:merge 8-5-event-perf-branch (restore merge point after complex merge across branches 8.6/8.6-timerate/etc)
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | sebres-8-6-event-perf-branch
Files: files | file ages | folders
SHA3-256: 852b037b2fe46da96e61e68356eae86a1b2d2eab145a92017db8d11cafbcd465
User & Date: sebres 2019-03-08 11:37:34
Context
2019-03-08
15:39
merge 8-5-event-perf-branch (no monotonic time fallbacks) check-in: ec9b47d045 user: sebres tags: sebres-8-6-event-perf-branch
11:37
merge 8-5-event-perf-branch (restore merge point after complex merge across branches 8.6/8.6-timerat... check-in: 852b037b2f user: sebres tags: sebres-8-6-event-perf-branch
11:34
3-way merge 8.6 - timerate is part of Tcl now (since TIP#527 got merged), conflicts resolved, merge-... check-in: 102958b94e user: sebres tags: sebres-8-6-event-perf-branch
04:38
merge 8.5 (fixed performance test for short exec-time) check-in: 177092d5da user: sebres tags: sebres-8-5-event-perf-branch
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to win/tclWinTime.c.

668
669
670
671
672
673
674

675


676
677
678
679
680
681
682
683

684
685



686
687
688
689
690
691
692
		 */

		SYSTEM_INFO systemInfo;
		unsigned int regs[4];

		GetSystemInfo(&systemInfo);


		if (TclWinCPUID(0, regs) == TCL_OK


			&& regs[1] == 0x756e6547	/* "Genu" */
			&& regs[3] == 0x49656e69	/* "ineI" */
			&& regs[2] == 0x6c65746e	/* "ntel" */
			&& TclWinCPUID(1, regs) == TCL_OK
			&& (( ((regs[0]&0x00000F00) == 0xF00) /* Pentium 4 */
			   || ((regs[0]&0x00000F00) == 0x600) ) /* or compatible (VM) */
			&& ((regs[0] & 0x0FF00000)	/* Extended family (bits 20-27) */
			|| (regs[3] & 0x10000000)))	/* Hyperthread (bit 28) */

			|| (((regs[1]&0x00FF0000) >> 16) >= 2 /* CPU count */
			    || systemInfo.dwNumberOfProcessors >= 2)) {



		    timeInfo.perfCounterAvailable = TRUE;
		} else {
		    timeInfo.perfCounterAvailable = FALSE;
		}

	    }
#endif /* above code is Win32 only */






>
|
>
>
|







>
|
<
>
>
>







668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688

689
690
691
692
693
694
695
696
697
698
		 */

		SYSTEM_INFO systemInfo;
		unsigned int regs[4];

		GetSystemInfo(&systemInfo);

		if ( systemInfo.dwNumberOfProcessors >= 2
		  || (TclWinCPUID(0, regs) == TCL_OK
		    && (
		    	(
			   regs[1] == 0x756e6547	/* "Genu" */
			&& regs[3] == 0x49656e69	/* "ineI" */
			&& regs[2] == 0x6c65746e	/* "ntel" */
			&& TclWinCPUID(1, regs) == TCL_OK
			&& (( ((regs[0]&0x00000F00) == 0xF00) /* Pentium 4 */
			   || ((regs[0]&0x00000F00) == 0x600) ) /* or compatible (VM) */
			&& ((regs[0] & 0x0FF00000)	/* Extended family (bits 20-27) */
			|| (regs[3] & 0x10000000)))	/* Hyperthread (bit 28) */
			)
			|| ((regs[1]&0x00FF0000) >> 16) >= 2 /* CPU count */

		    )
		  )
		) {
		    timeInfo.perfCounterAvailable = TRUE;
		} else {
		    timeInfo.perfCounterAvailable = FALSE;
		}

	    }
#endif /* above code is Win32 only */