LinuxCNC on Intel Clear Linux

More
15 Nov 2024 04:50 #314505 by rebelx
Replied by rebelx on topic LinuxCNC on Intel Clear Linux
Hi Tom, please let me know how I can send help! More coffee and pizza, or perhaps some nice beers?   I actually have quite some time available, so if you are working on specific things for which you need help, just let me know.
As for Debian, yes of course it is a big plus to have an easy install method, especially after doing system upgrades. But that was not always the case. I remember the days that upgrading under Debian could also be quite a lot of work. After LinuxCNC was added to the  mainstream Debian repositories things became much easier. And I hope that once CL has added LinuxCNC to their collection of software bundles, the same easy install and update method will apply to CL as well.
To answer you question about compiling LinuxCNC on CL: yes, I tried that, but many of the dependencies were not available on CL yet, or perhaps they were available but in places that I was not aware of. So instead of wasting more time, I followed the advice from the CL team and submitted a request to have a bundle created by them, which is comparable to having Debian adding LinuxCNC to their mainstream repositories. It should result in a single command to install and update LinuxCNC without having to build things from cratch, similar to having LinuxCNC in the Debian repositories.
But again, for me it is not about creating an alternative to Debian. It is about finding out if LinuxCNC under CL can benefit from their processor optimizations and if so (which still remains to be seen), how we may benefit from that on Debian and other distros as well.
The following user(s) said Thank You: tommylight

Please Log in or Create an account to join the conversation.

More
26 Nov 2024 01:37 - 26 Nov 2024 02:56 #315266 by NTULINUX
Replied by NTULINUX on topic LinuxCNC on Intel Clear Linux
Whelp, I just enabled -O3 and LTO in the Gentoo LinuxCNC installer/image, and bumped the CPU requirement from x86-64-v2 to x86-64-v3 (now requires AVX, AVX2, BMI1, BMI2, F16C, FMA, ABM, MOVBE and XSAVE.)

RHEL 10 requires x86-64-v3 now so this updated requirement is not radical, and x86-64-v3 goes back to 2013 for Intel (starting with Haswell) and 2015 for AMD. Let's see who's faster NOW! Muahahah!
Last edit: 26 Nov 2024 02:56 by NTULINUX. Reason: more info
The following user(s) said Thank You: tommylight

Please Log in or Create an account to join the conversation.

More
26 Nov 2024 14:32 #315299 by rebelx
Replied by rebelx on topic LinuxCNC on Intel Clear Linux
Hi NTULINUX, thank you for your efforts to make LinuxCNC faster on Gentoo. Could you share with us what performance gains you got with this, especially when it comes to latency? It may be interesting for other distros too.

Please Log in or Create an account to join the conversation.

More
27 Nov 2024 09:23 #315348 by NTULINUX
Replied by NTULINUX on topic LinuxCNC on Intel Clear Linux
I've noticed that the only difference really with latency is having a trimmed down kernel configuration with ALL of the debugging and security options disabled, but one of the things I'll be making to the kernel is using the -O3 flag as well to maximize the performance of context switching:

www.phoronix.com/review/linux-kernel-o3/5

"Out of all the benchmarks carried out, the Stress-NG context switching benchmark reported the most significant gain out of the -O3 optimized kernel build."

Context switching can impact latency so the -O3 flag to the kernel should help, and I'll be building the kernel with LTO as well.

All of this will be hosted on the `linuxcnc` branch of my Gentoo repo:

github.com/NTULINUX/gentoo_backup/tree/linuxcnc

The release will be posted here:

github.com/NTULINUX/gentoo_backup/releases

