Ignore:
Timestamp:
Feb 8, 2011, 11:05:30 AM (14 years ago)
Author:
george
Message:
  • Modified: Optimalized microthread execution from main thread.
  • Fixed: Passthrough of WaitFor on already signaled event.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • MicroThreading/UMicroThreadList.pas

    r162 r164  
    77uses
    88  Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, ComCtrls,
    9   ExtCtrls, StdCtrls, DateUtils;
     9  ExtCtrls, StdCtrls, DateUtils, UPlatform;
    1010
    1111type
     
    1414
    1515  TMicroThreadListForm = class(TForm)
     16  published
     17    Label10: TLabel;
     18    Label5: TLabel;
     19    Label6: TLabel;
     20    Label7: TLabel;
     21    Label8: TLabel;
     22    Label9: TLabel;
     23    TimerRedraw: TTimer;
    1624    Label1: TLabel;
    1725    Label2: TLabel;
    1826    ListView1: TListView;
    1927    ListView2: TListView;
    20     Panel1: TPanel;
    21     Panel2: TPanel;
    22     Splitter1: TSplitter;
    23     TimerRedraw: TTimer;
     28    PageControl1: TPageControl;
     29    TabSheet1: TTabSheet;
     30    TabSheet2: TTabSheet;
     31    TabSheet3: TTabSheet;
     32    procedure FormClose(Sender: TObject; var CloseAction: TCloseAction);
    2433    procedure FormHide(Sender: TObject);
    2534    procedure FormShow(Sender: TObject);
     
    5766  ListView2.Items[-1];
    5867  ListView2.Refresh;
     68
     69  Label6.Caption := IntToStr(GetLogicalProcessorCount);
     70  Label9.Caption := IntToStr(MainScheduler.ThreadPoolCount);
     71  Label10.Caption := IntToStr(MainScheduler.MicroThreadCount);
     72  Label2.Caption := FloatToStr(MainScheduler.MainThreadOutsideDuration / OneMillisecond) + ' ms';
    5973end;
    6074
     
    120134end;
    121135
     136procedure TMicroThreadListForm.FormClose(Sender: TObject;
     137  var CloseAction: TCloseAction);
     138begin
     139  TimerRedraw.Enabled := False;
     140end;
     141
    122142
    123143end.
Note: See TracChangeset for help on using the changeset viewer.