Recent

Author Topic: TPowerThread  (Read 9340 times)

mercurhyo

  • Full Member
  • ***
  • Posts: 242
Re: TPowerThread
« Reply #15 on: July 17, 2018, 03:50:40 am »
Maybe it is the choice for named events. I have no experience/need for those.

It does not matter as long as pSecurityAttributes is NIL and you access Events LOCALY in the same Process. named TEvent is a Global systemwide stuff (can be used interprocess way), so I have my safe habits  ;) while writing code from scratch and on the fly
« Last Edit: July 17, 2018, 04:14:19 am by mercurhyo »
DEO MERCHVRIO - Linux, Win10pro - Ryzen9XT 24threads + Geforce Rtx 3080SUPRIM
god of financial gain, commerce, eloquence (and thus poetry), messages, communication (including divination), travelers, boundaries, luck, trickery and thieves; he also serves as the guide of souls to the underworld

mercurhyo

  • Full Member
  • ***
  • Posts: 242
Re: TPowerThread
« Reply #16 on: July 17, 2018, 05:33:45 am »
with my TPowerThread template as starting point, you can parallelize :
- offscreen bitmaps drawings
- blocking sockets and ports
- heavy maths computations
- compilation of files
- ... and damn much more if applied to game engines IA programming
 :D
Enjoy!

just a draft idea to let you imagine...

...Post(@TPowThreadDerived.Compile, [SourceName[idx], OutFileName[idx], CompilerPath, options], Done, @MyCallBack, ErrorsPointerBuffer);

assuming you have an array[0..Pred(cpucount)] of TPowerThread ... the speedup could be awesome around compilation

TPowerThread is a NICE TOY
« Last Edit: July 17, 2018, 06:53:52 am by mercurhyo »
DEO MERCHVRIO - Linux, Win10pro - Ryzen9XT 24threads + Geforce Rtx 3080SUPRIM
god of financial gain, commerce, eloquence (and thus poetry), messages, communication (including divination), travelers, boundaries, luck, trickery and thieves; he also serves as the guide of souls to the underworld

mercurhyo

  • Full Member
  • ***
  • Posts: 242
Re: TPowerThread
« Reply #17 on: July 18, 2018, 03:33:27 pm »
Looks promising. You should create a runtime package and add a few examples so other people can test.
NO
- I Give away what I want, when I want
- I did never obey to morons, SO don't count on me @getmom
- As i read some of your posts (some are hilarious due to your messed up level), you have definitely no ability to critcize me, jealous paranoid @getmom
 :D
DEO MERCHVRIO - Linux, Win10pro - Ryzen9XT 24threads + Geforce Rtx 3080SUPRIM
god of financial gain, commerce, eloquence (and thus poetry), messages, communication (including divination), travelers, boundaries, luck, trickery and thieves; he also serves as the guide of souls to the underworld

howardpc

  • Hero Member
  • *****
  • Posts: 4144
Re: TPowerThread
« Reply #18 on: July 18, 2018, 05:36:41 pm »
@mercurhyo
You are stepping way over the bounds of civilised discourse in your last post.
GetMem did not criticize you. "Looks promising" is criticism?
You may not want to follow his suggestion of creating a runtime package and examples. OK. It was merely a suggestion, made in good faith. To accuse him of jealousy and paranoia is completely unwarranted.
If you continue in this vein, no matter how exalted your coding skills and programming insights, I think the moderators will be down on you.

mercurhyo

  • Full Member
  • ***
  • Posts: 242
Re: TPowerThread
« Reply #19 on: July 18, 2018, 11:47:11 pm »
@howardpc

- I am not afraid of any kind of ban, because I have already been banned here when I was gulyone, and I already mentioned it (nothing to hide)
- no matter if i get banned and banned again, I also mentioned, that I am NEVER the looser one
- to let you know what is going on with @gotmom, you can follow
https://forum.lazarus.freepascal.org/index.php/topic,41867.15.html
and his stupid "reflexions"
- finaly = if people do not want what I give, no problem... as usually, I can sell it in final products!!! what is FUNNY: the fact that i am pretty sure that some "jealous idiots" buy them HAHAHAHA
« Last Edit: July 18, 2018, 11:48:47 pm by mercurhyo »
DEO MERCHVRIO - Linux, Win10pro - Ryzen9XT 24threads + Geforce Rtx 3080SUPRIM
god of financial gain, commerce, eloquence (and thus poetry), messages, communication (including divination), travelers, boundaries, luck, trickery and thieves; he also serves as the guide of souls to the underworld

mercurhyo

  • Full Member
  • ***
  • Posts: 242
Re: TPowerThread
« Reply #20 on: July 18, 2018, 11:58:46 pm »
here is all my "disorder" LOL  :D
DEO MERCHVRIO - Linux, Win10pro - Ryzen9XT 24threads + Geforce Rtx 3080SUPRIM
god of financial gain, commerce, eloquence (and thus poetry), messages, communication (including divination), travelers, boundaries, luck, trickery and thieves; he also serves as the guide of souls to the underworld

mercurhyo

  • Full Member
  • ***
  • Posts: 242
Re: TPowerThread
« Reply #21 on: July 19, 2018, 04:56:27 am »
patch to v0.6
Code: Pascal  [Select][+][-]
  1. destructor TThreadedComponent.Destroy;
  2. begin
  3.   FThread.Suspended := True;
  4.   FThread.Terminate;
  5.   FThread.FWake.SetEvent; // don't wait
  6.   FThread.Suspended := False;
  7.   inherited Destroy;
  8. end;
  9.  
DEO MERCHVRIO - Linux, Win10pro - Ryzen9XT 24threads + Geforce Rtx 3080SUPRIM
god of financial gain, commerce, eloquence (and thus poetry), messages, communication (including divination), travelers, boundaries, luck, trickery and thieves; he also serves as the guide of souls to the underworld

 

TinyPortal © 2005-2018