And the installer will handle all the work for you. The installer is also designed to be installed to a USB flash drive (as long as you use UEFI, for some reason legacy doesn't work off USB but it could just be my motherboard.)

Installer is here, but it's out-of-date:

github.com/NTULINUX/gentoo_backup/blob/linuxcnc/installer.sh

And here's the wiki for everything:

openlunchbox.com/mw19/index.php/HOWTO:_Gentoo_for_LinuxCNC

The installer works on Debian too but you must be running Bookworm or newer (sid or testing)

And if you're using Debian Bookworm with a PREEMPT_RT kernel but want to use a UEFI installation, you must have `efi=runtime` specified on the kernel command line, or simply use a non PREEMPT_RT kernel when running the installer.

I'll be making a few announcements once it's finished.

One more thing, Debian formats drives in really weird ways so the installer is designed to wipe out and handle partition all by itself (partition sizes are asked during the script as it is interactive) but it uses the whole disk by design, so grab a spare hard drive, NVMe or USB drive that you're happy wiping out and use that for the install. I'll be updating the wiki as well.

I'd be truly surprised if somehow Clear Linux is faster than the image I'll be pushing out the next week or so. Also, the Gentoo installer/image is free of SystemD.
The following user(s) said Thank You: tommylight, rebelx

Please Log in or Create an account to join the conversation.

More
27 Nov 2024 11:21 - 27 Nov 2024 11:22 #315358 by rebelx
Replied by rebelx on topic LinuxCNC on Intel Clear Linux
Thanks for your thorough explanation. Much appreciated! I will certainly give your build a try and I may decide to use it for the new machine that I am working on. I always love to try new things, pushing the boundaries of my comfort zone :)
As for Clear Linux, I have not seen any recent progress on their end to build a bundle for LinuxCNC. They got beyond the point where I got stuck, but it is still a work in progress. I reached out to them two weeks ago, but have not received a reply yet. I know they have a lot on their plate, so it may just be a resource and priority issue. Time will tell.....
Last edit: 27 Nov 2024 11:22 by rebelx.

Please Log in or Create an account to join the conversation.

More
27 Nov 2024 20:32 #315411 by rodw
Replied by rodw on topic LinuxCNC on Intel Clear Linux
If you read on, it does go on to say in real world conditions, they could not see an improvement. Interesting article nonetheless.
 
The following user(s) said Thank You: tommylight

Please Log in or Create an account to join the conversation.

  • tommylight
  • tommylight's Avatar
  • Away
  • Moderator
  • Moderator
More
27 Nov 2024 22:47 #315421 by tommylight
Replied by tommylight on topic LinuxCNC on Intel Clear Linux

Hi Tom, please let me know how I can send help! More coffee and pizza, or perhaps some nice beers? 

Thanks for the offer and sorry for the late reply.
If you figure out how to get more time out of a day, let me know, that is what i need most! :)
-
Rod is right, those optimizations are fairly narrow and in usual use not really impactful.
In general, by now all major distros are within several percent of each other in anything as far as speed is concerned, and so are in usability and stability, so here are some reasons why i use Mint for everything:
-fast boot time
-very stable and reliable
-even when i break something badly, it can be restored, always
-can run for months without a single issue
-Mate DE is not the most "user friendly", Gnome and KDE plasma are better for that
-Mate is not "touch" freindly, but it is better than Windoze and Gnome and KDE win here again
Why i do not like other distros:
-Debian has a nasty habit of stuff just stopping at random, mainly taskbar stuff
-Debian boot time has improved a lot, but not yet Mint times
-Tuxedo OS has issues with kernel licensing, it is very user friendly and reliable but just a bit heavier on resources, touch works out of the box, LinuxCNC needs a lot of cuddling to make work so does not pay off
-Fedora boots very slow, a bit sluggish on older hardware, quite good with touch, does not use DEB's, no LinuxCNC
-i will not use anything that does not open a terminal with CTRL+ALT+T !!!
-have not used Gentoo in ages, it was very fast and very stable, has issues with some hardware back then but mostly could be made to work.
-SlackWare was even faster than any of those, was a pain to setup but worked like a "nuclear powered battleship", no idea where it is now
-FreeBSD was similar to SlackWare and got better when PC-OS came out
-Porteus, Pupps, etc, are very good at what they do, and there is DebianDog Pup with older LinuxCNC

Please Log in or Create an account to join the conversation.

