Console output slower that before

  • This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.
#1
Every test I can think of indicates that console output (lots of it, at high speed) is slower in v20 than in v19, in fact, about half the speed. Here are just a few things I've tried, performed with v20 and v19 in which I specified the affinity so as to get rid of the differences in speed among my processors.

Code:
v:\> outputtest.btm
start /min /wait /affinity=1 g:\tc20\tcc.exe /c dir /s g:\
Timer 1 off: 17:23:44  Elapsed: 0:00:25.33

start /min /wait /affinity=1 g:\tc19\tcc.exe /c dir /s g:\
Timer 1 off: 17:23:55  Elapsed: 0:00:11.32

start /min /wait /affinity=2 g:\tc20\tcc.exe /c dir /s g:\
Timer 1 off: 17:24:26  Elapsed: 0:00:31.33

start /min /wait /affinity=2 g:\tc19\tcc.exe /c dir /s g:\
Timer 1 off: 17:24:40  Elapsed: 0:00:13.98

start /min /wait /affinity=4 g:\tc20\tcc.exe /c dir /s g:\
Timer 1 off: 17:25:07  Elapsed: 0:00:26.75

start /min /wait /affinity=4 g:\tc19\tcc.exe /c dir /s g:\
Timer 1 off: 17:25:19  Elapsed: 0:00:12.40

start /min /wait /affinity=8 g:\tc20\tcc.exe /c dir /s g:\
Timer 1 off: 17:25:51  Elapsed: 0:00:32.05

start /min /wait /affinity=8 g:\tc19\tcc.exe /c dir /s g:\
Timer 1 off: 17:26:06  Elapsed: 0:00:14.19
 
#3
With ANSI off in both versions, it's better but v19 still has a 10-20% advantage.

Is the ANSI code executed when redirecting to NUL, or when piping to something which eats the output? In such cases, v19 and v20 measure the same, even with ANSI=Yes.
 

rconn

Administrator
Staff member
May 14, 2008
10,292
90
#4
With ANSI off in both versions, it's better but v19 still has a 10-20% advantage.

Is the ANSI code executed when redirecting to NUL, or when piping to something which eats the output? In such cases, v19 and v20 measure the same, even with ANSI=Yes.
For piping, yes. For redirecting to nul, depends on whether you're in a TCMD tab window (yes) or a console window (no).

If you're doing it in a TCMD tab window, then remember to turn off ANSI in TCC; otherwise you'll be executing ANSI code *twice*.
 
#6
Here's the same test using a pipe (ANSI code executed, right?). Both versions have ANSI=Yes. I used the c: drive to try to exaggerate the differences, but there are hardly any differences. If that's a valid test, it doesn't look like ANSI is the culprit. All of this is console only.
Code:
v:\> output.btm
start  /wait /affinity=1 g:\tc20\tcc.exe /c dir /s c:\ ^| wc
Timer 1 off: 21:41:01  Elapsed: 0:00:17.32

start  /wait /affinity=1 g:\tc19\tcc.exe /c dir /s c:\ ^| wc
Timer 1 off: 21:41:18  Elapsed: 0:00:16.92

start  /wait /affinity=2 g:\tc20\tcc.exe /c dir /s c:\ ^| wc
Timer 1 off: 21:41:35  Elapsed: 0:00:17.26

start  /wait /affinity=2 g:\tc19\tcc.exe /c dir /s c:\ ^| wc
Timer 1 off: 21:41:53  Elapsed: 0:00:17.73

start  /wait /affinity=4 g:\tc20\tcc.exe /c dir /s c:\ ^| wc
Timer 1 off: 21:42:10  Elapsed: 0:00:17.43

start  /wait /affinity=4 g:\tc19\tcc.exe /c dir /s c:\ ^| wc
Timer 1 off: 21:42:28  Elapsed: 0:00:17.64

start  /wait /affinity=8 g:\tc20\tcc.exe /c dir /s c:\ ^| wc
Timer 1 off: 21:42:47  Elapsed: 0:00:18.46

start  /wait /affinity=8 g:\tc19\tcc.exe /c dir /s c:\ ^| wc
Timer 1 off: 21:43:05  Elapsed: 0:00:18.87
 
#7
TYPE-ing a big file with ANSI=No, it's a dead heat! Even my 4 processors look the same (which is odd).
Code:
start  /wait /affinity=1 g:\tc20\tcc.exe /c type bigg.txt
Timer 1 off: 22:01:26  Elapsed: 0:00:18.26

start  /wait /affinity=1 g:\tc19\tcc.exe /c type bigg.txt
Timer 1 off: 22:01:44  Elapsed: 0:00:18.28

start  /wait /affinity=2 g:\tc20\tcc.exe /c type bigg.txt
Timer 1 off: 22:02:02  Elapsed: 0:00:18.25

start  /wait /affinity=2 g:\tc19\tcc.exe /c type bigg.txt
Timer 1 off: 22:02:21  Elapsed: 0:00:18.25

start  /wait /affinity=4 g:\tc20\tcc.exe /c type bigg.txt
Timer 1 off: 22:02:39  Elapsed: 0:00:18.24

start  /wait /affinity=4 g:\tc19\tcc.exe /c type bigg.txt
Timer 1 off: 22:02:57  Elapsed: 0:00:18.27

start  /wait /affinity=8 g:\tc20\tcc.exe /c type bigg.txt
Timer 1 off: 22:03:15  Elapsed: 0:00:18.27

start  /wait /affinity=8 g:\tc19\tcc.exe /c type bigg.txt
Timer 1 off: 22:03:34  Elapsed: 0:00:18.25
 
#8
I also noticed this. In my tests (the most recent one, for example) the control instance of TCC was v20. It had a taskbar icon. During the test, whenever v20 was run, for example
Code:
start  /wait /affinity=1 g:\tc20\tcc.exe /c type bigg.txt
that taskbar icon was doubled (that's expected). Whenever v19 was run, for example
Code:
start  /wait /affinity=1 g:\tc19\tcc.exe /c type bigg.txt
I got a new taskbar icon (also expected) but that new icon was the generic console app icon, not the TCC icon that I would expect.

This does not happen if the control app is v19. In this case, the new taskbar icon created when v20 is run is the correct one.

Is it Windows doing this, or maybe some difference between v19 and v20?