Author Topic: Multi core processor processing...  (Read 739 times)

0 Members and 1 Guest are viewing this topic.

ribarm

  • Gator
  • Posts: 3279
  • Marko Ribar, architect
Multi core processor processing...
« on: March 15, 2024, 01:25:48 PM »
I wonder...
I have this in my little brain - somewhere I saw that Evgeniy played with 8 cored processor and performed testings... I just can't remember did he combined them to work with AutoCAD... I know that CAD works only with single core, but nevertheless I want to ask this... That my slow routine for roofs works pretty slow, so just seeking for some comments...
Any feedback is welcomed...
Is future of CAD pointed in direction of using full power of PC, or not, and if I have powerful GPU - is that also included in enormous calculations...
Marko Ribar, d.i.a. (graduated engineer of architecture)

:)

M.R. on Youtube

ribarm

  • Gator
  • Posts: 3279
  • Marko Ribar, architect
Re: Multi core processor processing...
« Reply #1 on: March 15, 2024, 02:43:55 PM »
To be honest...
When CAD is calculating and I open Task Manager I see only one window for CPU and it shows 30-40% although it's stated that CPU - 1 socket - 2 cores - 4 logical processors... It is Laptop where I am seeing this info... And processor description is : Intel(R) Core(TM) i5-6200U CPU @ 2.30GHz...
Marko Ribar, d.i.a. (graduated engineer of architecture)

:)

M.R. on Youtube

JohnK

  • Administrator
  • Seagull
  • Posts: 10651
Re: Multi core processor processing...
« Reply #2 on: March 15, 2024, 03:16:29 PM »
Sorry, no threading for Lisp. Not sure you may even need threading perse.

For example:
I did threading in the last UNIX app I wrote; my app read from one file and wrote to another. I choose to implement threading because it was fun(er) and I wanted/needed atomic reading/writing. So, in other words, my app needed to read/write the file(s) in sequential chunks, and I wanted to make sure that wasn't interrupted. To do that I created a simple synchro method (a function to manage threads in case a process was blocked) to read a chunk of text and pass that along to other function(s) to parse/do something.

My threading monitor function just monitors an array of file descriptors and if an operation causes a thread to block, my function then schedules another runnable thread. In a single threaded operation if a process blocks, the entire operation needs to block (wait). The process I was preforming took nanoseconds on my 10 year old laptop so in reality my monitoring function was only creating two threads but like I said above, I was playing around too.

After I finish my process my synchro function just joins all the threads and closes up shop.

So, in crude terms, my app will "write or wait to write". It is a sort of guarantee for making sure data isn't corrupted. This isn't a "have one thread calculate this" and "another thread do that" type of thing because in the case of a long/involved calculation your other threads would have to block until information becomes available (the calc is preformed) so threading would gain you nothing (and you don't need atomic operations).
TheSwamp.org (serving the CAD community since 2003)
Member location map - Add yourself

Donate to TheSwamp.org

VovKa

  • Water Moccasin
  • Posts: 1632
  • Ukraine
Re: Multi core processor processing...
« Reply #3 on: March 16, 2024, 08:14:10 AM »
I wonder...
I have this in my little brain - somewhere I saw that Evgeniy played with 8 cored processor and performed testings... I just can't remember did he combined them to work with AutoCAD... I know that CAD works only with single core, but nevertheless I want to ask this... That my slow routine for roofs works pretty slow, so just seeking for some comments...
Any feedback is welcomed...
Is future of CAD pointed in direction of using full power of PC, or not, and if I have powerful GPU - is that also included in enormous calculations...
Evgeniy did it by starting multiple instances of accoreconsole.exe, thus distributing independent tasks, but it is not always possible of course :(

VovKa

  • Water Moccasin
  • Posts: 1632
  • Ukraine

It's Alive!

  • Retired
  • Needs a day job
  • Posts: 8728
  • AKA Daniel
Re: Multi core processor processing...
« Reply #5 on: March 16, 2024, 09:37:06 AM »
Python kinda has the same limitation, for modal commands, I must acquire a lock which blocks. Modeless is free to do threaded stuff, though threads a blocked if you call back into the wrappers.
“They” aren’t really doing the AI / Big data work in Python, data is being sent off to be processed with the results returned. You could do the same for lisp


ribarm

  • Gator
  • Posts: 3279
  • Marko Ribar, architect
Re: Multi core processor processing...
« Reply #6 on: March 16, 2024, 10:01:46 AM »
here's his presentation
https://www.theswamp.org/index.php?action=dlattach;topic=49099.0;attach=29799

Thanks for the link VovKa... So Evgeniy wrote *.VLX for nesting...
Just in case he didn't know there is this - deepnest.io : https://deepnest.io/
Marko Ribar, d.i.a. (graduated engineer of architecture)

:)

M.R. on Youtube

VovKa

  • Water Moccasin
  • Posts: 1632
  • Ukraine
Re: Multi core processor processing...
« Reply #7 on: March 16, 2024, 10:58:47 AM »
Just in case he didn't know there is this - deepnest.io : https://deepnest.io/
i'm sure he is capable of doing great things by himself
https://web.archive.org/web/20190326175425/http://elpanov.com/index.php?id=69

ribarm

  • Gator
  • Posts: 3279
  • Marko Ribar, architect
Re: Multi core processor processing...
« Reply #8 on: March 16, 2024, 11:25:50 AM »
Back in 2016, I did something in that manner : https://www.theswamp.org/index.php?topic=52260.0
But I am sure you know better and Evgeniy of course...
Marko Ribar, d.i.a. (graduated engineer of architecture)

:)

M.R. on Youtube

ribarm

  • Gator
  • Posts: 3279
  • Marko Ribar, architect
Re: Multi core processor processing...
« Reply #9 on: April 01, 2024, 03:31:28 AM »
Just saw in resource monitor...
All cores are working when routine is started from BricsCAD/AutoCAD, only some cores are 20-30 % and only one 4th on my Laptop is 80-90 %...
How should I make it all cores to 80-90 % ?

Thanks all...
« Last Edit: April 01, 2024, 03:38:05 AM by ribarm »
Marko Ribar, d.i.a. (graduated engineer of architecture)

:)

M.R. on Youtube