MCA
KiX Supporter
   
Registered: 2000-04-28
Posts: 5152
Loc: Netherlands, EU
|
Dear,Benchmark information: input file: 26.173 lines + 858.946 bytes - kixstrip
- 858.946 bytes -> 473.592 bytes - 101.89 seconds
- kixref
- 26.713 lines - 228 symbols - 44.973 linenumbers - 2 boldsymbols - 22 commands - 1 label - 35 macro's - 136 variables - 7 undefined names - 339 do/until statements - 5235 if/else/endif statements - 30 select/case/endselect statements - 15 while/loop statements - 3.95 seconds
code:
Kixref 3.62 (vs 1.37e) MCA - scripting@wanadoo.nl - 2000 kixref (vs 1.37e) kix-test.kix -> kix-test.txt (pl=55 pw=150 (default)) 3.95 (sec) (26172 BOLD=[228:44973] SOURCE=26187) (count 228 b=2 c=22 f=25 l=1 m=35 v=136 ?=7) (blocks do=[339:339] if=[5235:1113:5235] select=[30:198:30] while=[15:15])
- compress e X Y
- 858.946 bytes -> 128.947 bytes - 13.73 seconds
- codec e X Y
- 128.947 bytes -> 186.822 bytes - 1.05 seconds
- codec d X Y
- 186.822 bytes -> 128.947 bytes - 4.50 seconds
- compress d X Y
- 128.947 bytes -> 858.946 bytes - 1.37 seconds - compress e X Y
- 473.592 bytes -> 73.952 bytes - 6.54 seconds
- codec e X Y
- 73.952 bytes -> 107.383 bytes - 0.71 seconds
- codec d X Y
- 107.383 bytes -> 73.952 bytes - 2.58 seconds
- compress d X Y
- 73.952 bytes -> 473.592 bytes - 0.82 seconds
Example input: code:
$MACADD = @address $StDir = @startdir call '01login.kix' $filename = $INIFILE $section = 'Survey' $key = 'StartTime' $string = $STIME $WriteString = WRITEPROFILESTRING('$filename', '$section', '$key', '$string') $key = 'EndTime' $string = $ETIME $WriteString = WRITEPROFILESTRING('$filename', '$section', '$key', '$string') call '02globvar.kix' call '03ulckdktp.kix' call '04uaffil.kix' call '05runmsd.kix' :readrpt :checkmac IF $MACADD = '000000000000' Select Case Open(1,'c:\demerge\report.msd') = 0 $line = Readline(1) :again WHILE @ERROR = 0 SELECT CASE INSTR($line,"Physical Station Number:") $MACADD = SUBSTR(LTRIM(RTRIM($line)),LEN(LTRIM(RTRIM($line))) - 13 , 4 ) $MACADD = $MACADD + SUBSTR(LTRIM(RTRIM($line)),LEN(LTRIM(RTRIM($line))) - 8 , 4 ) $MACADD = $MACADD + SUBSTR(LTRIM(RTRIM($line)),LEN(LTRIM(RTRIM($line))) - 3 , 4 ) close (1) goto 'contin' CASE INSTR($line,"NetBIOS Card Information:") $line = Readline(1) $MACADD = SUBSTR(LTRIM(RTRIM($line)),LEN(LTRIM(RTRIM($line))) - 11 , 12 ) close (1) goto 'contin' ENDSELECT $line = Readline(1) LOOP close (1) $mheader = 'Unable to find MacAddress' $message = $mheader + Chr(10) + Chr(10) $message = $message + 'WINIPCFG will be launched.' + Chr(10) $message = $message + 'Enter MacAddress on the next Survey Screen' $selection = MESSAGEBOX($message, $mheader, 16) RUN 'c:\windows\winipcfg.exe' :nomac Color b/n BOX (8,21,20,61,) Color g+/n BOX (7,20,19,60,FULL) $instruct1 = 'Enter "Adapter Address" below' $instruct2 = 'Example -> 00CO4F8CB1FB' $Selection = 'MAC ADDRESS: ' $LenIns1 = 20 + ((40 - LEN($instruct1))/2) $LenIns2 = 20 + ((40 - LEN($instruct2))/2) AT(9,$LenIns1) $instruct1 AT(11,24) $instruct2 AT(17,24) $Selection $x = (LEN($Selection) + 24) AT(17,$x) Get $Ans Select Case LEN($Ans) = 12 $MACADD = $Ans goto 'contin' Case LEN($Ans) <> 12 goto 'nomac' EndSelect Case Open(1,'c:\demerge\report.msd') <> 0 ? "Unable to open 'report.msd'... survey halted!" get $x quit EndSelect EndIF :contin $filename = $INIFILE $section = 'Computer' $key = 'MacAddress' $string = $MACADD $WriteString = WRITEPROFILESTRING('$filename', '$section', '$key', '$string') $messenger = 'Credit4Survey' call 'messenger.kix'
After compress + codec code:
begin (c) CODEC 1.31e (2000221 tue 08-aug-2000 22:58:32.44) ; ; (c) The software product is protected by copyright laws and ; international copyright treaties, as well as other in- ; tellectual property laws and treaties. ; The SOFTWARE PRODUCT is licensed, not sold. ; ; If you want to use the software for any (new) purpose ; you needs a license agreement, which can only be deli- ; vered by creator and owner of this software. ; begin. size=1022 Œ쪷ŵœ…—–ƒŽ…š‰ӵšѐȪ‰‡Ž‚< —кƒƶ‚ž›ˆڷ™չŒŽШ< ‹͠—Ÿ‰‘–‡‹“Žٿ›’Š㢡£ڣ—< ۺ컢…‡‹ŭ꺱ֻ˻—ɲœ˫„‹Ӿɰ< ٢˥𕉅–‚€„•œ„“ˆ< …„ȯž‘Ž™€„ѱ›˜›ت„‚š•…< ʍ‘Ҳ™”ͧƒ™’„ˆݠ€‰‰œհŸ“< ž…™͍а…ߧŒԨŒŸñܝŸկ™< œ’ƒˆ‘ȳ„Œ“‹—ˆˆ˜ˬҶ“‹< —ȵͯ—›Š“‡ƒ†’۹Œ‹˵„š’< •ηƒư•弲Ĩ†žߩƒ’Ш< ˮϨûʾҧ”……šˆֺœ‡貱ŽŪͣ—< ԳƵҽ‹€“ҳ›֧…––ɶȩ‚ɰ< ”–œͩ‰”œ˜†ƒ™ش™žөˆ< ڸεĹͻ˜žຣ”Ⱪ̼•”ס›–•…< ˜‘ܢ„™›“†’’˳†ˆŽ•Ž‚“< Œ駬–—ݭŒ‡™ѹ€˜±…™’‹•< €ˆ„Ү窶э›„€„…œŽΥž‡™ˆʺ‹< žܭ‹ߵ„•ˆ—ƒƲμ’⯽‘ؐ< ‚›†ӳʰϡ•’δ“תΧ†žš‹žШ< ߷„ݴ֠ˆŒ˜•å™›†€Ѫ߳—< ܫ‰ŒƒɰƒױŽ“Ÿœ獠âŒɰ< Ր–‚€†——ԏϤ€‘Ÿ< end: completed. end: crc16=52476 end: check=”Š˜— œŸˆ
After kixref: code:
Kixref example.kix 08-aug-2000 09:27:38 page 1 1 $MACADD = @address 2 $StDir = @startdir 3 call '01login.kix' 4 $filename = $INIFILE 5 $section = 'Survey' 6 $key = 'StartTime' 7 $string = $STIME 8 $WriteString = WRITEPROFILESTRING('$filename', '$section', '$key', '$string') 9 $key = 'EndTime' 10 $string = $ETIME 11 $WriteString = WRITEPROFILESTRING('$filename', '$section', '$key', '$string') 12 call '02globvar.kix' 13 call '03ulckdktp.kix' 14 call '04uaffil.kix' 15 call '05runmsd.kix' 16 :readrpt 17 :checkmac 18 1 IF $MACADD = '000000000000' 19 2 Select 20 2 Case Open(1,'c:\demerge\report.msd') = 0 21 $line = Readline(1) 22 :again 23 3 WHILE @ERROR = 0 24 4 SELECT 25 4 CASE INSTR($line,"Physical Station Number:") 26 $MACADD = SUBSTR(LTRIM(RTRIM($line)),LEN(LTRIM(RTRIM($line))) - 13 , 4 ) 27 $MACADD = $MACADD + 28 SUBSTR(LTRIM(RTRIM($line)),LEN(LTRIM(RTRIM($line))) - 8 , 4 ) 29 $MACADD = $MACADD + 30 SUBSTR(LTRIM(RTRIM($line)),LEN(LTRIM(RTRIM($line))) - 3 , 4 ) 31 close (1) 32 goto 'contin' 33 34 4 CASE INSTR($line,"NetBIOS Card Information:") 35 $line = Readline(1) 36 $MACADD = SUBSTR(LTRIM(RTRIM($line)),LEN(LTRIM(RTRIM($line))) - 11 , 12 ) 37 close (1) 38 goto 'contin' 39 40 4 ENDSELECT 41 $line = Readline(1) 42 3 LOOP 43 close (1) 44 $mheader = 'Unable to find MacAddress' 45 $message = $mheader + Chr(10) + Chr(10) 46 $message = $message + 'WINIPCFG will be launched.' + Chr(10) 47 $message = $message + 'Enter MacAddress on the next Survey Screen' 48 $selection = MESSAGEBOX($message, $mheader, 16) 49 RUN 'c:\windows\winipcfg.exe' 50 :nomac 51 Color b/n 52 BOX (8,21,20,61,) 53 Color g+/n 54 BOX (7,20,19,60,FULL) 55 $instruct1 = 'Enter "Adapter Address" below' 56 $instruct2 = 'Example -> 00CO4F8CB1FB' 57 $Selection = 'MAC ADDRESS: ' 58 $LenIns1 = 20 + ((40 - LEN($instruct1))/2) 59 $LenIns2 = 20 + ((40 - LEN($instruct2))/2) 60 AT(9,$LenIns1) $instruct1 61 AT(11,24) $instruct2 62 AT(17,24) $Selection 63 $x = (LEN($Selection) + 24) 64 AT(17,$x) Get $Ans 65 3 Select 66 3 Case LEN($Ans) = 12 67 $MACADD = $Ans 68 goto 'contin' 69 3 Case LEN($Ans) <> 12 70 goto 'nomac' 71 3 EndSelect 72 2 Case Open(1,'c:\demerge\report.msd') <> 0 73 ? "Unable to open 'report.msd'... survey halted!" 74 get $x 75 quit 76 2 EndSelect 77 1 EndIF 78 :contin 79 $filename = $INIFILE 80 $section = 'Computer' 81 $key = 'MacAddress' 82 $string = $MACADD 83 $WriteString = WRITEPROFILESTRING('$filename', '$section', '$key', '$string') 84 $messenger = 'Credit4Survey' 85 call 'messenger.kix' 86 Kixref example.kix 08-aug-2000 09:27:38 page 3 @address m 1 :again l 22 $ans v 64 66 67 69 AT f 60 61 62 64 b 51 BOX f 52 54 CALL c 3 12 13 14 15 85 CASE c 20 25 34 66 69 72 :checkmac l 17 CHR f 45 45 46 CLOSE f 31 37 43 COLOR c 51 53 :contin l 78 ENDIF c 77 ENDSELECT c 40 71 76 @error m 23 $etime v 10 $filename v 4 79 full 54 g 53 GET c 64 74 GOTO c 32 38 68 70 IF c 18 $inifile v 4 79 INSTR f 25 34 $instruct1 v 55 58 60 $instruct2 v 56 59 61 $key v 6 9 81 LEN f 26 28 30 36 58 59 63 66 69 $lenins1 v 58 60 $lenins2 v 59 $line v 21 25 26 26 28 28 30 30 34 35 36 36 41 LOOP c 42 LTRIM f 26 26 28 28 30 30 36 36 $macadd v 1 18 26 27 27 29 29 36 67 82 $message v 45 46 46 47 47 48 MESSAGEBOX f 48 $messenger v 84 $mheader v 44 45 48 n 51 53 :nomac l 50 OPEN f 20 72 QUIT c 75 READLINE f 21 35 41 :readrpt l 16 RTRIM f 26 26 28 28 30 30 36 36 RUN c 49 $section v 5 80 SELECT c 19 24 65 $selection v 48 57 62 63 @startdir m 2 $stdir v 2 $stime v 7 $string v 7 10 82 SUBSTR f 26 28 30 36 WHILE c 23 WRITEPROFILESTRING f 8 11 83 $writestring v 8 11 83 $x v 63 64 74 Kixref example.kix 08-aug-2000 09:27:38 page 5 Summary boldsymbols 0 commands 13 functions 13 labels 5 macros 3 variables 21 ? 4 59 Block Structure
do/until [0:0] if/else/endif [1:0:1] select/case/endselect [3:6:3] while/loop [1:1] Kixref example.kix 08-aug-2000 09:27:38 page 6 @address 1 :again 1 $ans 4 at 4 b 1 box 2 call 6 case 6 :checkmac 1 chr 3 close 3 color 2 :contin 1 endif 1 endselect 3 @error 1 $etime 1 $filename 2 full 1 g 1 get 2 goto 4 if 1 $inifile 2 instr 2 $instruct1 3 $instruct2 3 $key 3 len 9 $lenins1 2 $lenins2 1 $line 13 loop 1 ltrim 8 $macadd 10 $message 6 messagebox 1 $messenger 1 $mheader 3 n 2 :nomac 1 open 2 quit 1 readline 3 :readrpt 1 rtrim 8 run 1 $section 2 select 3 $selection 4 @startdir 1 $stdir 1 $stime 1 $string 3 substr 4 while 1 writeprofilestring 3 $writestring 3 $x 3
After kixstrip: code:
; ; Kixtart 3.62 ; ; (c) MCA - scripting@wanadoo.nl - 2000 ; ; The software product is protected by copyright laws and ; international copyright treaties, as well as other in- ; tellectual property laws and treaties. ; The SOFTWARE PRODUCT is licensed, not sold. ; ; If you want to use the software for any (new) purpose ; you needs a license agreement, which can only be deli- ; vered by creator and owner of this software. ; {{{ code has been removed. it blows up this topic }}}
After kixstrip with /debug and errors:
code:
?"- 1-" $MACADD = @address ?"- 2-" $StDir = @startdir ?"- 3-" call '01login.kix' ?"- 4-" $filename = $INIFILE ?"- 5-" $section = 'Survey' ?"- 6-" $key = 'StartTime' ?"- 7-" $string = $STIME?"-------> Warning KIXSTRIP: next line incomplete (parenthesis)." ?"- 8-" $WriteString = WRITEPROFILESTRING('$filename', '$section', '$key', ?"-------> Warning KIXSTRIP: next line incomplete (parenthesis)." ?"- 9-" '$string') ?"- 10-" $key = 'EndTime' ?"- 11-" $string = $ETIME ?"-------> Warning KIXSTRIP: next line incomplete (parenthesis)." ?"- 12-" $WriteString = WRITEPROFILESTRING('$filename', '$section', '$key', ?"-------> Warning KIXSTRIP: next line incomplete (parenthesis)." ?"- 13-" '$string') ?"- 14-" call '02globvar.kix' ?"- 15-" call '03ulckdktp.kix' ?"- 16-" call '04uaffil.kix' ?"- 17-" call '05runmsd.kix' ?"- 18-" :readrpt ?"- 19-" :checkmac ?"- 20-" IF $MACADD = '000000000000' ?"- 21-" Select ?"- 22-" Case Open(1,'c:\demerge\report.msd') = 0 ?"- 23-" $line = Readline(1) ?"- 24-" :again ?"- 25-" WHILE @ERROR = 0 ?"- 26-" SELECT ?"- 27-" CASE INSTR($line,"Physical Station Number:") ?"-------> Warning KIXSTRIP: next line incomplete (parenthesis)." ?"- 28-" $MACADD = SUBSTR(LTRIM(RTRIM($line)),LEN(LTRIM(RTRIM($line))) - ?"-------> Warning KIXSTRIP: next line incomplete (parenthesis)." ?"- 29-" 13 , 4 ) ?"- 30-" $MACADD = $MACADD + ?"- 31-" SUBSTR(LTRIM(RTRIM($line)),LEN(LTRIM(RTRIM($line))) - 8 , 4 ) ?"- 32-" $MACADD = $MACADD + ?"- 33-" SUBSTR(LTRIM(RTRIM($line)),LEN(LTRIM(RTRIM($line))) - 3 , 4 ) ?"- 34-" close (1) ?"- 35-" goto 'contin' ?"- 36-" ?"- 37-" CASE INSTR($line,"NetBIOS Card Information:") ?"- 38-" $line = Readline(1) ?"-------> Warning KIXSTRIP: next line incomplete (parenthesis)." ?"- 39-" $MACADD = SUBSTR(LTRIM(RTRIM($line)),LEN(LTRIM(RTRIM($line))) - ?"-------> Warning KIXSTRIP: next line incomplete (parenthesis)." ?"- 40-" 11 , 12 ) ?"- 41-" close (1) ?"- 42-" goto 'contin' ?"- 43-" ?"- 44-" ENDSELECT ?"- 45-" $line = Readline(1) ?"- 46-" LOOP ?"- 47-" close (1) ?"- 48-" $mheader = 'Unable to find MacAddress' ?"- 49-" $message = $mheader + Chr(10) + Chr(10) ?"- 50-" $message = $message + 'WINIPCFG will be launched.' + Chr(10) ?"-------> Warning KIXSTRIP: next line incomplete (single quotation)." ?"- 51-" $message = $message + 'Enter MacAddress on the next Survey ?"-------> Warning KIXSTRIP: next line incomplete (single quotation)." ?"- 52-" Screen' ?"- 53-" $selection = MESSAGEBOX($message, $mheader, 16) ?"- 54-" RUN 'c:\windows\winipcfg.exe' ?"- 55-" :nomac ?"- 56-" Color b/n ?"- 57-" BOX (8,21,20,61,) ?"- 58-" Color g+/n ?"- 59-" BOX (7,20,19,60,FULL) ?"- 60-" $instruct1 = 'Enter "Adapter Address" below' ?"-------> Warning KIXSTRIP: next line incomplete (single quotation)." ?"- 61-" $instruct2 = 'Example -> 00CO4F8CB1FB ?"- 62-" $Selection = 'MAC ADDRESS: ' ?"-------> Warning KIXSTRIP: next line incomplete (parenthesis)." ?"- 63-" $LenIns1 = 20 + ((40 - (LEN($instruct1))/2) ?"-------> Warning KIXSTRIP: next line incomplete (parenthesis)." ?"- 64-" $LenIns2 = 20 + ((40 - (LEN($instruct2))/2) ?"- 65-" AT(9,$LenIns1) $instruct1 ?"- 66-" AT(11,24) $instruct2 ?"- 67-" AT(17,24) $Selection ?"- 68-" $x = (LEN($Selection) + 24) ?"- 69-" AT(17,$x) Get $Ans ?"- 70-" Select ?"- 71-" Case LEN($Ans) = 12 ?"- 72-" $MACADD = $Ans ?"- 73-" goto 'contin' ?"- 74-" Case LEN($Ans) <> 12 ?"- 75-" goto 'nomac' ?"- 76-" EndSelect ?"- 77-" Case Open(1,'c:\demerge\report.msd') <> 0 ?"- 78-" ? "Unable to open 'report.msd'... survey halted!" ?"- 79-" get $x ?"- 80-" quit ?"- 81-" EndSelect ?"- 82-" EndIF ?"- 83-" :contin ?"- 84-" $filename = $INIFILE ?"- 85-" $section = 'Computer' ?"- 86-" $key = 'MacAddress' ?"- 87-" $string = $MACADD ?"-------> Warning KIXSTRIP: next line incomplete (parenthesis)." ?"- 88-" $WriteString = WRITEPROFILESTRING('$filename', '$section', '$key', ?"-------> Warning KIXSTRIP: next line incomplete (parenthesis)." ?"- 89-" '$string') ?"- 90-" $messenger = 'Credit4Survey' ?"- 91-" call 'messenger.kix' ; ; mon 07-aug-2000 22:42:43 ; ;Warning KIXSTRIP: 15 lines are incompleted.
After kixstrip with /debug and without errors:
code:
?"- 1-" $macadd=@address ?"- 2-" $stdir=@startdir ?"- 3-" CALL '01login.kix' ?"- 4-" $filename=$inifile ?"- 5-" $section='Survey' ?"- 6-" $key='StartTime' ?"- 7-" $string=$stime ?"- 8-" $writestring=WriteProfileString('$filename','$section','$key','$string') ?"- 9-" $key='EndTime' ?"- 10-" $string=$etime ?"- 11-" $writestring=WriteProfileString('$filename','$section','$key','$string') ?"- 12-" CALL '02globvar.kix' ?"- 13-" CALL '03ulckdktp.kix' ?"- 14-" CALL '04uaffil.kix' ?"- 15-" CALL '05runmsd.kix' ?"- 16-" :readrpt?"- 17-" :checkmac ?"- 18-" IF $macadd='000000000000' ?"- 19-" SELECT ?"- 20-" CASE Open(1,'c:\demerge\report.msd')=0 ?"- 21-" $line=ReadLine(1) ?"- 22-" :again ?"- 23-" WHILE @error=0 ?"- 24-" SELECT ?"- 25-" CASE Instr($line,"Physical Station Number:") ?"- 26-" $macadd=Substr(Ltrim(Rtrim($line)),Len(Ltrim(Rtrim($line)))-13,4) ?"- 27-" $macadd=$macadd+ ?"- 28-" Substr(Ltrim(Rtrim($line)),Len(Ltrim(Rtrim($line)))-8,4) ?"- 29-" $macadd=$macadd+ ?"- 30-" Substr(Ltrim(Rtrim($line)),Len(Ltrim(Rtrim($line)))-3,4) ?"- 31-" Close(1) ?"- 32-" GOTO 'contin' ?"- 33-" CASE Instr($line,"NetBIOS Card Information:") ?"- 34-" $line=ReadLine(1) ?"- 35-" $macadd=Substr(Ltrim(Rtrim($line)),Len(Ltrim(Rtrim($line)))-11,12) ?"- 36-" Close(1) ?"- 37-" GOTO 'contin' ?"- 38-" ENDSELECT ?"- 39-" $line=ReadLine(1) ?"- 40-" LOOP ?"- 41-" Close(1) ?"- 42-" $mheader='Unable to find MacAddress' ?"- 43-" $message=$mheader+Chr(10)+Chr(10) ?"- 44-" $message=$message+'WINIPCFG will be launched.'+Chr(10) ?"- 45-" $message=$message+'Enter MacAddress on the next Survey Screen' ?"- 46-" $selection=MessageBox($message,$mheader,16) ?"- 47-" RUN 'c:\windows\winipcfg.exe' ?"- 48-" :nomac ?"- 49-" COLOR b/n ?"- 50-" Box(8,21,20,61,) ?"- 51-" COLOR g+/n ?"- 52-" Box(7,20,19,60,full) ?"- 53-" $instruct1='Enter "Adapter Address" below' ?"- 54-" $instruct2='Example -> 00CO4F8CB1FB' ?"- 55-" $selection='MAC ADDRESS: ' ?"- 56-" $lenins1=20+((40-Len($instruct1))/2) ?"- 57-" $lenins2=20+((40-Len($instruct2))/2) ?"- 58-" At(9,$lenins1)$instruct1 ?"- 59-" At(11,24)$instruct2 ?"- 60-" At(17,24)$selection ?"- 61-" $x=(Len($selection)+24) ?"- 62-" At(17,$x)GET $ans ?"- 63-" SELECT ?"- 64-" CASE Len($ans)=12 ?"- 65-" $macadd=$ans ?"- 66-" GOTO 'contin' ?"- 67-" CASE Len($ans)<>12 ?"- 68-" GOTO 'nomac' ?"- 69-" ENDSELECT ?"- 70-" CASE Open(1,'c:\demerge\report.msd')<>0 ?"- 71-" ?"Unable to open 'report.msd'... survey halted!" ?"- 72-" GET $x ?"- 73-" QUIT ?"- 74-" ENDSELECT ?"- 75-" ENDIF ?"- 76-" :contin ?"- 77-" $filename=$inifile ?"- 78-" $section='Computer' ?"- 79-" $key='MacAddress' ?"- 80-" $string=$macadd ?"- 81-" $writestring=WriteProfileString('$filename','$section','$key','$string') ?"- 82-" $messenger='Credit4Survey' ?"- 83-" CALL 'messenger.kix'
Greetings. [ 22 January 2002: Message edited by: MCA ]
|