Jump to content

Search the Community

Showing results for tags 'tparallel.for'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Delphi Questions and Answers
    • Algorithms, Data Structures and Class Design
    • VCL
    • FMX
    • RTL and Delphi Object Pascal
    • Databases
    • Network, Cloud and Web
    • Windows API
    • Cross-platform
    • Delphi IDE and APIs
    • General Help
    • Delphi Third-Party
  • C++Builder Questions and Answers
    • General Help
  • General Discussions
    • Embarcadero Lounge
    • Tips / Blogs / Tutorials / Videos
    • Job Opportunities / Coder for Hire
    • I made this
  • Software Development
    • Project Planning and -Management
    • Software Testing and Quality Assurance
  • Community
    • Community Management

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Delphi-Version

Found 1 result

  1. I am using delphi 11.2 in windows Full source attached Either one only run 1 thread,please help me,thanks. ==================================================== procedure TForm1.btnParallelForClick(Sender: TObject); TParallel.For(0,System.CPUCount,procedure(I:Int64) var thinkstep: string; begin MinMax(board,mutiSideisRed,8,thinkstep); end; end); ===================================================== procedure TForm1.btnTTaskClick(Sender: TObject); var tasks: array of ITask; thinkstep : array of string; SW: TStopwatch; a:integer; begin Setlength (tasks ,System.CPUCount); Setlength (thinkstep ,System.CPUCount+1); ReInitboard; SW :=TStopWatch.Create; for a := 0 to System.CPUCount-1 do begin thinkstep[a+1] := ''; tasks[a] := TTask.Create (procedure () begin PMinMax(board,mutiSideisRed,8,thinkstep[a]); end); end; for a := 0 to System.CPUCount-1 do tasks[a].Start; TTask3.zip
×