Author Topic: 4GB Patch  (Read 691 times)

Offline Bob La Londe

  • CNC Jedi
  • *****
  • Posts: 3965
  • ^ 8.5 pounds on my own hand poured bait.
    • View Profile
    • CNC Molds N Stuff
4GB Patch
« on: March 24, 2020, 19:14:15 pm »
I have been using a W10Pro64 machine for a while now, and occasionally I still run into memory limit errors with CB.  Since I do more and more complex things I figured I was just running into the limits of the 32bit software... and I was sort of.  Usually I could make a few tweaks, hide all complex geometry, and start code generation from a freshly opened session.  The other day none of that work.  It was driving me bonkers.  I was about to the point of generating separate code files and editing them together with Notepad++. 

Then it occurred to me that I had never done the 4GB patch on this installation of CamBam.  I was not hopeful as nothing works like it "used to" in W10, but I found the software and gave it a go. 

Code not only generated, but it generated much faster.  I did bump the worker threads up  to 4 as for some reason I had not set that either. 

I still think CB either needs to implement some form of memory page swapping to the drive, or upgrade to a 64bit version that has the ability to address more memory, but the old 4GB patch got me through this time. 



Getting started on CNC?  In or passing through my area?
If I have the time I'll be glad to show you a little in my shop. 

Some Stuff I Make with CamBam
http://www.CNCMOLDS.com

Offline dh42

  • Administrator
  • CNC Jedi
  • *****
  • Posts: 6073
    • View Profile
    • Cambam V1.0 French Doc
Re: 4GB Patch
« Reply #1 on: March 24, 2020, 22:48:34 pm »
Hello Bob

Yes this patch is very helpful, and remember it must be applied each time CB is upgraded because it change something in the cambam.exe itself. The original .exe file is renamed CamBam.exe.Backup so if you want to "un patch" cb, just delete the cambam.exe patched file and rename the cambam.exe.Backup to cambam.exe

Quote
I still think CB either needs to implement some form of memory page swapping to the drive

Yep, using the hard drive would be fine, especially now with SSD drive.

On VisualMill, when we generate the toolpaths the HD is used, I don't know exactly how, but what I'm sure it's that the toolpath are saved to the drive after calculation, because if you quit/run the soft, it is not needed to run the toolpaths calculation again if nothing as been changed in a mop. It's a very good things when using 3d mop like waterline that are very long to calculate (as with CB) ; you can close and open the soft and the toolpaths are still here !

Quote
I did bump the worker threads up  to 4 as for some reason I had not set that either.

Yes, CB can use one worker thread / mop so it can improve calculation speed on projects that use many mops.

Use a value = the number of threads of your CPU, not the number of core to get the max speed ;)
(ex: on a core i7 ; 8 threads , 4 cores, so set the the worker threads to 8 )

++
David

Offline Bob La Londe

  • CNC Jedi
  • *****
  • Posts: 3965
  • ^ 8.5 pounds on my own hand poured bait.
    • View Profile
    • CNC Molds N Stuff
Re: 4GB Patch
« Reply #2 on: March 25, 2020, 00:20:13 am »
I thought I had read somewhere that CB maxed at 4 worker threads? 
Getting started on CNC?  In or passing through my area?
If I have the time I'll be glad to show you a little in my shop. 

Some Stuff I Make with CamBam
http://www.CNCMOLDS.com

Offline dh42

  • Administrator
  • CNC Jedi
  • *****
  • Posts: 6073
    • View Profile
    • Cambam V1.0 French Doc
Re: 4GB Patch
« Reply #3 on: March 25, 2020, 01:25:14 am »
Seems it is working for 8

if set to 4 my 8 thread CPU is used 50% of power (10 mop to calculate) and it run at 100% if set to 8 (and of course if there is at least 8 mop to calculate)

It is not needed to restart CB after changing the worker thread number, the new setting is immediately used.

++
David
« Last Edit: March 25, 2020, 01:31:55 am by dh42 »

Offline Bob La Londe

  • CNC Jedi
  • *****
  • Posts: 3965
  • ^ 8.5 pounds on my own hand poured bait.
    • View Profile
    • CNC Molds N Stuff
Re: 4GB Patch
« Reply #4 on: March 25, 2020, 02:34:16 am »
That is a pretty definitive test, and I was able to duplicate your results.  8 it is. 
Getting started on CNC?  In or passing through my area?
If I have the time I'll be glad to show you a little in my shop. 

Some Stuff I Make with CamBam
http://www.CNCMOLDS.com

Offline Tycho-X

  • Ewok
  • *
  • Posts: 12
    • View Profile
Re: 4GB Patch
« Reply #5 on: August 01, 2020, 05:15:24 am »
Hi,

does the Linux version has a memory limit too? If yes, how to allow for more RAM usage?

cheers...

Offline dh42

  • Administrator
  • CNC Jedi
  • *****
  • Posts: 6073
    • View Profile
    • Cambam V1.0 French Doc
Re: 4GB Patch
« Reply #6 on: August 01, 2020, 07:15:20 am »
Hello

Quote
does the Linux version has a memory limit too? If yes, how to allow for more RAM usage?

I don't know, but for Linux there is a 64Bits version from a while and certainly it will alow more memory that the 32bits one ... if you're using a 64 bits version of linux, of course . (32 bits = max 4 GB of addressable RAM)

(now, there is also a 64bits version for Windows too)

++
David

Offline newlinuxuser

  • Droid
  • **
  • Posts: 81
    • View Profile
Re: 4GB Patch
« Reply #7 on: August 04, 2020, 23:09:09 pm »
64 bit distro is the best solution, only if you have an old pc, not suitable for 64 bit, the 32 bit pae kernel can address more than 4 GB of memory:
https://help.ubuntu.com/community/PAE