More
28 Nov 2024 03:53 - 28 Nov 2024 04:14 #315432 by rebelx
Replied by rebelx on topic LinuxCNC on Intel Clear Linux
The only way to get more time out of a day would be to slow down the rotation of the planet. I did some digging, but I could not find any useful data about what system drives the rotation, e.g. whether it is stepper or servo driven, what type of encoder is being used, etc. So I guess for now we simply have to live with roughly 24hrs/day.

I think we can all agree that there is no perfect distro, but many distros are perfectly workable. I am currently running one machine on an Orange Pi 5 with Armbian, and another machine with LMDE running KDE (which gives me the lowest latency and most responsive system), and for my new machine I will be giving NTULINUX's Gentoo a try. Both of my current machines run smooth and stable, so from that perspective there would be no reason to consider anything else, whether it is Debian, Arch, Gentoo, Clear Linux, or any other flavor. And boot time is certainly no issue for me, because the first thing I do after switching on power in my workshop is brew a fresh espresso to get the day started, and by the time I go to my machines they ready to go. If boot time would be an issue, I'd rather get better hardware than to find a faster booting OS. What triggers me most is the overall responsiveness of the system, which certainly was a nuisance with my older J1900 based machines, despite their very low latency. I still have a few of those boards laying around, but the sluggish responsiveness under Debian and LMDE prevents me from using them. I will give NTULINUX's Gentoo build a try on those older board. Perhaps they may be quite a good match. 
I guess the reason why many of us are still trying to find a better setup or improve our current system, is simply because it is fun doing so and satisfying if we can squeeze the best performance out of our hardware. After all, in a way many of us are geeks and that's what geeks do. At least I am It still remains to be seen if Clear Linux only provides a more responsive user experience compared to most other distros (which it definitely does), or if there are also optimizations under the hood that would result in lower latency numbers. It would be awesome if that would be the case, but we will know once the bundle is available.
Last edit: 28 Nov 2024 04:14 by rebelx.
The following user(s) said Thank You: tommylight

Please Log in or Create an account to join the conversation.

More
17 Jan 2025 05:54 #319156 by rebelx
Replied by rebelx on topic LinuxCNC on Intel Clear Linux
One of the developers at Clear Linux team stated the following on Github yesterday:

I did attempt to package this. The biggest issue is that the LinuxCNC team itself thinks one of the produced binaries has a license conflict between GPL2.0 and GPL3.0 when building a binary for redistribution. Since that's what we're trying to do, we're kind of stuck until/unless they fix it or decide that it's not a conflict.


Does anybody know anything about this? I have requested more details about the specific binary.

Please Log in or Create an account to join the conversation.

  • Cant do this anymore bye all
  • Cant do this anymore bye all's Avatar
  • Offline
  • Platinum Member
  • Platinum Member
More
17 Jan 2025 07:58 - 17 Jan 2025 08:22 #319162 by Cant do this anymore bye all
Replied by Cant do this anymore bye all on topic LinuxCNC on Intel Clear Linux
I think
—enable-non-distributable
switch when running configure may help.



Here's my opinion on latency.
For mesa cards epp\pci\pcie\ethernet\spi (rpi platform) or similar motion cards (seems to be a few more of these projects around now) where a base thread is not required it a little say loose, up to a certain point. I may be one of the few Luddites that still considers EPP an alternative .
It's when the Linuxcnc machine generates the step\dir signals and read encoders requiring a base thread that things get tight.
Even a i5-3470 machine from about 2012/2013 can perform fine when having to produce step\dir signals. (btw I found this machine on the side of the road, someone had put it out for "council" cleanup.)

@Tommy Slackware was my goto disrto for years, but I got a little tired of having to build missing libs and such to install a new piece of software. The last time I used Redhat was version 9, back in the days when you had to do some weird stuff to use wifi, some of which was using windows drivers, in some way or another, that's right ndiswrapper.
Last edit: 17 Jan 2025 08:22 by Cant do this anymore bye all.

Please Log in or Create an account to join the conversation.

Time to create page: 0.426 seconds
Powered by Kunena Forum