Does Freecad use GPU?

Post here for help on using FreeCAD's graphical user interface (GUI).
Forum rules
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help

Also, be nice to others! Read the FreeCAD code of conduct!
Laurie Hartley
Posts: 526
Joined: Mon Feb 27, 2017 5:33 am
Location: Australia

Re: Does Freecad use GPU?

Post by Laurie Hartley »

chrisb wrote: Mon Jan 31, 2022 6:34 am
Laurie Hartley wrote: Mon Jan 31, 2022 6:26 am what do you make of my comparison - the older computer with 3Gib of ram loads FreeCAD programme faster but the file slower?
There is more to consider for a comparison: a first guess would be a faster harddisk on the older computer, or even an SSD; do you use the same OS; was it directly after booting; was freecad started before on the older, ...?
The Thinkpad has an M.2 Slot 1x 2280 M.2 NVMe slot and MX Linux 19 OS with XFCE
The Dell has 2.5” magnetic hard drive and Antix Linux OS with ICEWM - very lightweight for older machines

I am away from my computers at the moment (on an iPad) but I will shut both machines down and run the tests again on each machine directly after booting.
GeneFC
Veteran
Posts: 5373
Joined: Sat Mar 19, 2016 3:36 pm
Location: Punta Gorda, FL

Re: Does Freecad use GPU?

Post by GeneFC »

thomas-neemann wrote: Mon Jan 31, 2022 7:50 am what cpu clock does your pc have and how long does it take for the test file?
I spent a career in R&D in the semiconductor industry. What I said was correct.

As chrisb points out there are many factors that control the speed of operations. Of course clock speed has an impact, but that is only one of many.

GPUs are effective due to specialized architecture and massive hardware parallelism. They also tend to have high clock speeds, but that is only a small contributor to the GPU throughput.

The reason clock speed leveled out a couple of decades ago is due to power considerations and even speed of light. The power required by a switching circuit, such as a transistor, is proportional to the frequency (inverse of clock speed), the capacitance, and the voltage squared. Years ago the industry roadmaps for semiconductors showed clock speed heading to 10 GHz and beyond. It did not take long to realize that each computer would need to be water-cooled and include a fire extinguisher system.

The alternative was to work on the architecture to continue to improve throughput without increasing clock speed.

If you have two otherwise identical processors with different clock speeds the faster speed will lead to faster throughput. For processors with different internal structures all bets are off regarding impact of clock speed.

Gene
TheMarkster
Veteran
Posts: 5513
Joined: Thu Apr 05, 2018 1:53 am

Re: Does Freecad use GPU?

Post by TheMarkster »

It matters less how long it takes to load file than how long it takes to recompute the file. I would use the recompute profiler macro for such comparisons.
User avatar
thomas-neemann
Veteran
Posts: 11915
Joined: Wed Jan 22, 2020 6:03 pm
Location: Osnabrück DE 🇩🇪
Contact:

Re: Does Freecad use GPU?

Post by thomas-neemann »

TheMarkster wrote: Mon Jan 31, 2022 4:31 pm It matters less how long it takes to load file ..
with ifc import it is currently a huge problem. Strangely, the cpu core load does not go to 100%
Gruß Dipl.-Ing. (FH) Thomas Neemann

https://www.youtube.com/@thomasneemann5 ... ry=freecad
TheMarkster
Veteran
Posts: 5513
Joined: Thu Apr 05, 2018 1:53 am

Re: Does Freecad use GPU?

Post by TheMarkster »

It could be the importer is running in a single thread and one core is getting pegged out to 100%, but in the case for example of a quad core system, you only ever see 25% utilization and it gets spread periodically from one core to another.

I don't do a lot of importing, so I guess it matters less to me than recompute times because when I am working on a model I want the recomputes to happen faster. I also want calls to OCC to be faster, such as check geometry, booleans, fillets, etc.
User avatar
thomas-neemann
Veteran
Posts: 11915
Joined: Wed Jan 22, 2020 6:03 pm
Location: Osnabrück DE 🇩🇪
Contact:

Re: Does Freecad use GPU?

Post by thomas-neemann »

