lisp2arx
Visual Programming for AutoLisp Mathématiques en programmation Lisp.. doc2cpp,doc2lsp, sld2lsp, bmp2dcl, free__GifCcapture for all-CAD'platforms..
Lista Forumurilor Pe Tematici
lisp2arx | Reguli | Inregistrare | Login

POZE LISP2ARX

Nu sunteti logat.
Nou pe simpatie:
vio69
Femeie
25 ani
Botosani
cauta Barbat
25 - 50 ani
lisp2arx / Delphi , InnoPascal / Delphi32- TStackSize calculate how much stack full  
Autor
Mesaj Pagini: 1
admin
Administrator

Din: Bucharest
Inregistrat: acum 13 ani
Postari: 515
Q:How can I see how much of decrease from stackspace inside each'functions?
Compare StackOlverFlow for each-types?
Q:how can I see how much of the stack space is currently used in my  dpr/lpr?"
{--}
Shx=288  ID_DevHelp="You do use this type. Very ugly types of parametric"
Shp=28
Sht=32
STb=12
STb1=0 ID_DevHelp="Maybe here are errror/s?"
STL=24
STO=8
STOR=28
STS=0
*BORDERX2,____  ____  .  ____  ____  .  ____  ____  .  ____  ____  .

Code:

Program tstacksize;
Uses windows,sysutils;
{$AppType CONSOLE}
Var stk:record
         org:integer;
         shx,shp,sht:integer;
         stb,stb1,stl,sto,stor,sts,shs:integer;
        end;

Function getvar_tstacksize:integer;
asm
  mov eax, fs:[4]
  sub eax, esp
end;

Var ecobo:string='4     M     Sf. Cuv. Ioanichie cel Mare; Sf. Mc. Nicandru Ep. si Ermeu pr. (Post) ';
    domenicomaria:shortstring='+ Sf. M. Mc. Varvara; Sf. Cuv. Ioan Damaschin (Dezlegare la ulei si vin)';
    kauff:integer;
    rr:string;

Procedure shx(a:shortstring);
Begin stk.shx:=stk.org-getvar_tstacksize;
      kauff:=length(a);rr:=concat(rr,a,#13#10);
End;

Procedure shp(const a:shortstring);
Begin stk.shp:=stk.org-getvar_tstacksize;
      kauff:=length(a);rr:=concat(rr,a,#13#10);
End;

Procedure sht(Var a:shortstring);
Begin stk.sht:=stk.org-getvar_tstacksize;
      kauff:=length(a);rr:=concat(rr,a,#13#10);
End;

Procedure stb(const a:string);
Begin
       stk.stb:=stk.org-getvar_tstacksize;
       kauff:=length(a);rr:=concat(rr,a,#13#10);
End;

Procedure stb1(const a:string);
Var f:string;
Begin
       f:=lowercase(a);
       stk.stb1:=stk.org-getvar_tstacksize;
       kauff:=length(f);rr:=concat(rr,a,#13#10);
End;

Procedure stl(a:string);
Begin
      stk.stl:=stk.org-getvar_tstacksize;
      kauff:=length(a);rr:=concat(rr,a,#13#10);
End;

Procedure sto(Var a:string);
Begin
      stk.sto:=stk.org-getvar_tstacksize;
      kauff:=length(a);rr:=concat(rr,a,#13#10);
End;

Procedure stor(a:string);
Begin
      stk.stor:=stk.org-getvar_tstacksize;
      a:=lowercase(a);
      kauff:=length(a);rr:=concat(rr,a,#13#10);
End;

Procedure sts(a:pchar;len:integer);
Begin
       stk.sto:=stk.org-getvar_tstacksize;
End;

Begin
       rr:='';
       Writeln('Compare StackOlverFlow for types');
       stk.org:=getvar_tstacksize();shx(domenicomaria);
       stk.org:=getvar_tstacksize();shp(domenicomaria);
       stk.org:=getvar_tstacksize();sht(domenicomaria);
       stk.org:=getvar_tstacksize();stb(ecobo);
       stk.org:=getvar_tstacksize();stl(ecobo);
       stk.org:=getvar_tstacksize();sto(ecobo);
       stk.org:=getvar_tstacksize();stor('12345678901234567890');
       stk.org:=getvar_tstacksize();sts(pchar(ecobo),length(ecobo));
       writeln('Shx=',abs(stk.shx));windows.beep(kauff,30);
       writeln('Shp=',abs(stk.shp));windows.beep(kauff,30);
       writeln('Sht=',abs(stk.sht));windows.beep(kauff,30);
       writeln('STb=',abs(stk.stb));windows.beep(kauff,30);
       writeln('STb1=',abs(stk.stb1));windows.beep(kauff,30);       
       writeln('STL=',abs(stk.stl));windows.beep(kauff,30);
       writeln('STO=',abs(stk.stO));windows.beep(kauff,30);
       writeln('STOR=',abs(stk.stor));windows.beep(kauff,30);
       writeln('STS=',abs(stk.sts));windows.beep(kauff,30);
       Writeln('*BORDERX2,____  ____  .  ____  ____  .  ____  ____  .  ____  ____  .  ');
       writeln('The Big"Number"s are wrongs. The lower-numbers are good');
       readln;
       writeln(rr);
End.



_______________________________________


pus acum 3 ani
   
Pagini: 1  

Mergi la