TheMarkster wrote: Mon Jan 31, 2022 4:41 pm It could be the importer is running in a single thread and one core is getting pegged out to 100%, but in the case for example of a quad core system, you only ever see 25% utilization and it gets spread periodically from one core to another.
..
I have taken that into account. my analysis tool shows it separately
1.png
1.png (11.12 KiB) Viewed 1528 times
Gruß Dipl.-Ing. (FH) Thomas Neemann

https://www.youtube.com/@thomasneemann5 ... ry=freecad
User avatar
thomas-neemann
Veteran
Posts: 11915
Joined: Wed Jan 22, 2020 6:03 pm
Location: Osnabrück DE 🇩🇪
Contact:

Re: Does Freecad use GPU?

Post by thomas-neemann »

GeneFC wrote: Mon Jan 31, 2022 3:36 pm ping
i agree with you, in general it is like that, but in freecad the clock speed seems to be dominant.
Example of the blister from frecad-heini-1

https://www.dropbox.com/s/ly7m7juexi42a ... fcstd?dl=0


1.png
1.png (242.76 KiB) Viewed 1477 times


that takes about twice as long in the y interval (8) on an i5 6200u with 2.3 ghz than on a ryzen 7 3800x with 3.9 ghz. this roughly corresponds to the different timing

OS: Ubuntu 20.04.1 LTS (XFCE/xubuntu)
Word size of FreeCAD: 64-bit
Version: 0.20.27078 (Git) AppImage
Build type: Release
Branch: (HEAD detached at bcdd926)
Hash: bcdd926686f2245fe60baface1cce1ab3dff7a5b
Python version: 3.9.9
Qt version: 5.12.9
Coin version: 4.0.0
OCC version: 7.5.3
Locale: German/Germany (de_DE)
Gruß Dipl.-Ing. (FH) Thomas Neemann

https://www.youtube.com/@thomasneemann5 ... ry=freecad
GeneFC
Veteran
Posts: 5373
Joined: Sat Mar 19, 2016 3:36 pm
Location: Punta Gorda, FL

Re: Does Freecad use GPU?

Post by GeneFC »

thomas-neemann wrote: Mon Jan 31, 2022 6:44 pm that takes about twice as long in the y interval (8) on an i5 6200u with 2.3 ghz than on a ryzen 7 3800x with 3.9 ghz. this roughly corresponds to the different timing
Is this a joke? Comparing a 6-year old dual-core low-power laptop processor with a new 8-core fire-breathing monster?

Do I need to state it differently? Did you not understand what I wrote?

Gene
User avatar
thomas-neemann
Veteran
Posts: 11915
Joined: Wed Jan 22, 2020 6:03 pm
Location: Osnabrück DE 🇩🇪
Contact:

Re: Does Freecad use GPU?

Post by thomas-neemann »

GeneFC wrote: Mon Jan 31, 2022 7:07 pm ...
Is this a joke? .
I got it, but these are the values ​​that I measured myself
Gruß Dipl.-Ing. (FH) Thomas Neemann

https://www.youtube.com/@thomasneemann5 ... ry=freecad
wieszak17
Posts: 250
Joined: Fri Jan 10, 2014 7:59 pm

Re: Does Freecad use GPU?

Post by wieszak17 »

thomas-neemann wrote: Mon Jan 31, 2022 7:28 pm
GeneFC wrote: Mon Jan 31, 2022 7:07 pm ...
Is this a joke? .
I got it, but these are the values ​​that I measured myself
Well, long time ago i was writing program for controlling selfmade CNC connected to parport. Speed of step motors was controlled by delays in that program. At the time CPU was Pentium-III @433MHz. usleep() was a bit slow for my liking so i ended with "for (i=0;i<1000;i++);;" - and it worked great. But not that long ago motherboard died. So i got board with Intel Atom 1.6 GHz. You would say that i need much bigger number in that loop. In reality... i set 1600 instead of that 1000 to get same speed. 1.6GHz processor few generations better is only 1.6x faster...

Also, why you are comparing file load time to measure GPU? Wouldn't be better load complicated object, start turntable view and check fps? Unless quiestoin is if FC is using GPU for anything besides OpenGL scene?
Post Reply