Discussion:
Preview: LinuxCNC 2.5 single codebase - supports RTAI, RT_PREEMPT, Xenomai-kernel, Xenomai-User, Simulator
Charles Steinkuehler
2012-11-02 15:29:06 UTC
Permalink
I have now integrated the RT-PREEMPT branch as provided by
Charles, added the now-working Xenomai-userland thread style, and
massaged configure to deal with all of this. The Xenomai-kernel
branch I reported about yesterday is fully integrated. If you
played with that branch, it's safe to switch.
Awesomely groovy!

I'm at this very moment trying to pull the xenomai kernel stuff to
build and test on my hardware. Should I go ahead and pull this new
branch?
./configure --with-threads=xenomai-user
./configure --with-threads=rt-preempt-user
./configure --with-threads=rtai
./configure --enable-simulator [--enable-drivers for the
hal_parport usermode driver]
...and what is it for kernel-mode xenomai?

- --
Charles Steinkuehler
charles-***@public.gmane.org
Michael Haberler
2012-11-02 15:18:42 UTC
Permalink
I have now integrated the RT-PREEMPT branch as provided by Charles, added the now-working Xenomai-userland thread style, and massaged configure to deal with all of this. The Xenomai-kernel branch I reported about yesterday is fully integrated. If you played with that branch, it's safe to switch.

this adds the following scenarios:

./configure --with-threads=xenomai-user

./configure --with-threads=rt-preempt-user

./configure --with-threads=rtai

./configure --enable-simulator [--enable-drivers for the hal_parport usermode driver]


for the RT-PREEMT flavor, please install

http://static.mah.priv.at/public/xenomai-debs/linux-headers-3.4.13-rt-preempt-rt22+_0.1_i386.deb
http://static.mah.priv.at/public/xenomai-debs/linux-image-3.4.13-rt-preempt-rt22+_0.1_i386.deb

The notes from README.xenomai wrt initrd and update-grub apply as well.

Please pull from http://git.mah.priv.at/gitweb/emc2-dev.git/shortlog/refs/heads/rtos-integration-preview1

- Michael

- The userland parport driver needs work - it cant claim the parport yet :-/ The nice part is: you can fix it with gdb.
- runtests with rt-preempt-user shows errors, but that is because stderr messages cause it to 'fail' whereas the regression output actually is ok


[so here's some drinking from the firehose for the weekend;) ]
Michael Haberler
2012-11-02 20:45:18 UTC
Permalink
to put this in perspective:

RTAI should work as always
Xenomai-kernel is pretty much identical in features and I havent found a showstopper bug yet
rt-preempt is in the state the branch was as pushed by Charles (plus maybe an original mah bug thrown in; I did some merging of data structures)
Xenomai-user is next to unusable - dont waste your time yet; I need to get this going better though since this is on the Grand Unified RT-Preempt strategy by the Xenomai folks

-m
Post by Michael Haberler
I have now integrated the RT-PREEMPT branch as provided by Charles, added the now-working Xenomai-userland thread style, and massaged configure to deal with all of this. The Xenomai-kernel branch I reported about yesterday is fully integrated. If you played with that branch, it's safe to switch.
./configure --with-threads=xenomai-user
./configure --with-threads=rt-preempt-user
./configure --with-threads=rtai
./configure --enable-simulator [--enable-drivers for the hal_parport usermode driver]
for the RT-PREEMT flavor, please install
http://static.mah.priv.at/public/xenomai-debs/linux-headers-3.4.13-rt-preempt-rt22+_0.1_i386.deb
http://static.mah.priv.at/public/xenomai-debs/linux-image-3.4.13-rt-preempt-rt22+_0.1_i386.deb
The notes from README.xenomai wrt initrd and update-grub apply as well.
Please pull from http://git.mah.priv.at/gitweb/emc2-dev.git/shortlog/refs/heads/rtos-integration-preview1
- Michael
- The userland parport driver needs work - it cant claim the parport yet :-/ The nice part is: you can fix it with gdb.
- runtests with rt-preempt-user shows errors, but that is because stderr messages cause it to 'fail' whereas the regression output actually is ok
[so here's some drinking from the firehose for the weekend;) ]
------------------------------------------------------------------------------
LogMeIn Central: Instant, anywhere, Remote PC access and management.
Stay in control, update software, and manage PCs from one command center
Diagnose problems and improve visibility into emerging IT issues
Automate, monitor and manage. Do more in less time with Central
http://p.sf.net/sfu/logmein12331_d2d
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
John Morris
2012-11-02 21:08:11 UTC
Permalink
Hi Michael,
Post by Michael Haberler
I have now integrated the RT-PREEMPT branch as provided by Charles, added the now-working Xenomai-userland thread style, and massaged configure to deal with all of this. The Xenomai-kernel branch I reported about yesterday is fully integrated. If you played with that branch, it's safe to switch.
./configure --with-threads=xenomai-user
./configure --with-threads=rt-preempt-user
./configure --with-threads=rtai
./configure --enable-simulator [--enable-drivers for the hal_parport usermode driver]
This is fantastic news for me. I originally dug up Michael Büsch's
preempt-rt patches in order to run LinuxCNC on RedHat-like distros,
where I have quite an investment in infrastructure. (Not knocking
Debian at all; I've seriously contemplated a very painful switch because
of the greater availability of these tools!) First, I thought all this
time that the preempt-rt patches were not working, but Charles has
indicated that they actually are. Now there's a second choice with your
work on Xenomai.

I'm compiling up a Xenomai-patched RPM and utilities right now, and will
report back with results.

Thank you so much. This is a major step closer to having a fully FOSS,
automated and reproducible CAD/CAM/CNC workflow.

John
John Morris
2012-11-06 17:52:00 UTC
Permalink
Post by John Morris
Hi Michael,
Post by Michael Haberler
I have now integrated the RT-PREEMPT branch as provided by Charles,
added the now-working Xenomai-userland thread style, and massaged
configure to deal with all of this. The Xenomai-kernel branch I
reported about yesterday is fully integrated. If you played with
that branch, it's safe to switch.
./configure --with-threads=xenomai-user
[...]
I'm compiling up a Xenomai-patched RPM and utilities right now, and
will report back with results.
There's a small problem when building LinuxCNC --with-xenomai-kernel
under a kernel other than the one built against. The two-liner patch
here fixes it.

It's slow going, getting all this packaged up for el6. The
kernel-xenomai and xenomai RPMs are nearly done. LinuxCNC itself needed
a few required packages to be rebuilt from fedora for el6.
Astonishingly, asciidoc, which LinuxCNC requires v. 8.5 or higher, is
still at v. 8.4.5 for even fedora rawhide, and the package hasn't been
touched since 2009.

I'm guessing there aren't any RH users here on the list, but when the
packages become available sometime this week in my public repo, I'll
post a link.

It might actually make sense someday to get an el6 version of the
rt-preempt package into EPEL, since RH ships an official rt-preempt
kernel as part of the MRG project. That will require an asciidoc86
package (latest is v. 8.6.8) in EPEL that doesn't clobber the existing
asciidoc package, with /usr/bin/{asciidoc86,a2x86}, /etc/asciidoc86,
etc. Ugh.

John
Michael Haberler
2012-11-06 18:08:09 UTC
Permalink
Post by John Morris
Hi Michael,
Post by Michael Haberler
I have now integrated the RT-PREEMPT branch as provided by Charles,
added the now-working Xenomai-userland thread style, and massaged
configure to deal with all of this. The Xenomai-kernel branch I
reported about yesterday is fully integrated. If you played with
that branch, it's safe to switch.
./configure --with-threads=xenomai-user
[...]
I'm compiling up a Xenomai-patched RPM and utilities right now, and
will report back with results.
There's a small problem when building LinuxCNC --with-xenomai-kernel under a kernel other than the one built against. The two-liner patch here fixes it.
thanks! applied, see http://git.mah.priv.at/gitweb/emc2-dev.git/shortlog/refs/heads/rtos-integration-preview1

- Michael
It's slow going, getting all this packaged up for el6. The kernel-xenomai and xenomai RPMs are nearly done. LinuxCNC itself needed a few required packages to be rebuilt from fedora for el6. Astonishingly, asciidoc, which LinuxCNC requires v. 8.5 or higher, is still at v. 8.4.5 for even fedora rawhide, and the package hasn't been touched since 2009.
I'm guessing there aren't any RH users here on the list, but when the packages become available sometime this week in my public repo, I'll post a link.
It might actually make sense someday to get an el6 version of the rt-preempt package into EPEL, since RH ships an official rt-preempt kernel as part of the MRG project. That will require an asciidoc86 package (latest is v. 8.6.8) in EPEL that doesn't clobber the existing asciidoc package, with /usr/bin/{asciidoc86,a2x86}, /etc/asciidoc86, etc. Ugh.
John
<linuxcnc-2.6.0.pre0-ksrc_fix.patch>------------------------------------------------------------------------------
LogMeIn Central: Instant, anywhere, Remote PC access and management.
Stay in control, update software, and manage PCs from one command center
Diagnose problems and improve visibility into emerging IT issues
Automate, monitor and manage. Do more in less time with Central
http://p.sf.net/sfu/logmein12331_d2d_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
John Morris
2012-11-10 07:06:58 UTC
Permalink
Hi Michael,

I've been whacking away ('hacking' is too glamorous a term for my clumsy
bumbling) at getting xenomai-kernel to work today. I did make some
progress; there's a new commit that fixes a problem where symbols in
xeno_math.ko are not being shared with other modules, resulting in
rtapi.ko not loading.

Xenomai seems to work properly. The Xenomai 'latency' and 'xeno-test'
programs look great, with <3uS/<9uS latency in kernel task and user task
modes, respectively. I followed all the guides I could find, and added
'--enable-dlopen-skins' to the user tools build, per your instructions.

The LinuxCNC latency-test, however, results in one of a few bad endings.

- Exits after writing the lines from 'Symptom 1' below into syslog; this
probably happens on the first run after a reboot.

- (One time only) a kernel oops, see 'Symptom 2' below; system kept running

- Machine hangs; CPU fan spins at max speed until system reset.

Let me know what bells these ring.

John



Symptom 1:
RTAI[math]: loaded.
HAL_LIB: ERROR: clock period too long: 1000000000000
THREADS: ERROR: could not create thread 'slow'
RTAI[math]: unloaded.

Symptom 2:
RTAI[math]: loaded.
divide error: 0000 [#1] PREEMPT SMP
last sysfs file: /sys/module/xeno_nucleus/parameters/xenomai_gid
CPU 0
Modules linked in: threads(+) hal_lib rtapi xeno_math nfs fscache
nfs_acl auth_rpcgss autofs4 lockd sunrpc ipv6 uinput ppdev parport_pc
parport sg pcspkr k8temp edac_core edac_mce_amd forcedeth i2c_nforce2
ext4 mbcache jbd2 raid1 firewire_ohci firewire_core crc_itu_t sd_mod
crc_t10dif sr_mod cdrom pata_amd pata_acpi ata_generic sata_nv radeon
ttm drm_kms_helper drm i2c_algo_bit i2c_core dm_mirror dm_region_hash
dm_log dm_mod [last unloaded: xeno_math]

Pid: 17143, comm: insmod Not tainted 2.6.38.8-2.xenomai.el6.x86_64 #1
/M61P-S3
RIP: 0010:[<ffffffffa04aad0c>] [<ffffffffa04aad0c>]
hal_create_thread+0x1fc/0x530 [hal_lib]
RSP: 0000:ffff8801c09afea8 EFLAGS: 00010256
RAX: 00000000000186a0 RBX: ffffc90004ffde58 RCX: 0000000000000000
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000063
RBP: ffff8801c09aff08 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: ffff8801c097f410
R13: 00000000000186a0 R14: 0000000000000001 R15: ffffc90004ffde80
FS: 00007f19885c1700(0000) GS:ffff8800dfc00000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f7109cc90f0 CR3: 00000001c09e2000 CR4: 00000000000006f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
Process insmod (pid: 17143, threadinfo ffff8801c09ac000, task
ffff88020e728e40)
Stack:
ffff8801c09afee8 ffffffff814b67c4 657268745f4c4148 ffffffff00736461
ffffc90004fbe000 0000000000000001 ffffffffa04bd540 ffffffffa04bd540
0000000000000000 ffffffffa04bd020 0000000001276050 0000000000000004
Call Trace:
[<ffffffff814b67c4>] ? notifier_call_chain+0x54/0x80
[<ffffffffa04bd020>] ? init_module+0x0/0x1f4 [threads]
[<ffffffffa04bd121>] init_module+0x101/0x1f4 [threads]
[<ffffffff810001e3>] do_one_initcall+0x43/0x1a0
[<ffffffff8109678a>] sys_init_module+0xba/0x200
[<ffffffff81002fff>] system_call_fastpath+0x16/0x1b
Code: 48 8b 48 08 8b 78 10 48 8b b2 98 00 00 00 49 39 f5 0f 82 61 02 00
00 48 89 f0 31 d2 48 c1 e8 3f 48 01 f0 48 d1 f8 49 8d 44 05 00 <48> f7
f6 48 98 48 0f af c6 48 39 c1 48 89 43 08 0f 8f cb 01 00
RIP [<ffffffffa04aad0c>] hal_create_thread+0x1fc/0x530 [hal_lib]
RSP <ffff8801c09afea8>
---[ end trace 3a9286738b179516 ]---
Michael Haberler
2012-11-10 07:50:11 UTC
Permalink
Hi John,
Post by John Morris
Hi Michael,
I've been whacking away ('hacking' is too glamorous a term for my clumsy
bumbling) at getting xenomai-kernel to work today. I did make some
progress; there's a new commit that fixes a problem where symbols in
xeno_math.ko are not being shared with other modules, resulting in
rtapi.ko not loading.
Xenomai seems to work properly. The Xenomai 'latency' and 'xeno-test'
programs look great, with <3uS/<9uS latency in kernel task and user task
modes, respectively. I followed all the guides I could find, and added
'--enable-dlopen-skins' to the user tools build, per your instructions.
The LinuxCNC latency-test, however, results in one of a few bad endings.
- Exits after writing the lines from 'Symptom 1' below into syslog; this
probably happens on the first run after a reboot.
- (One time only) a kernel oops, see 'Symptom 2' below; system kept running
- Machine hangs; CPU fan spins at max speed until system reset.
Let me know what bells these ring.
John
I just tried on my Atom with the 2.6.38.8-xenomai+ kernel off my repo (I had been using the 3.2.21-xenomai+ kernel so far exclusively)

I dont get your oops, or HAL_LIB error message
Post by John Morris
2.6.38.8-2.xenomai.el6.x86_64
------------------------^^^^^^^

can you push your kernel config to here: http://git.mah.priv.at/gitweb/linuxcnc-kernel.git/tree/refs/heads/linuxcnc-2.6.38.8-xenomai-x86:/linuxcnc
(in case you have the 3.2.21 x86_64 kernel built as well, your push that to the linuxcnc-2.6.38.8-xenomai-x86 branch, too?)

I'll build and try the x86_64 variants then too (good to see that's being explored, I really need to read up on what this actually means - zero clue so far)

- Michael
Post by John Morris
RTAI[math]: loaded.
HAL_LIB: ERROR: clock period too long: 1000000000000
THREADS: ERROR: could not create thread 'slow'
RTAI[math]: unloaded.
RTAI[math]: loaded.
divide error: 0000 [#1] PREEMPT SMP
last sysfs file: /sys/module/xeno_nucleus/parameters/xenomai_gid
CPU 0
Modules linked in: threads(+) hal_lib rtapi xeno_math nfs fscache
nfs_acl auth_rpcgss autofs4 lockd sunrpc ipv6 uinput ppdev parport_pc
parport sg pcspkr k8temp edac_core edac_mce_amd forcedeth i2c_nforce2
ext4 mbcache jbd2 raid1 firewire_ohci firewire_core crc_itu_t sd_mod
crc_t10dif sr_mod cdrom pata_amd pata_acpi ata_generic sata_nv radeon
ttm drm_kms_helper drm i2c_algo_bit i2c_core dm_mirror dm_region_hash
dm_log dm_mod [last unloaded: xeno_math]
Pid: 17143, comm: insmod Not tainted 2.6.38.8-2.xenomai.el6.x86_64 #1
/M61P-S3
RIP: 0010:[<ffffffffa04aad0c>] [<ffffffffa04aad0c>]
hal_create_thread+0x1fc/0x530 [hal_lib]
RSP: 0000:ffff8801c09afea8 EFLAGS: 00010256
RAX: 00000000000186a0 RBX: ffffc90004ffde58 RCX: 0000000000000000
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000063
RBP: ffff8801c09aff08 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: ffff8801c097f410
R13: 00000000000186a0 R14: 0000000000000001 R15: ffffc90004ffde80
FS: 00007f19885c1700(0000) GS:ffff8800dfc00000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f7109cc90f0 CR3: 00000001c09e2000 CR4: 00000000000006f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
Process insmod (pid: 17143, threadinfo ffff8801c09ac000, task
ffff88020e728e40)
ffff8801c09afee8 ffffffff814b67c4 657268745f4c4148 ffffffff00736461
ffffc90004fbe000 0000000000000001 ffffffffa04bd540 ffffffffa04bd540
0000000000000000 ffffffffa04bd020 0000000001276050 0000000000000004
[<ffffffff814b67c4>] ? notifier_call_chain+0x54/0x80
[<ffffffffa04bd020>] ? init_module+0x0/0x1f4 [threads]
[<ffffffffa04bd121>] init_module+0x101/0x1f4 [threads]
[<ffffffff810001e3>] do_one_initcall+0x43/0x1a0
[<ffffffff8109678a>] sys_init_module+0xba/0x200
[<ffffffff81002fff>] system_call_fastpath+0x16/0x1b
Code: 48 8b 48 08 8b 78 10 48 8b b2 98 00 00 00 49 39 f5 0f 82 61 02 00
00 48 89 f0 31 d2 48 c1 e8 3f 48 01 f0 48 d1 f8 49 8d 44 05 00 <48> f7
f6 48 98 48 0f af c6 48 39 c1 48 89 43 08 0f 8f cb 01 00
RIP [<ffffffffa04aad0c>] hal_create_thread+0x1fc/0x530 [hal_lib]
RSP <ffff8801c09afea8>
---[ end trace 3a9286738b179516 ]---
------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
http://p.sf.net/sfu/appdyn_d2d_nov
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
Michael Haberler
2012-11-10 18:30:17 UTC
Permalink
John,

the HAL_LIB error message you got and the divide error raise my gut feeling that something is wrong with in-kernel 64bit integer division on x32_64; clock periods are long long; maybe there's some inline assembly somewhere which breaks

maybe that can be verified in a standalone program?

---

I'd be interested if you can verify the below error as well

also, can you verify you have the same strange '[permanent]' tag in lsmod as me?

(post failure described below):

***@atom:~# lsmod
Module Size Used by
sampler 14143 1 [permanent]
hal_lib 39412 1 sampler,[permanent]
rtapi 46610 2 sampler,hal_lib,[permanent]
xeno_math 12602 1 rtapi,[permanent]
binfmt_misc 16829 1


-----


meanwhile I could produce an oops during module load, but different from yours (null pointer deref in-kernel), with the 32bit 2.6.38.8-xenomai+

to trigger the error:

***@atom:~/emc2-dev/tests/abs.0$ realtime start
***@atom:~/emc2-dev/tests/abs.0$ halcmd -f -k
halcmd: loadrt sampler cfg=ff depth=350
<stdin>:1: child did not exit normally
<stdin>:1: insmod failed, returned -1
See the output of 'dmesg' for more information.
halcmd:

(which is part of tests/abs.0, so runtests should cause it)

***@atom:~# dmesg
[ 252.764152] RTAI[math]: loaded.
[ 260.200891] BUG: unable to handle kernel NULL pointer dereference at (null)
[ 260.201030] IP: [<c1072256>] sys_init_module+0x2c6/0x1b80
[ 260.201132] *pde = 00000000
[ 260.201184] Oops: 0000 [#1] SMP
[ 260.201244] last sysfs file: /sys/devices/pci0000:00/0000:00:1e.0/0000:05:00.0/local_cpus
[ 260.201381] Modules linked in: sampler(+) hal_lib rtapi xeno_math binfmt_misc nfsd exportfs nfs lockd fscache nfs_acl auth_rpcgss sunrpc dm_crypt snd_hda_codec_realtek snd_hda_intel snd_hda_codec snd_hwdep snd_pcm snd_seq_midi snd_rawmidi snd_seq_midi_event snd_seq ppdev snd_timer snd_seq_device snd psmouse parport_pc serio_raw soundcore snd_page_alloc parport usbhid hid i915 drm_kms_helper drm ahci r8169 libahci i2c_algo_bit video
[ 260.202135]
[ 260.202164] Pid: 1779, comm: insmod Not tainted 2.6.38.8-xenomai+ #1 /D525MW
[ 260.202321] EIP: 0060:[<c1072256>] EFLAGS: 00010246 CPU: 0
[ 260.202415] EIP is at sys_init_module+0x2c6/0x1b80
[ 260.204015] EAX: 00000000 EBX: f90d9000 ECX: 00000000 EDX: 00000001
[ 260.204015] ESI: 00000000 EDI: 00000001 EBP: f0d9bfac ESP: f0d9bf24
[ 260.204015] DS: 007b ES: 007b FS: 00d8 GS: 0033 SS: 0068
[ 260.204015] Process insmod (pid: 1779, ti=f0d9a000 task=f0d3dee0 task.ti=f0d9a000)
[ 260.204015] I-pipe domain Linux
[ 260.204015] Stack:
[ 260.204015] 000006dc c16d39a4 00000000 c16575e6 f90d900c f13debc4 f90be460 00000004
[ 260.204015] f90d84e8 0000000b f90d9048 00000025 00000001 f0d9bf5c f90bd000 00017cc8
[ 260.204015] f90cf3c4 f90cf262 f90d4a4c f13d8180 00003000 00003040 00000000 00000000
[ 260.204015] Call Trace:
[ 260.204015] [<c1002ce1>] sysenter_do_call+0x12/0x16
[ 260.204015] Code: 00 00 8b 93 e8 00 00 00 8b b3 e0 00 00 00 89 34 24 e8 1f e3 ff ff 8b 83 80 01 00 00 85 c0 74 19 31 f6 8d 76 00 8b 83 7c 01 00 00 <ff> 14 b0 83 c6 01 3b b3 80 01 00 00 72 ec 8b 83 d4 00 00 00 85
[ 260.204015] EIP: [<c1072256>] sys_init_module+0x2c6/0x1b80 SS:ESP 0068:f0d9bf24
[ 260.204015] CR2: 0000000000000000
[ 260.366000] ---[ end trace 7dbf30905148abaa ]---
Post by John Morris
Hi Michael,
I've been whacking away ('hacking' is too glamorous a term for my clumsy
bumbling) at getting xenomai-kernel to work today. I did make some
progress; there's a new commit that fixes a problem where symbols in
xeno_math.ko are not being shared with other modules, resulting in
rtapi.ko not loading.
Xenomai seems to work properly. The Xenomai 'latency' and 'xeno-test'
programs look great, with <3uS/<9uS latency in kernel task and user task
modes, respectively. I followed all the guides I could find, and added
'--enable-dlopen-skins' to the user tools build, per your instructions.
The LinuxCNC latency-test, however, results in one of a few bad endings.
- Exits after writing the lines from 'Symptom 1' below into syslog; this
probably happens on the first run after a reboot.
- (One time only) a kernel oops, see 'Symptom 2' below; system kept running
- Machine hangs; CPU fan spins at max speed until system reset.
Let me know what bells these ring.
John
RTAI[math]: loaded.
HAL_LIB: ERROR: clock period too long: 1000000000000
THREADS: ERROR: could not create thread 'slow'
RTAI[math]: unloaded.
RTAI[math]: loaded.
divide error: 0000 [#1] PREEMPT SMP
last sysfs file: /sys/module/xeno_nucleus/parameters/xenomai_gid
CPU 0
Modules linked in: threads(+) hal_lib rtapi xeno_math nfs fscache
nfs_acl auth_rpcgss autofs4 lockd sunrpc ipv6 uinput ppdev parport_pc
parport sg pcspkr k8temp edac_core edac_mce_amd forcedeth i2c_nforce2
ext4 mbcache jbd2 raid1 firewire_ohci firewire_core crc_itu_t sd_mod
crc_t10dif sr_mod cdrom pata_amd pata_acpi ata_generic sata_nv radeon
ttm drm_kms_helper drm i2c_algo_bit i2c_core dm_mirror dm_region_hash
dm_log dm_mod [last unloaded: xeno_math]
Pid: 17143, comm: insmod Not tainted 2.6.38.8-2.xenomai.el6.x86_64 #1
/M61P-S3
RIP: 0010:[<ffffffffa04aad0c>] [<ffffffffa04aad0c>]
hal_create_thread+0x1fc/0x530 [hal_lib]
RSP: 0000:ffff8801c09afea8 EFLAGS: 00010256
RAX: 00000000000186a0 RBX: ffffc90004ffde58 RCX: 0000000000000000
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000063
RBP: ffff8801c09aff08 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: ffff8801c097f410
R13: 00000000000186a0 R14: 0000000000000001 R15: ffffc90004ffde80
FS: 00007f19885c1700(0000) GS:ffff8800dfc00000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f7109cc90f0 CR3: 00000001c09e2000 CR4: 00000000000006f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
Process insmod (pid: 17143, threadinfo ffff8801c09ac000, task
ffff88020e728e40)
ffff8801c09afee8 ffffffff814b67c4 657268745f4c4148 ffffffff00736461
ffffc90004fbe000 0000000000000001 ffffffffa04bd540 ffffffffa04bd540
0000000000000000 ffffffffa04bd020 0000000001276050 0000000000000004
[<ffffffff814b67c4>] ? notifier_call_chain+0x54/0x80
[<ffffffffa04bd020>] ? init_module+0x0/0x1f4 [threads]
[<ffffffffa04bd121>] init_module+0x101/0x1f4 [threads]
[<ffffffff810001e3>] do_one_initcall+0x43/0x1a0
[<ffffffff8109678a>] sys_init_module+0xba/0x200
[<ffffffff81002fff>] system_call_fastpath+0x16/0x1b
Code: 48 8b 48 08 8b 78 10 48 8b b2 98 00 00 00 49 39 f5 0f 82 61 02 00
00 48 89 f0 31 d2 48 c1 e8 3f 48 01 f0 48 d1 f8 49 8d 44 05 00 <48> f7
f6 48 98 48 0f af c6 48 39 c1 48 89 43 08 0f 8f cb 01 00
RIP [<ffffffffa04aad0c>] hal_create_thread+0x1fc/0x530 [hal_lib]
RSP <ffff8801c09afea8>
---[ end trace 3a9286738b179516 ]---
------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
http://p.sf.net/sfu/appdyn_d2d_nov
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
John Morris
2012-11-13 05:27:46 UTC
Permalink
Hi Michael,

Now that the got my more basic gremlins are worked out, I find the i686
box in the shop also freezes with the latency-test, so clearly the
problem is with my setup and not a 32-bit vs. 64-bit issue.

I don't see the [permanent] flag set when loading the rtapi modules.

I'm going back to try to recreate your setup. Found your kernel config
file. If you have one around, please send a LinuxCNC build log to help
guess what the differences might be.

John
Post by Michael Haberler
John,
the HAL_LIB error message you got and the divide error raise my gut
feeling that something is wrong with in-kernel 64bit integer division on
x32_64; clock periods are long long; maybe there's some inline assembly
somewhere which breaks
maybe that can be verified in a standalone program?
---
I'd be interested if you can verify the below error as well
also, can you verify you have the same strange '[permanent]' tag in lsmod as me?
Module Size Used by
sampler 14143 1 [permanent]
hal_lib 39412 1 sampler,[permanent]
rtapi 46610 2 sampler,hal_lib,[permanent]
xeno_math 12602 1 rtapi,[permanent]
binfmt_misc 16829 1
-----
meanwhile I could produce an oops during module load, but different
from yours (null pointer deref in-kernel), with the 32bit
2.6.38.8-xenomai+
halcmd: loadrt sampler cfg=ff depth=350
<stdin>:1: child did not exit normally
<stdin>:1: insmod failed, returned -1
See the output of 'dmesg' for more information.
(which is part of tests/abs.0, so runtests should cause it)
[ 252.764152] RTAI[math]: loaded.
[ 260.200891] BUG: unable to handle kernel NULL pointer dereference at (null)
[ 260.201030] IP: [<c1072256>] sys_init_module+0x2c6/0x1b80
[ 260.201132] *pde = 00000000
[ 260.201184] Oops: 0000 [#1] SMP
[ 260.201244] last sysfs file: /sys/devices/pci0000:00/0000:00:1e.0/0000:05:00.0/local_cpus
[ 260.201381] Modules linked in: sampler(+) hal_lib rtapi xeno_math binfmt_misc nfsd exportfs nfs lockd fscache nfs_acl auth_rpcgss sunrpc dm_crypt snd_hda_codec_realtek snd_hda_intel snd_hda_codec snd_hwdep snd_pcm snd_seq_midi snd_rawmidi snd_seq_midi_event snd_seq ppdev snd_timer snd_seq_device snd psmouse parport_pc serio_raw soundcore snd_page_alloc parport usbhid hid i915 drm_kms_helper drm ahci r8169 libahci i2c_algo_bit video
[ 260.202135]
[ 260.202164] Pid: 1779, comm: insmod Not tainted 2.6.38.8-xenomai+ #1 /D525MW
[ 260.202321] EIP: 0060:[<c1072256>] EFLAGS: 00010246 CPU: 0
[ 260.202415] EIP is at sys_init_module+0x2c6/0x1b80
[ 260.204015] EAX: 00000000 EBX: f90d9000 ECX: 00000000 EDX: 00000001
[ 260.204015] ESI: 00000000 EDI: 00000001 EBP: f0d9bfac ESP: f0d9bf24
[ 260.204015] DS: 007b ES: 007b FS: 00d8 GS: 0033 SS: 0068
[ 260.204015] Process insmod (pid: 1779, ti=f0d9a000 task=f0d3dee0 task.ti=f0d9a000)
[ 260.204015] I-pipe domain Linux
[ 260.204015] 000006dc c16d39a4 00000000 c16575e6 f90d900c f13debc4 f90be460 00000004
[ 260.204015] f90d84e8 0000000b f90d9048 00000025 00000001 f0d9bf5c f90bd000 00017cc8
[ 260.204015] f90cf3c4 f90cf262 f90d4a4c f13d8180 00003000 00003040 00000000 00000000
[ 260.204015] [<c1002ce1>] sysenter_do_call+0x12/0x16
[ 260.204015] Code: 00 00 8b 93 e8 00 00 00 8b b3 e0 00 00 00 89 34 24 e8 1f e3 ff ff 8b 83 80 01 00 00 85 c0 74 19 31 f6 8d 76 00 8b 83 7c 01 00 00 <ff> 14 b0 83 c6 01 3b b3 80 01 00 00 72 ec 8b 83 d4 00 00 00 85
[ 260.204015] EIP: [<c1072256>] sys_init_module+0x2c6/0x1b80 SS:ESP 0068:f0d9bf24
[ 260.204015] CR2: 0000000000000000
[ 260.366000] ---[ end trace 7dbf30905148abaa ]---
Post by John Morris
Hi Michael,
I've been whacking away ('hacking' is too glamorous a term for my clumsy
bumbling) at getting xenomai-kernel to work today. I did make some
progress; there's a new commit that fixes a problem where symbols in
xeno_math.ko are not being shared with other modules, resulting in
rtapi.ko not loading.
Xenomai seems to work properly. The Xenomai 'latency' and 'xeno-test'
programs look great, with <3uS/<9uS latency in kernel task and user task
modes, respectively. I followed all the guides I could find, and added
'--enable-dlopen-skins' to the user tools build, per your instructions.
The LinuxCNC latency-test, however, results in one of a few bad endings.
- Exits after writing the lines from 'Symptom 1' below into syslog; this
probably happens on the first run after a reboot.
- (One time only) a kernel oops, see 'Symptom 2' below; system kept running
- Machine hangs; CPU fan spins at max speed until system reset.
Let me know what bells these ring.
John
RTAI[math]: loaded.
HAL_LIB: ERROR: clock period too long: 1000000000000
THREADS: ERROR: could not create thread 'slow'
RTAI[math]: unloaded.
RTAI[math]: loaded.
divide error: 0000 [#1] PREEMPT SMP
last sysfs file: /sys/module/xeno_nucleus/parameters/xenomai_gid
CPU 0
Modules linked in: threads(+) hal_lib rtapi xeno_math nfs fscache
nfs_acl auth_rpcgss autofs4 lockd sunrpc ipv6 uinput ppdev parport_pc
parport sg pcspkr k8temp edac_core edac_mce_amd forcedeth i2c_nforce2
ext4 mbcache jbd2 raid1 firewire_ohci firewire_core crc_itu_t sd_mod
crc_t10dif sr_mod cdrom pata_amd pata_acpi ata_generic sata_nv radeon
ttm drm_kms_helper drm i2c_algo_bit i2c_core dm_mirror dm_region_hash
dm_log dm_mod [last unloaded: xeno_math]
Pid: 17143, comm: insmod Not tainted 2.6.38.8-2.xenomai.el6.x86_64 #1
/M61P-S3
RIP: 0010:[<ffffffffa04aad0c>] [<ffffffffa04aad0c>]
hal_create_thread+0x1fc/0x530 [hal_lib]
RSP: 0000:ffff8801c09afea8 EFLAGS: 00010256
RAX: 00000000000186a0 RBX: ffffc90004ffde58 RCX: 0000000000000000
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000063
RBP: ffff8801c09aff08 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: ffff8801c097f410
R13: 00000000000186a0 R14: 0000000000000001 R15: ffffc90004ffde80
FS: 00007f19885c1700(0000) GS:ffff8800dfc00000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f7109cc90f0 CR3: 00000001c09e2000 CR4: 00000000000006f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
Process insmod (pid: 17143, threadinfo ffff8801c09ac000, task
ffff88020e728e40)
ffff8801c09afee8 ffffffff814b67c4 657268745f4c4148 ffffffff00736461
ffffc90004fbe000 0000000000000001 ffffffffa04bd540 ffffffffa04bd540
0000000000000000 ffffffffa04bd020 0000000001276050 0000000000000004
[<ffffffff814b67c4>] ? notifier_call_chain+0x54/0x80
[<ffffffffa04bd020>] ? init_module+0x0/0x1f4 [threads]
[<ffffffffa04bd121>] init_module+0x101/0x1f4 [threads]
[<ffffffff810001e3>] do_one_initcall+0x43/0x1a0
[<ffffffff8109678a>] sys_init_module+0xba/0x200
[<ffffffff81002fff>] system_call_fastpath+0x16/0x1b
Code: 48 8b 48 08 8b 78 10 48 8b b2 98 00 00 00 49 39 f5 0f 82 61 02 00
00 48 89 f0 31 d2 48 c1 e8 3f 48 01 f0 48 d1 f8 49 8d 44 05 00 <48> f7
f6 48 98 48 0f af c6 48 39 c1 48 89 43 08 0f 8f cb 01 00
RIP [<ffffffffa04aad0c>] hal_create_thread+0x1fc/0x530 [hal_lib]
RSP <ffff8801c09afea8>
---[ end trace 3a9286738b179516 ]---
------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
http://p.sf.net/sfu/appdyn_d2d_nov
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
http://p.sf.net/sfu/appdyn_d2d_nov
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
John Morris
2012-11-14 07:19:22 UTC
Permalink
Post by John Morris
I'm going back to try to recreate your setup. Found your kernel config
file. If you have one around, please send a LinuxCNC build log to help
guess what the differences might be.
While sitting around waiting for the umpteenth time for the Xenomai
kernel to build, this time with Michael's config just to help narrow
things down, I compiled up LinuxCNC xenomai-user.

Latency-test works. And on the same kernel that, combined with
xenomai-kernel, hangs! 64-bit uniprocessor running several glxgears
(why's that the test we always use?), loading up Firefox with a buggy
load of saved tabs, compiling that same xenomai kernel and spinning
shapes around in FreeCAD, latency-test reported 7ms/6ms jitter.

Also, Michael told me today that xenomai-user will also compile for
Raspberry Pi, one of which my friend dropped in my lap a few weeks ago
and which I had no idea what to do with until now.

Woo hoo! What a wonderful turn of events after a crummy week.

John
Michael Haberler
2012-11-14 09:35:57 UTC
Permalink
Post by John Morris
Post by John Morris
I'm going back to try to recreate your setup. Found your kernel config
file. If you have one around, please send a LinuxCNC build log to help
guess what the differences might be.
While sitting around waiting for the umpteenth time for the Xenomai
kernel to build, this time with Michael's config just to help narrow
things down, I compiled up LinuxCNC xenomai-user.
Latency-test works. And on the same kernel that, combined with
xenomai-kernel, hangs! 64-bit uniprocessor running several glxgears
(why's that the test we always use?), loading up Firefox with a buggy
load of saved tabs, compiling that same xenomai kernel and spinning
shapes around in FreeCAD, latency-test reported 7ms/6ms jitter.
That result both Kent and me are puzzled about.. conventional wisdom would imply 'kernel threads might have lower latency'.

The really hard question for the future (LinuxCNC3) is: does it make sense to support kernel threads builds at all? if the above results turn out to be reproducible, the answer to this might be 'sorry, to gain exactly _what_?' which opens a wide range of options to simplify things in LinuxCNC3
Post by John Morris
Also, Michael told me today that xenomai-user will also compile for
Raspberry Pi, one of which my friend dropped in my lap a few weeks ago
and which I had no idea what to do with until now.
note operative word 'compile':

I didnt get the GUI's to run because of some Python OpenGL support missing, this could be me or support for OpenGL on the Pi; likely me. runtests is ok.

what does work nicely is HAL+RTAPI; also I cooked up a primitive Pi GPIO driver (src/hal/drivers/hal_gpio) which wiggles pins just fine. Now if only motion had a sane message interface we already would have a working 'RT outboard' by now.

With xenomai as RT base, the range of architectures is in fact wide open:

http://www.xenomai.org/index.php/Embedded_Device_Support

the architecture dependent code in src/rtapi/rtapi_bitops.h can nowadays be handled by GCC builtin atomic operations which obviates the need for assembly, this is enabled by --enable-gcc-atomic-ops and forced by --with-platform=raspberry . That should in fact compile on any washer & dryer supported by gcc.

I need to write up the status, and the pre-merge laundry list.

The viability of PCI I/O in userthreads builds is still pending verification. The upside of doing this: debugging RT code with gdb like any other user program simplifies things drastically.

- Michael
Post by John Morris
Woo hoo! What a wonderful turn of events after a crummy week.
John
------------------------------------------------------------------------------
Monitor your physical, virtual and cloud infrastructure from a single
web console. Get in-depth insight into apps, servers, databases, vmware,
SAP, cloud infrastructure, etc. Download 30-day Free Trial.
Pricing starts from $795 for 25 servers or applications!
http://p.sf.net/sfu/zoho_dev2dev_nov
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
andy pugh
2012-11-14 13:00:13 UTC
Permalink
Post by Michael Haberler
I didnt get the GUI's to run because of some Python OpenGL support missing
Any luck with mini, or tklinuxcnc, or even (desperation) keystick?
--
atp
If you can't fix it, you don't own it.
http://www.ifixit.com/Manifesto
John Morris
2012-11-14 17:33:10 UTC
Permalink
Post by andy pugh
Post by Michael Haberler
I didnt get the GUI's to run because of some Python OpenGL support missing
Any luck with mini, or tklinuxcnc, or even (desperation) keystick?
What are you shooting for, Andy? This link has come up before, an
example of a GUI that won't require OpenGL:

http://code.google.com/p/miniemc2/

Jonh
Michael Haberler
2012-11-15 07:00:35 UTC
Permalink
Post by andy pugh
Post by Michael Haberler
I didnt get the GUI's to run because of some Python OpenGL support missing
Any luck with mini, or tklinuxcnc, or even (desperation) keystick?
let me clarify what I'm doing:

I'm trying to get HAL/RTAPI to run on other architectures than PC/x86 and get the build support in place, and the raspberry is a cheap ARM platform I can exercise this build support on

my goal is to enable a 'realtime outboard' which eventually runs HAL,RTAPI, maybe motion and which LinuxCNC can talk to with a messaging interface

a non-goal for me is LinuxCNC-as-is as a package for the Raspberry - if somebody else sends in patches and the result makes any sense: great

it is just not on my list so don't hope on anything coming from me in this direction

- Michael
Post by andy pugh
--
atp
If you can't fix it, you don't own it.
http://www.ifixit.com/Manifesto
------------------------------------------------------------------------------
Monitor your physical, virtual and cloud infrastructure from a single
web console. Get in-depth insight into apps, servers, databases, vmware,
SAP, cloud infrastructure, etc. Download 30-day Free Trial.
Pricing starts from $795 for 25 servers or applications!
http://p.sf.net/sfu/zoho_dev2dev_nov
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
Kent A. Reed
2012-11-14 17:57:17 UTC
Permalink
Post by John Morris
While sitting around waiting for the umpteenth time for the Xenomai
kernel to build, this time with Michael's config just to help narrow
things down, I compiled up LinuxCNC xenomai-user.
Latency-test works. And on the same kernel that, combined with
xenomai-kernel, hangs! 64-bit uniprocessor running several glxgears
(why's that the test we always use?), loading up Firefox with a buggy
load of saved tabs, compiling that same xenomai kernel and spinning
shapes around in FreeCAD, latency-test reported 7ms/6ms jitter.
Sorry, John, I lost the bubble. What CPU/motherboard/etc was this?

As for the silly glxgears test, I think the original intent was to use
it as a quick exercise of the X/OpenGL/driver path and perhaps as a
benchmark of the graphics performance if the path works (although
graphics guys are quick to tell us it isn't a benchmark).

For latency testing purposes, it might help smoke out problems with the
graphics subsystem---some drivers and some chips grab hold of DMA for
example.

Obviously, we've not thought our way through anything resembling a
proper test suite.

Regards,
Kent
John Morris
2012-11-14 18:34:06 UTC
Permalink
Hi Kent,
Post by Kent A. Reed
Post by John Morris
While sitting around waiting for the umpteenth time for the Xenomai
kernel to build, this time with Michael's config just to help narrow
things down, I compiled up LinuxCNC xenomai-user.
Latency-test works. And on the same kernel that, combined with
xenomai-kernel, hangs! 64-bit uniprocessor running several glxgears
(why's that the test we always use?), loading up Firefox with a buggy
load of saved tabs, compiling that same xenomai kernel and spinning
shapes around in FreeCAD, latency-test reported 7ms/6ms jitter.
Sorry, John, I lost the bubble. What CPU/motherboard/etc was this?
This is an old Gigabyte GA-M61P-S3 rev. 1.0:

http://www.gigabyte.com/products/product-page.aspx?pid=2434#sp

- NVidia GeForce 6100 chipset
- A suspicious 'model unknown' AMD Athlon 64-bit single core 2.2GHz
1MB cache I got super cheap in Beijing 2007
- 8GB DDR2 RAM, I believe 800MHz
- ATI Radeon X1300 Pro video card running two monitors
Post by Kent A. Reed
As for the silly glxgears test, I think the original intent was to use
it as a quick exercise of the X/OpenGL/driver path and perhaps as a
benchmark of the graphics performance if the path works (although
graphics guys are quick to tell us it isn't a benchmark).
For latency testing purposes, it might help smoke out problems with the
graphics subsystem---some drivers and some chips grab hold of DMA for
example.
Obviously, we've not thought our way through anything resembling a
proper test suite.
At least a 'standardized' load generator would help, something that
would be easy for us to run, that would run the same types of loads,
collect the same performance stats while running, and collect system
hardware and software information. Better would be if the results could
be uploaded to a common database. This would get us closer to an
objective set of tests, and with a database, would enable analysis to
help identify e.g. problem chipsets, problem VGA cards, etc.

I've done some of this stuff in the past and could do it again, but this
would be quite a bit harder since I don't control the machines under
test, which could be running any version of any distro with any sort of
customization, and concurrently doing who knows what else at the same time.

John
John Morris
2012-11-14 21:16:56 UTC
Permalink
Hi Kent,
Post by John Morris
- NVidia GeForce 6100 chipset
- A suspicious 'model unknown' AMD Athlon 64-bit single core 2.2GHz
1MB cache I got super cheap in Beijing 2007
- 8GB DDR2 RAM, I believe 800MHz
- ATI Radeon X1300 Pro video card running two monitors
Then did you really mean "ms" as in milliseconds? 7ms/6ms is 3
orders of magnitude greater than the jitter I'm seeing on my Athlon
II X64 640 and I have a hard time believing the different cpus are
1000x different in performance.
Ha, Andy caught me before using the wrong units several months back, but
I seem to have let down my guard again. Yes, 7us/6us.

John
Post by John Morris
At least a 'standardized' load generator would help, something
that would be easy for us to run, that would run the same types of
loads, collect the same performance stats while running, and
collect system hardware and software information. Better would be
if the results could be uploaded to a common database. This would
get us closer to an objective set of tests, and with a database,
would enable analysis to help identify e.g. problem chipsets,
problem VGA cards, etc.
Amen to that.
Regards,
Kent
EBo
2012-11-14 21:19:42 UTC
Permalink
Post by John Morris
Hi Kent,
Post by John Morris
- NVidia GeForce 6100 chipset
- A suspicious 'model unknown' AMD Athlon 64-bit single core
2.2GHz
Post by John Morris
1MB cache I got super cheap in Beijing 2007
- 8GB DDR2 RAM, I believe 800MHz
- ATI Radeon X1300 Pro video card running two monitors
Then did you really mean "ms" as in milliseconds? 7ms/6ms is 3
orders of magnitude greater than the jitter I'm seeing on my Athlon
II X64 640 and I have a hard time believing the different cpus are
1000x different in performance.
Ha, Andy caught me before using the wrong units several months back, but
I seem to have let down my guard again. Yes, 7us/6us.
I was wondering about that. Thanks for the clarification. 7us/6us
seems really good to me.

EBo --
John Morris
2012-11-14 22:18:58 UTC
Permalink
Post by EBo
Post by John Morris
Hi Kent,
Post by John Morris
- NVidia GeForce 6100 chipset
- A suspicious 'model unknown' AMD Athlon 64-bit single core
2.2GHz
Post by John Morris
1MB cache I got super cheap in Beijing 2007
- 8GB DDR2 RAM, I believe 800MHz
- ATI Radeon X1300 Pro video card running two monitors
Then did you really mean "ms" as in milliseconds? 7ms/6ms is 3
orders of magnitude greater than the jitter I'm seeing on my Athlon
II X64 640 and I have a hard time believing the different cpus are
1000x different in performance.
Ha, Andy caught me before using the wrong units several months back, but
I seem to have let down my guard again. Yes, 7us/6us.
I was wondering about that. Thanks for the clarification. 7us/6us
seems really good to me.
Just tested on the i686 in the shop, where the numbers looked pretty
bad. The base numbers looked like 13us/10us, but spikes quickly brought
those up to 100-200us. There's still tuning to be done, such as turning
the SMI workaround kernel options on.

As I keep saying, my goal is to lower the barrier to entry for novice
users. I predict that a big challenge in making LinuxCNC more
accessible will be inability to provide a single kernel image that works
for everyone. The SMI workarounds are an example: these should not be
turned on for all machines, but on ones with jitter spikes but no
SMI-related risk of overheating, these should be turned on. Maybe this
will change in the future if a run-time switch is implemented, but for
now it's a problem.

John
Kent A. Reed
2012-11-14 23:03:11 UTC
Permalink
Post by John Morris
Just tested on the i686 in the shop, where the numbers looked pretty
bad. The base numbers looked like 13us/10us, but spikes quickly brought
those up to 100-200us. There's still tuning to be done, such as turning
the SMI workaround kernel options on.
As I keep saying, my goal is to lower the barrier to entry for novice
users. I predict that a big challenge in making LinuxCNC more
accessible will be inability to provide a single kernel image that works
for everyone. The SMI workarounds are an example: these should not be
turned on for all machines, but on ones with jitter spikes but no
SMI-related risk of overheating, these should be turned on. Maybe this
will change in the future if a run-time switch is implemented, but for
now it's a problem.
For grins, I jwent to test the xenomai-user configuration on an old P4
machine, from which I've obtained sub-20us max jitter values with past
releases of LinuxCNC. Wouldn't you know it, the xenomai kernel borks my
Xserver on this machine. I hate it when that happens. I'm sure I'll get
it sorted but try explaining it to a Newbie.

I'm hoping ARM-based boards and Michael's work with xenomai-user threads
will give us a more stable platform.

I'm fearing, of course, that this may be a victory we have to fight for
over and over again, what with the constant flux in ARM offerings,
notably in the way IP cores are mixed and matched in physical devices. I
almost responded to Eric Johnson's message about the new, low-cost,
linux-capable ARM board that these things remind me of the old saying
about buses. If you don't like one, just wait. Another will come along
in a few minutes. The kicker is, if you do like one, you better hope it
doesn't pull away soon. Just look at the rapid evolution in the Intel Atom.

Regards,
Kent
Peter C. Wallace
2012-11-14 23:10:26 UTC
Permalink
Date: Wed, 14 Nov 2012 18:03:11 -0500
Subject: Re: [Emc-developers] Preview: LinuxCNC 2.5 single codebase - supports
RTAI, RT_PREEMPT, Xenomai-kernel, Xenomai-User, Simulator
Post by John Morris
Just tested on the i686 in the shop, where the numbers looked pretty
bad. The base numbers looked like 13us/10us, but spikes quickly brought
those up to 100-200us. There's still tuning to be done, such as turning
the SMI workaround kernel options on.
As I keep saying, my goal is to lower the barrier to entry for novice
users. I predict that a big challenge in making LinuxCNC more
accessible will be inability to provide a single kernel image that works
for everyone. The SMI workarounds are an example: these should not be
turned on for all machines, but on ones with jitter spikes but no
SMI-related risk of overheating, these should be turned on. Maybe this
will change in the future if a run-time switch is implemented, but for
now it's a problem.
For grins, I jwent to test the xenomai-user configuration on an old P4
machine, from which I've obtained sub-20us max jitter values with past
releases of LinuxCNC. Wouldn't you know it, the xenomai kernel borks my
Xserver on this machine. I hate it when that happens. I'm sure I'll get
it sorted but try explaining it to a Newbie.
I'm hoping ARM-based boards and Michael's work with xenomai-user threads
will give us a more stable platform.
I'm fearing, of course, that this may be a victory we have to fight for
over and over again, what with the constant flux in ARM offerings,
notably in the way IP cores are mixed and matched in physical devices. I
almost responded to Eric Johnson's message about the new, low-cost,
linux-capable ARM board that these things remind me of the old saying
about buses. If you don't like one, just wait. Another will come along
in a few minutes. The kicker is, if you do like one, you better hope it
doesn't pull away soon. Just look at the rapid evolution in the Intel Atom.
Regards,
Kent
I think that is an issue with ARM CPUs because unlike a PC, theres no
'platform' standard at all other than maybe a cell phone/tablet with a 6 month
platform lifetime.

A good thing about the Atom is that Intel seems to have learned their lesson
with the PowerVR video fiasco so the next Atoms will have Intel video again.


Peter Wallace
Mesa Electronics
Eric Keller
2012-11-14 19:59:56 UTC
Permalink
Post by Kent A. Reed
As for the silly glxgears test, I think the original intent was to use
it as a quick exercise of the X/OpenGL/driver path and perhaps as a
benchmark of the graphics performance if the path works (although
graphics guys are quick to tell us it isn't a benchmark).
For latency testing purposes, it might help smoke out problems with the
graphics subsystem---some drivers and some chips grab hold of DMA for
example.
glxgears can slow down the computer, but I've never really seen it blow up
the latency numbers much. The worst latency I got on the last computer I
stress tested was starting a Java program off of the cd drive.
Historically, the worst latency problems on the PC architecture were from
disk accesses. All the other problems are really driver related as far as
I can tell
Eric
Kent A. Reed
2012-11-14 21:23:50 UTC
Permalink
Post by Eric Keller
Post by Kent A. Reed
As for the silly glxgears test, I think the original intent was to use
it as a quick exercise of the X/OpenGL/driver path and perhaps as a
benchmark of the graphics performance if the path works (although
graphics guys are quick to tell us it isn't a benchmark).
For latency testing purposes, it might help smoke out problems with the
graphics subsystem---some drivers and some chips grab hold of DMA for
example.
glxgears can slow down the computer, but I've never really seen it blow up
the latency numbers much....
I have seen it cause a blow up but not recently. When it did, typically
web browsing did too because the browser also exercises the graphics
subsystem hard.

Trouble is, good or bad behavior depends on the specific circumstances,
so we're forced to run everything when we exercise a new system. That's
really all the latency-test instructions say: try everything you can
think of to see if you can get to the worst-case numbers and here's a
list of things we've had trouble with in the past---glxgears, videos,
web surfing (which implies network access), directory listings, etc.
Post by Eric Keller
... The worst latency I got on the last computer I
stress tested was starting a Java program off of the cd drive.
Historically, the worst latency problems on the PC architecture were from
disk accesses. All the other problems are really driver related as far as
I can tell
I've had more problems with various USB devices (and not only USB
mass-storage devices) than with internal disks. Again, the details of
board/bios, cpu, drivers, specific device, whether or not legacy USB
support is enabled, plugging the device in before or after booting,
etc., mattered.

Unfortunately, saying the problems are driver-related only identifies
the source of the problem, it doesn't resolve the problem. There's still
vendor-proprietary magic which we can't change in drivers for many
graphics subsystems; even with open-source hardware drivers we face the
problem that changes get made in them whenever a developer gets a wild
hair. Sometimes the changes are pure improvement; more often the changes
are a mixed blessing.

And, yes, I do always expect my bread to fall jelly-side down on the
floor:-)

Regards,
Kent
John Kasunich
2012-11-06 19:06:32 UTC
Permalink
Post by John Morris
Astonishingly, asciidoc, which LinuxCNC requires v. 8.5 or higher, is
still at v. 8.4.5 for even fedora rawhide, and the package hasn't been
touched since 2009.
I am completely out of the loop on this, but anytime I see "requires
version X.X or higher", I always wonder if the project really uses some
feature or bugfix that only exists in that version? Or is it simply a
case
of "that is what was on the initial developer's system" ?

Do we know for a fact that asciidoc 8.4.whatever won't build the
LinuxCNC documents, or is that simply what happens to be
included with Ubuntu?

John Kasunich
(not a fan of rapid obsolence)
Michael Haberler
2012-11-06 19:26:07 UTC
Permalink
Post by John Kasunich
Post by John Morris
Astonishingly, asciidoc, which LinuxCNC requires v. 8.5 or higher, is
still at v. 8.4.5 for even fedora rawhide, and the package hasn't been
touched since 2009.
I am completely out of the loop on this, but anytime I see "requires
version X.X or higher", I always wonder if the project really uses some
feature or bugfix that only exists in that version? Or is it simply a
case
of "that is what was on the initial developer's system" ?
Do we know for a fact that asciidoc 8.4.whatever won't build the
LinuxCNC documents, or is that simply what happens to be
included with Ubuntu?
we know, it was a terrible PITA just to get it to run on the lucid-supplied asciidoc, which is 8.5.2

there are several version-specific macros needed, and also options in the .txt files proper just to cater with the issues in 8.5.2

-m
Post by John Kasunich
John Kasunich
(not a fan of rapid obsolence)
------------------------------------------------------------------------------
LogMeIn Central: Instant, anywhere, Remote PC access and management.
Stay in control, update software, and manage PCs from one command center
Diagnose problems and improve visibility into emerging IT issues
Automate, monitor and manage. Do more in less time with Central
http://p.sf.net/sfu/logmein12331_d2d
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
John Morris
2012-11-06 20:42:54 UTC
Permalink
Hi John,
Post by John Kasunich
Post by John Morris
Astonishingly, asciidoc, which LinuxCNC requires v. 8.5 or higher, is
still at v. 8.4.5 for even fedora rawhide, and the package hasn't been
touched since 2009.
I am completely out of the loop on this, but anytime I see "requires
version X.X or higher", I always wonder if the project really uses some
feature or bugfix that only exists in that version? Or is it simply a
case
of "that is what was on the initial developer's system" ?
Do we know for a fact that asciidoc 8.4.whatever won't build the
LinuxCNC documents, or is that simply what happens to be
included with Ubuntu?
I'm like you, and the first thing I tried was building with asciidoc
8.4.5, which bombed out with an error. Replacing it with 8.6.8 fixed
it, so in this case, LinuxCNC does appear to need whatever feature that
is that's missing.

I considered going in to see whether the docs could be fixed, since that
could possibly be easier than creating the previously-mentioned
asciidoc86 package, but decided that won't a priority unless we do
finally have something suitable for putting through the fedora packaging
process. (I actually learned something recently when someone linked to
the definition of YAGNI, or I'd probably be working on it right now. ;)

John
Kent A. Reed
2012-11-02 21:53:56 UTC
Permalink
Post by Michael Haberler
I have now integrated the RT-PREEMPT branch as provided by Charles, added the now-working Xenomai-userland thread style, and massaged configure to deal with all of this. The Xenomai-kernel branch I reported about yesterday is fully integrated. If you played with that branch, it's safe to switch.
./configure --with-threads=xenomai-user
./configure --with-threads=rt-preempt-user
./configure --with-threads=rtai
./configure --enable-simulator [--enable-drivers for the hal_parport usermode driver]
Are the machinations in debian/configure not relevant?
Post by Michael Haberler
<...>
Please pull from http://git.mah.priv.at/gitweb/emc2-dev.git/shortlog/refs/heads/rtos-integration-preview1
I'm feeling especially old and crusty today. Not being a git Master (in
the sense of being master of all I survey) and failing in my several
tries to "pull from ...", I used my father's time-honored advice "don't
force it; get a bigger hammer", in this case, by creating and
downloading a .tar.gz file via gitweb.

Host: AMD Athlon II X4 640 cpu with 4GB memory on an ASUS M488T-M
motherboard with Ubuntu 10.04LTS and LinuxCNC 2.6.0-pre built from
sources. I previously posted results with this board to the Latency Test
page on the Wiki.

Installed your .deb files and did the housekeeping.

OOPS - the syntax for adding a user to a group is

# adduser <user> <group>

and not addgroup as stated in the readme.

---

The good news-

LinuxCNC built for xenomai-kernel threads without a hitch. I love how
fast a build goes with make running on multiple cores.

Since this is a quadcore system, I set isolcpus=3 and rebooted into
3.2.21-xenomai+

The not so good news-

I'm seeing the same sort of strange behavior I saw with the RT-PREEMPT
patches earlier although not as strongly.

RTAI - 1ms servo thread/25us base thread - max jitter 4401ns/2378ns
after 3 hours

Xenomai/kernel - 1ms servo thread/25us base thread - max jitter appeared
to be running roughly 10000ns/10000ns after 45 minutes *but* then while
I was doing something random the max jitter jumped to 89590ns/367129ns
(at which point /proc/xenomai/stat said wait errors=8. last overrun=14,
total overruns=76). Later, I reran the test unattended for an hour and
again got roughly 10000ns/10000ns max jitter. Which is good but the
burst is worrisome.

The strange behavior is that as I increase the base period in 25us steps
I see both base and servo jitters first increase for several steps then
fall back somewhat to what seems to be a steady result at longish base
periods.

Here's what I get for a series of two-minute tests, always with a 1ms
servo period.

base period---max jitter (servo/base)
25us---5672ns/9734ns
50us---22037ns/32170ns
75us---24328ns/34338ns
100us---18712ns/30256ns
125us---17051ns/19064ns
150us---16775ns/19168ns
175us---14389ns/19667ms
200us---18403ns/21412ns

I believe the last three or four sets are essentially equivalent.

Does anyone understand why I'm getting this kind of behavior? It seems
to be repeatable. Is it an artifact of latency-test or is it real? Were
this a physical system, I'd wave my hands about being the system being
in saturation at the shortest periods, but here...?

I conjectured some time ago that the ASUS bios is perhaps causing a
problem with both this board and the Atom board I'll be testing in a
bit, but I need more data:-)

Regards,
Kent
Gene Heskett
2012-11-02 22:23:06 UTC
Permalink
Post by Kent A. Reed
Post by Michael Haberler
I have now integrated the RT-PREEMPT branch as provided by Charles,
added the now-working Xenomai-userland thread style, and massaged
configure to deal with all of this. The Xenomai-kernel branch I
reported about yesterday is fully integrated. If you played with that
branch, it's safe to switch.
./configure --with-threads=xenomai-user
./configure --with-threads=rt-preempt-user
./configure --with-threads=rtai
./configure --enable-simulator [--enable-drivers for the hal_parport usermode driver]
Are the machinations in debian/configure not relevant?
Post by Michael Haberler
<...>
Please pull from
http://git.mah.priv.at/gitweb/emc2-dev.git/shortlog/refs/heads/rtos-i
ntegration-preview1
I'm feeling especially old and crusty today. Not being a git Master (in
the sense of being master of all I survey) and failing in my several
tries to "pull from ...", I used my father's time-honored advice "don't
force it; get a bigger hammer", in this case, by creating and
downloading a .tar.gz file via gitweb.
Host: AMD Athlon II X4 640 cpu with 4GB memory on an ASUS M488T-M
motherboard with Ubuntu 10.04LTS and LinuxCNC 2.6.0-pre built from
sources. I previously posted results with this board to the Latency Test
page on the Wiki.
Installed your .deb files and did the housekeeping.
OOPS - the syntax for adding a user to a group is
# adduser <user> <group>
and not addgroup as stated in the readme.
No darned wonder I've always had to hand edit that crap. :(
Post by Kent A. Reed
---
The good news-
LinuxCNC built for xenomai-kernel threads without a hitch. I love how
fast a build goes with make running on multiple cores.
Since this is a quadcore system, I set isolcpus=3 and rebooted into
3.2.21-xenomai+
The not so good news-
I'm seeing the same sort of strange behavior I saw with the RT-PREEMPT
patches earlier although not as strongly.
RTAI - 1ms servo thread/25us base thread - max jitter 4401ns/2378ns
after 3 hours
Xenomai/kernel - 1ms servo thread/25us base thread - max jitter appeared
to be running roughly 10000ns/10000ns after 45 minutes *but* then while
I was doing something random the max jitter jumped to 89590ns/367129ns
(at which point /proc/xenomai/stat said wait errors=8. last overrun=14,
total overruns=76). Later, I reran the test unattended for an hour and
again got roughly 10000ns/10000ns max jitter. Which is good but the
burst is worrisome.
The strange behavior is that as I increase the base period in 25us steps
I see both base and servo jitters first increase for several steps then
fall back somewhat to what seems to be a steady result at longish base
periods.
Here's what I get for a series of two-minute tests, always with a 1ms
servo period.
base period---max jitter (servo/base)
25us---5672ns/9734ns
50us---22037ns/32170ns
75us---24328ns/34338ns
100us---18712ns/30256ns
125us---17051ns/19064ns
150us---16775ns/19168ns
175us---14389ns/19667ms
200us---18403ns/21412ns
I believe the last three or four sets are essentially equivalent.
Does anyone understand why I'm getting this kind of behavior? It seems
to be repeatable. Is it an artifact of latency-test or is it real? Were
this a physical system, I'd wave my hands about being the system being
in saturation at the shortest periods, but here...?
I conjectured some time ago that the ASUS bios is perhaps causing a
problem with both this board and the Atom board I'll be testing in a
bit, but I need more data:-)
Regards,
Kent
------------------------------------------------------------------------
------ LogMeIn Central: Instant, anywhere, Remote PC access and
management. Stay in control, update software, and manage PCs from one
command center Diagnose problems and improve visibility into emerging
IT issues Automate, monitor and manage. Do more in less time with
Central http://p.sf.net/sfu/logmein12331_d2d
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
Cheers, Gene
--
"There are four boxes to be used in defense of liberty:
soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
My web page: <http://coyoteden.dyndns-free.com:85/gene> is up!
The Surgeon General has determined that cigarette smoking is hazardous to
your
health.
John Morris
2012-11-02 23:09:03 UTC
Permalink
Hi Kent, and the list in general,
Post by Kent A. Reed
RTAI - 1ms servo thread/25us base thread - max jitter 4401ns/2378ns
after 3 hours
Xenomai/kernel - 1ms servo thread/25us base thread - max jitter appeared
to be running roughly 10000ns/10000ns after 45 minutes *but* then while
I was doing something random the max jitter jumped to 89590ns/367129ns
(at which point /proc/xenomai/stat said wait errors=8. last overrun=14,
total overruns=76). Later, I reran the test unattended for an hour and
again got roughly 10000ns/10000ns max jitter. Which is good but the
burst is worrisome.
The strange behavior is that as I increase the base period in 25us steps
I see both base and servo jitters first increase for several steps then
fall back somewhat to what seems to be a steady result at longish base
periods.
Here's what I get for a series of two-minute tests, always with a 1ms
servo period.
base period---max jitter (servo/base)
25us---5672ns/9734ns
50us---22037ns/32170ns
75us---24328ns/34338ns
100us---18712ns/30256ns
125us---17051ns/19064ns
150us---16775ns/19168ns
175us---14389ns/19667ms
200us---18403ns/21412ns
I believe the last three or four sets are essentially equivalent.
Does anyone understand why I'm getting this kind of behavior? It seems
to be repeatable. Is it an artifact of latency-test or is it real? Were
this a physical system, I'd wave my hands about being the system being
in saturation at the shortest periods, but here...?
I conjectured some time ago that the ASUS bios is perhaps causing a
problem with both this board and the Atom board I'll be testing in a
bit, but I need more data:-)
I know about the 'latency-test' app, which pops up a gui window. Is
there a command-line/textual interface for the app which would be
suitable for input into a log file with time stamps? (Do I need to hack
one up myself? ;)

It could be informative to run a latency test overnight that logged max
jitter into a log file, say, every 10 seconds (resetting the counter
every period, of course). Then spikes like Kent is seeing could be
correlated to system logs, performance monitoring systems, and other
available history of system activity.

John
Michael Haberler
2012-11-03 06:19:51 UTC
Permalink
Post by Kent A. Reed
Are the machinations in debian/configure not relevant?
not for building with 'sh autogen.sh; ./configure ..'; that is TBD
Post by Kent A. Reed
OOPS - the syntax for adding a user to a group is
# adduser <user> <group>
and not addgroup as stated in the readme.
fixed
Post by Kent A. Reed
The good news-
LinuxCNC built for xenomai-kernel threads without a hitch. I love how
fast a build goes with make running on multiple cores.
Since this is a quadcore system, I set isolcpus=3 and rebooted into
3.2.21-xenomai+
support for more than one core running an RT thread each isnt in place yet. I just outlined an idea but it's TBD.
Post by Kent A. Reed
The not so good news-
I'm seeing the same sort of strange behavior I saw with the RT-PREEMPT
patches earlier although not as strongly.
your observations closely match mine. leave it alone - figures look reasonable; do something with it, like network I/O - a sudden spike every now and then.

first, there's some xenomai-specific tools in /usr/xenomai/bin worth exploring, for instance the xenomai latency test:

***@atom:/usr/xenomai/bin# ./latency
== Sampling period: 100 us
== Test mode: periodic user-mode task
== All results in microseconds
warming up...
RTT| 00:00:01 (periodic user-mode task, 100 us period, priority 99)
RTH|----lat min|----lat avg|----lat max|-overrun|---msw|---lat best|--lat worst
RTD| -0.585| -0.517| 2.108| 0| 0| -0.585| 2.108
RTD| -0.933| -0.641| 12.546| 0| 0| -0.933| 12.546
RTD| -1.211| -0.617| 2.098| 0| 0| -1.211| 12.546

Note that latency-test uses RTAPI, and it's entirely possible I committed some goof in the code; it would be worth researching if the spikes we see also appear in the xenomai-supplied latency test

It seems to be possible to run both simultaneously; I'm doing that right now to see if the spike in the RTAPI version is reflected in the Xenomai version too

[guess what, spike wont show with both latency tests running :-/ - it's a Heisenspike!]

then, the kernel config could be at fault, too

I just went through http://www.xenomai.org/index.php/Configuring_x86_kernels and
http://www.xenomai.org/index.php/FAQs#Tips_and_tricks_setting_up_your_x86_kernel, and looking through /boot/config-3.2.21-xenomai+ ; I couldnt find an obvious blunder right away
--

depending upon results, there are a few things which could be done; for instance compiling the kernel with ipipe debugging support and see whether that uncovers anything

but first I guess the right thing to do is to verify whether the RTAPI is at fault or not

- Michael
Post by Kent A. Reed
RTAI - 1ms servo thread/25us base thread - max jitter 4401ns/2378ns
after 3 hours
Xenomai/kernel - 1ms servo thread/25us base thread - max jitter appeared
to be running roughly 10000ns/10000ns after 45 minutes *but* then while
I was doing something random the max jitter jumped to 89590ns/367129ns
(at which point /proc/xenomai/stat said wait errors=8. last overrun=14,
total overruns=76). Later, I reran the test unattended for an hour and
again got roughly 10000ns/10000ns max jitter. Which is good but the
burst is worrisome.
The strange behavior is that as I increase the base period in 25us steps
I see both base and servo jitters first increase for several steps then
fall back somewhat to what seems to be a steady result at longish base
periods.
Here's what I get for a series of two-minute tests, always with a 1ms
servo period.
base period---max jitter (servo/base)
25us---5672ns/9734ns
50us---22037ns/32170ns
75us---24328ns/34338ns
100us---18712ns/30256ns
125us---17051ns/19064ns
150us---16775ns/19168ns
175us---14389ns/19667ms
200us---18403ns/21412ns
I believe the last three or four sets are essentially equivalent.
Does anyone understand why I'm getting this kind of behavior? It seems
to be repeatable. Is it an artifact of latency-test or is it real? Were
this a physical system, I'd wave my hands about being the system being
in saturation at the shortest periods, but here...?
I conjectured some time ago that the ASUS bios is perhaps causing a
problem with both this board and the Atom board I'll be testing in a
bit, but I need more data:-)
Regards,
Kent
------------------------------------------------------------------------------
LogMeIn Central: Instant, anywhere, Remote PC access and management.
Stay in control, update software, and manage PCs from one command center
Diagnose problems and improve visibility into emerging IT issues
Automate, monitor and manage. Do more in less time with Central
http://p.sf.net/sfu/logmein12331_d2d
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
Michael Haberler
2012-11-03 06:30:27 UTC
Permalink
Am 03.11.2012 um 07:19 schrieb Michael Haberler:

...
Post by Michael Haberler
Note that latency-test uses RTAPI, and it's entirely possible I committed some goof in the code; it would be worth researching if the spikes we see also appear in the xenomai-supplied latency test
well, looking at: http://git.mah.priv.at/gitweb/xenomai-linuxcnc.git/blob/refs/heads/linuxcnc-v2.6.1:/src/testsuite/latency/latency.c

this uses rt_timer_tsc() to do samples, and my RTAPi does a rt_timer_read()

see http://www.xenomai.org/documentation/trunk/html/api/group__native__timer.html#gaa589af3dafaeaa5dcbf2ef7b6dde6af8 for the fineprint

that might explain different results between xenomai latency and RTAPI latency-test

but first this damn spike needs to show up, and it just doesnt right now :-/

-m
Kent A. Reed
2012-11-03 13:28:52 UTC
Permalink
Post by Michael Haberler
Post by Kent A. Reed
Since this is a quadcore system, I set isolcpus=3 and rebooted into
3.2.21-xenomai+
support for more than one core running an RT thread each isnt in place yet. I just outlined an idea but it's TBD.
Michael:

I'm pretty sure you and I are on the same wavelength, but an alternative
reading of your response is that I'm trying to isolate more than one cpu
and your work doesn't support that yet. For others who may be reading
this message thread casually, isolcpus=3 tells Linux to isolate cpu #3,
not isolate 3 cpus. Since the kernel numbers the cpus from 0, isolcpus=3
for a quadcore machine and isolcpus=1 for a dualcore machine both say
isolate the highest numbered cpu.

For this and your subsequent two messages, thanks. I'm very impressed
and pleased by the progress you've been making in the grand unification
of different approaches to realtime processing. I'm confident that you
and our other major contributors will conquer the niggly stuff (which I
can follow only in broad outline; OS internals were never my cup of tea).

I've got several more systems to play on while you look into RTAPI.

By the way, "Heisenspike" is a great turn of phrase...made me laugh.

Regards,
Kent
Michael Haberler
2012-11-03 15:10:28 UTC
Permalink
Post by Kent A. Reed
Post by Michael Haberler
Post by Kent A. Reed
Since this is a quadcore system, I set isolcpus=3 and rebooted into
3.2.21-xenomai+
support for more than one core running an RT thread each isnt in place yet. I just outlined an idea but it's TBD.
I'm pretty sure you and I are on the same wavelength, but an alternative
reading of your response is that I'm trying to isolate more than one cpu
and your work doesn't support that yet. For others who may be reading
this message thread casually, isolcpus=3 tells Linux to isolate cpu #3,
not isolate 3 cpus. Since the kernel numbers the cpus from 0, isolcpus=3
duh. it helps to read..
Post by Kent A. Reed
By the way, "Heisenspike" is a great turn of phrase...made me laugh.
Unfortunately, it wasnt - it reappeared.

for the the very determined, there are xenomai debs with ipipe tracing enabled here:

wget http://static.mah.priv.at/public/xenomai-debs/linux-image-3.2.21-xenomaiipipetrace+_0.2_i386.deb
wget http://static.mah.priv.at/public/xenomai-debs/linux-headers-3.2.21-xenomaiipipetrace+_0.2_i386.deb

dpkg -i linux-image-3.2.21-xenomaiipipetrace+_0.2_i386.deb
lucid doesnt have the libtinfo5 package, so it needs a bit of force to install
dpkg --ignore-depends=libtinfo5 -i linux-headers-3.2.21-xenomaiipipetrace+_0.2_i386.deb

http://www.xenomai.org/index.php/I-pipe:Tracer

I do get traces at new latency maximums. I have circa zero clue what to make of them.

oh well
-m
Kent A. Reed
2012-11-03 15:49:17 UTC
Permalink
Post by Michael Haberler
http://www.xenomai.org/index.php/I-pipe:Tracer
I do get traces at new latency maximums. I have circa zero clue what to make of them.
oh well
-m
I guess one hopes to capture "normal" increases in latency maximums that
occur until we reach some sort of long-term steady state (with a maximum
maximorum value we can use in tuning LinuxCNC) and "abnormal" increases
(e.g., our spikes) and then discern a difference in the patterns in the
traces. I'm sure the traces make sense to the cognoscenti, but looking
at the sample traces shown in the page you reference reminds me of the
joke about the man madly shoveling in the stables because "with this
much manure, there must be a pony in here somewhere."

Regards,
Kent
Kent A. Reed
2012-11-04 17:35:03 UTC
Permalink
Post by Kent A. Reed
<...>
The good news-
LinuxCNC built for xenomai-kernel threads without a hitch. I love how
fast a build goes with make running on multiple cores.
Since this is a quadcore system, I set isolcpus=3 and rebooted into
3.2.21-xenomai+
The not so good news-
I'm seeing the same sort of strange behavior I saw with the RT-PREEMPT
patches earlier although not as strongly.
RTAI - 1ms servo thread/25us base thread - max jitter 4401ns/2378ns
after 3 hours
Xenomai/kernel - 1ms servo thread/25us base thread - max jitter
appeared to be running roughly 10000ns/10000ns after 45 minutes *but*
then while I was doing something random the max jitter jumped to
89590ns/367129ns (at which point /proc/xenomai/stat said wait
errors=8. last overrun=14, total overruns=76). Later, I reran the test
unattended for an hour and again got roughly 10000ns/10000ns max
jitter. Which is good but the burst is worrisome.
The "something random" turns out to be executing "cat
/proc/xenomai/stat" in a separate terminal while running latency-test.
This operation reliably kicks the reported max-jitter number over the
moon. Looking at /proc/rtapi/status doesn't seem to be a problem.

Hope this helps.

Regards,
Kent
Jon Elson
2012-11-04 22:44:29 UTC
Permalink
Post by Kent A. Reed
The "something random" turns out to be executing "cat
/proc/xenomai/stat" in a separate terminal while running latency-test.
This operation reliably kicks the reported max-jitter number over the
moon. Looking at /proc/rtapi/status doesn't seem to be a problem.
Wow, good find! This probably indicates some kernel service is getting
blocked waiting for exclusive access to a kernel data structure.
It might be easy to find but hard to fix. It might be good to know
if any common utilities or apps use this service.

Jon
Kent A. Reed
2012-11-04 23:38:33 UTC
Permalink
So, in an earlier message concerning my test of Michael's codebase on
Post by Kent A. Reed
<...>
The strange behavior is that as I increase the base period in 25us
steps I see both base and servo jitters first increase for several
steps then fall back somewhat to what seems to be a steady result at
longish base periods.
Here's what I get for a series of two-minute tests, always with a 1ms
servo period.
base period---max jitter (servo/base)
25us---5672ns/9734ns
50us---22037ns/32170ns
75us---24328ns/34338ns
100us---18712ns/30256ns
125us---17051ns/19064ns
150us---16775ns/19168ns
175us---14389ns/19667ms
200us---18403ns/21412ns
I believe the last three or four sets are essentially equivalent.
Does anyone understand why I'm getting this kind of behavior? It seems
to be repeatable. Is it an artifact of latency-test or is it real?
Were this a physical system, I'd wave my hands about being the system
being in saturation at the shortest periods, but here...?
First off, this is not an artifact of Michael's work with Xenomai, I
have now been able to obtain similar results with the distributed
LinuxCNC on RTAI.

I got to thinking I'd read something like this. Yep, turns out it's
already described in the wiki,
http://wiki.linuxcnc.org/cgi-bin/wiki.pl?RealTime, from which I quote
Post by Kent A. Reed
I saw some other cache related behavior a long time ago when doing
some latency testing. The latency results improved noticeably when I
lowered the thread period below some threshold. (I don't remember the
threshold period, it was at least a year ago.)
I eventually realized that when I was running the thread very
frequently, the RT code never got pushed out of cache. When I
increased the period, other processes had enough time to replace the
RT code in cache between invocations of the thread.
This language has been in place since at least 2009. I don't know who
contributed it. The historical documents are incomplete.

I tried loading up the system with CPU hogs (see the wiki) and was able
to reduce my max-jitter numbers by 4us to 10us at the higher base
periods and by only a little at the shortest base periods---as would be
expected because the shortest base periods exihibit the smallest max
jitters.

This behavior holds with one or two cpus isolated and with RTAI or Xenomai.

Regards,
Kent
dave
2012-11-05 03:40:29 UTC
Permalink
Post by Kent A. Reed
So, in an earlier message concerning my test of Michael's codebase on
Post by Kent A. Reed
<...>
The strange behavior is that as I increase the base period in 25us
steps I see both base and servo jitters first increase for several
steps then fall back somewhat to what seems to be a steady result at
longish base periods.
Here's what I get for a series of two-minute tests, always with a 1ms
servo period.
base period---max jitter (servo/base)
25us---5672ns/9734ns
50us---22037ns/32170ns
75us---24328ns/34338ns
100us---18712ns/30256ns
125us---17051ns/19064ns
150us---16775ns/19168ns
175us---14389ns/19667ms
200us---18403ns/21412ns
I believe the last three or four sets are essentially equivalent.
Does anyone understand why I'm getting this kind of behavior? It seems
to be repeatable. Is it an artifact of latency-test or is it real?
Were this a physical system, I'd wave my hands about being the system
being in saturation at the shortest periods, but here...?
First off, this is not an artifact of Michael's work with Xenomai, I
have now been able to obtain similar results with the distributed
LinuxCNC on RTAI.
I got to thinking I'd read something like this. Yep, turns out it's
already described in the wiki,
http://wiki.linuxcnc.org/cgi-bin/wiki.pl?RealTime, from which I quote
Post by Kent A. Reed
I saw some other cache related behavior a long time ago when doing
some latency testing. The latency results improved noticeably when I
lowered the thread period below some threshold. (I don't remember the
threshold period, it was at least a year ago.)
I eventually realized that when I was running the thread very
frequently, the RT code never got pushed out of cache. When I
increased the period, other processes had enough time to replace the
RT code in cache between invocations of the thread.
This language has been in place since at least 2009. I don't know who
contributed it. The historical documents are incomplete.
I tried loading up the system with CPU hogs (see the wiki) and was able
to reduce my max-jitter numbers by 4us to 10us at the higher base
periods and by only a little at the shortest base periods---as would be
expected because the shortest base periods exihibit the smallest max
jitters.
This behavior holds with one or two cpus isolated and with RTAI or Xenomai.
Regards,
Kent
Hi,

Way back in history ... when the amd 64 bit dual cpus came out Seb did
something where he kept one cpu busy with a script and used the other
for latency and got much better figures than allowing both cpu's some
free time. My conclusions may be wrong or my memory may have failed but
could this be the some kind of thing.

Dave
Post by Kent A. Reed
------------------------------------------------------------------------------
LogMeIn Central: Instant, anywhere, Remote PC access and management.
Stay in control, update software, and manage PCs from one command center
Diagnose problems and improve visibility into emerging IT issues
Automate, monitor and manage. Do more in less time with Central
http://p.sf.net/sfu/logmein12331_d2d
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
Kent A. Reed
2012-11-07 15:53:52 UTC
Permalink
Post by Michael Haberler
I have now integrated the RT-PREEMPT branch as provided by Charles, added the now-working Xenomai-userland thread style, and massaged configure to deal with all of this. The Xenomai-kernel branch I reported about yesterday is fully integrated. If you played with that branch, it's safe to switch.
./configure --with-threads=xenomai-user
./configure --with-threads=rt-preempt-user
./configure --with-threads=rtai
./configure --enable-simulator [--enable-drivers for the hal_parport usermode driver]
Just a note to say that, so far, using Michael's various kernels and his
git server, I've built LinuxCNC 2.5.1 on my AMD quad-core machine
running Ubuntu 10.04LTS and three of his thread scenarios
(xenomai-kernel, rt-preempt-user, rtai) without any problems. My thanks
and a tip of the hat to Michael.

I've also built with the xenomai-kernel thread scenario on a dual-core
Atom netbook running Linux Mint 13. This build required making the
change to the pow-function definition labelled in Michael's work as
required for Ubuntu Precise. FYI, Mint 13 installs gcc 4.6.3 and
binutils 2.22. I believe the problem with pow lies not so much with gcc
but gcc and ld together, but I've not been able to tease a solution out
of the GSF readmes. Of course, the netbook sucks, but that's the color
of a different horse. I used it because it was there. I'm going to drop
back to a simulator on the netbook so I can play while sitting in
waiting rooms.

As for my old single-core Pentium 4 box, I'm having problems unrelated
to this work specifically. Somehow, the new kernels are screwing up my
Xserver---the screen is blank. I can ssh into the box so with time and
elbow grease I'm sure I can fix it.

Regards,
Kent
Abel Michael
2012-11-11 23:08:45 UTC
Permalink
Hi there,

I've updated my shared memory hal module and LinuxCNC adoption which
enables real time data transfer between LinuxCNC and other real-time
programs running on rt-preempt.

My work is now put on top of the rtos-integration-preview1 branch from
Michael Haberler.

The functionality was also contained in earlier Versions of the
rt-preempt port I did on the basis of Michael Büschs work. But now, my
patch/adoption is clearer and smaller as the support for rt-preempt is
already there. And of course it's still beta.

Please pull branch shm_interface from
http://gitorious.org/emc-rt-preempt/emc-rt-preempt

after compiling start the cnc and the rt-interface tester afterwards:

cd /src/hal/drivers/shared_memory
make -f Makefile_shm
sudo chrt 90 ./shm_interface_test

In the end it should look nearly like a year ago :) :
Loading Image...

Regards,

Michael
Post by Michael Haberler
I have now integrated the RT-PREEMPT branch as provided by Charles, added the now-working Xenomai-userland thread style, and massaged configure to deal with all of this. The Xenomai-kernel branch I reported about yesterday is fully integrated. If you played with that branch, it's safe to switch.
./configure --with-threads=xenomai-user
./configure --with-threads=rt-preempt-user
./configure --with-threads=rtai
./configure --enable-simulator [--enable-drivers for the hal_parport usermode driver]
for the RT-PREEMT flavor, please install
http://static.mah.priv.at/public/xenomai-debs/linux-headers-3.4.13-rt-preempt-rt22+_0.1_i386.deb
http://static.mah.priv.at/public/xenomai-debs/linux-image-3.4.13-rt-preempt-rt22+_0.1_i386.deb
The notes from README.xenomai wrt initrd and update-grub apply as well.
Please pull from http://git.mah.priv.at/gitweb/emc2-dev.git/shortlog/refs/heads/rtos-integration-preview1
- Michael
- The userland parport driver needs work - it cant claim the parport yet :-/ The nice part is: you can fix it with gdb.
- runtests with rt-preempt-user shows errors, but that is because stderr messages cause it to 'fail' whereas the regression output actually is ok
[so here's some drinking from the firehose for the weekend;) ]
------------------------------------------------------------------------------
LogMeIn Central: Instant, anywhere, Remote PC access and management.
Stay in control, update software, and manage PCs from one command center
Diagnose problems and improve visibility into emerging IT issues
Automate, monitor and manage. Do more in less time with Central
http://p.sf.net/sfu/logmein12331_d2d
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
--
--------------------------------------------------------------
Dipl.-Ing. Michael Abel

Graduate School of advanced Manufacturing Engineering
GSaME - Universität Stuttgart

Institut für Steuerungstechnik
der Werkzeugmaschinen und Fertigungseinrichtungen
ISW - Universität Stuttgart

Seidenstr. 36
70174 Stuttgart

Tel.: ++49 (0) 711 685-82532
Fax : ++49 (0) 711 685-82808

michael.abel-PvR2ET76y1sL63KmMnjC+***@public.gmane.org
michael.abel-mmWg1XfvUW+***@public.gmane.org

www.gsame.uni-stuttgart.de
www.isw.uni-stuttgart.de
--------------------------------------------------------------
EBo
2012-11-13 05:17:47 UTC
Permalink
Recently I took several pokes at building the experimental versions of
LinuxCNC on Gentoo with no success.

The first issue that arose is that I have phthon-3.2.3 selected by
default. I had to switch it to 2.7.3 for it to get past the following
error:

checking python version... File "<string>", line 1
import sys;raise SystemExit,sys.hexversion<0x2040000
^
SyntaxError: invalid syntax
configure: error: Python version too old (2.4 or newer required)

which is misleading since the version is in fact to new. This problem
is seemingly fixed with adding --with-python=/usr/bin/python2 to
configure. But problems arise when you actually run compile and it
depends on the current version and breaks the build all over the place.
I can get it past this by eselect'ing python back to 2.7.3.

The next issue, which is currently completely stopping me, is that it
is complaining that boost::python is not installed. Actually it is
(version 1.49.0 to be precise). The problem seems to be how configure
tests for the boost library. I can get past this by adding
--disable-python, but then the build dies looking for
depends/emc/pythonplugin/python_plugin.d

At this point the build system is to broken for me to port it to Gentoo
with the time resources I have at my disposal.

If anyone has a little time to work on python-3.2 support and sort out
the problem with boost, I'll take another poke at it...

EBo --
Post by Abel Michael
Hi there,
I've updated my shared memory hal module and LinuxCNC adoption which
enables real time data transfer between LinuxCNC and other real-time
programs running on rt-preempt.
My work is now put on top of the rtos-integration-preview1 branch from
Michael Haberler.
The functionality was also contained in earlier Versions of the
rt-preempt port I did on the basis of Michael Büschs work. But now, my
patch/adoption is clearer and smaller as the support for rt-preempt is
already there. And of course it's still beta.
Please pull branch shm_interface from
http://gitorious.org/emc-rt-preempt/emc-rt-preempt
cd /src/hal/drivers/shared_memory
make -f Makefile_shm
sudo chrt 90 ./shm_interface_test
http://www.bitmuster.org/projects/images/emc-shm-rt-gui.png
Regards,
Michael
Post by Michael Haberler
I have now integrated the RT-PREEMPT branch as provided by Charles,
added the now-working Xenomai-userland thread style, and massaged
configure to deal with all of this. The Xenomai-kernel branch I
reported about yesterday is fully integrated. If you played with that
branch, it's safe to switch.
./configure --with-threads=xenomai-user
./configure --with-threads=rt-preempt-user
./configure --with-threads=rtai
./configure --enable-simulator [--enable-drivers for the hal_parport usermode driver]
for the RT-PREEMT flavor, please install
http://static.mah.priv.at/public/xenomai-debs/linux-headers-3.4.13-rt-preempt-rt22+_0.1_i386.deb
http://static.mah.priv.at/public/xenomai-debs/linux-image-3.4.13-rt-preempt-rt22+_0.1_i386.deb
The notes from README.xenomai wrt initrd and update-grub apply as well.
Please pull from
http://git.mah.priv.at/gitweb/emc2-dev.git/shortlog/refs/heads/rtos-integration-preview1
- Michael
- The userland parport driver needs work - it cant claim the parport
yet :-/ The nice part is: you can fix it with gdb.
- runtests with rt-preempt-user shows errors, but that is because
stderr messages cause it to 'fail' whereas the regression output
actually is ok
[so here's some drinking from the firehose for the weekend;) ]
------------------------------------------------------------------------------
LogMeIn Central: Instant, anywhere, Remote PC access and management.
Stay in control, update software, and manage PCs from one command center
Diagnose problems and improve visibility into emerging IT issues
Automate, monitor and manage. Do more in less time with Central
http://p.sf.net/sfu/logmein12331_d2d
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
--
--------------------------------------------------------------
Dipl.-Ing. Michael Abel
Graduate School of advanced Manufacturing Engineering
GSaME - Universität Stuttgart
Institut für Steuerungstechnik
der Werkzeugmaschinen und Fertigungseinrichtungen
ISW - Universität Stuttgart
Seidenstr. 36
70174 Stuttgart
Tel.: ++49 (0) 711 685-82532
Fax : ++49 (0) 711 685-82808
www.gsame.uni-stuttgart.de
www.isw.uni-stuttgart.de
--------------------------------------------------------------
------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
http://p.sf.net/sfu/appdyn_d2d_nov
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
Michael Haberler
2012-11-17 09:31:44 UTC
Permalink
Hi Michael,
Post by Abel Michael
Hi there,
I've updated my shared memory hal module and LinuxCNC adoption which
enables real time data transfer between LinuxCNC and other real-time
programs running on rt-preempt.
I reviewed your code and I have some questions

First, I am a bit fuzzy as to what those 'other realtime programs' are - could you explain? if it is of general use that would help to sell it

What I understand this does is periodically copy from/to a fixed set of HAL pins and a shared memory segment intended for some other code. That copy process introduces delay and possibly race conditions - is it completely out of the question to extend the other code so it can access pins directly? the big advantage of that would be: no copy, no race condition, no extra single-purpose component, no RTAPI changes.

Please clarify what the 'RTAPI semaphores' mean - obviously they are intended for communication between your external program and your component, so I do not understand why it has to go into RTAPI to start with, which is Linuxcnc-internal (btw please note we just removed semaphore, fifo and irq handling code from RTAPi because that was never used, and you need a really good use case to reintegrate it). I understand the new RTAPI semaphore is only used in your code.
Post by Abel Michael
From a comment in the code it seems you were aware of race conditions and consider blocking EMC2 until your component is done. This is not a good idea because it will change the RT timing behavior.
to summarize:

- I think interfacing to other programs is a valuable line of thought and might have use cases
- it would help very much if the mechanism were generic, not special-purpose/fixed set of/fixed types of pins
- I think the copying mechanism will be a source of trouble and I would go for a direct access mechanism if remotely possible
- if you need synchronization primitives, I suggest the existing non-blocking mutex operations in RTAPI which are based on atomic operations - blocking is generally not a good idea in RT applications; rather postpone until next thread invocation instead of blocking.

--

To clarify what I mean with a 'generic mechanism', here is some line of thought:

Currently there is a duplicity of mechanism for status reporting in LinuxCNC. We have shared memory status objects which are communicated through NML messages, through special purpose code like usrmotif.cc, and we have HAL, and we have halrmt glued on top of that. Some would call that a terrible mess lacking style.

I think HAL is the strongest foundation of LinuxCNC, and it makes therefore sense to consider how to tie HAL into messaging without grafting several incompatible methods on top of HAL or shared memory one way or the other, which is the situation we have now.

That said, looking at the status reporting task: what the mechanisms have in common is:
- the may report typically several values together (like in your code, positions x,y,z)
- they are triggered either by timer expiring, or a change of some value, for _some_ being dependent on the task.

I tried to abstract this functionality into HAL objects and commands, and I arrived at an idea which I call 'HAL signal groups'. The gist of the idea is this:

- HAL gets a new object, called 'group'. A group has a HAL name, and (for now two) integer parameters which are for using code interpretation.
- a group can have members which must be signals. Each member descriptor again carries two parameters for using code interpretation.
- the only extensions in HAL are to enable group management, see below for a halcmd example.

Now you can create a component which works on HAL groups, for instance:
- periodically report a group by some mechanism (I used zeroMQ in the examples below, but it might be your shared memory thing, or event NML).
- watch a group for change, and report-if-changed. Now the member parameters could tell the code *which* of the members are to be monitored for change.

Note that this mechanism is completely generic within HAL, and HAL itself does not do anything with groups or members. Using components do.

I wrote such a generic change reporter, and it can be found (in trial stage) here: http://git.mah.priv.at/gitweb/emc2-dev.git/tree/4259166865c681017b6009f041ac4d1ed5e16439:/src/hal/halreport

There's a simple example of monitoring a hypothetical power supply here: http://git.mah.priv.at/gitweb/emc2-dev.git/blob/4259166865c681017b6009f041ac4d1ed5e16439:/src/hal/halreport/periodic+change-detect.hal

The idea is: you get group reports containing volts, amps, fuse-ok and mains-ok always together, but you trigger the update only if the fuse blows or mains goes away, and you do that by setting member parameters and have the using component interpret them.

This is unmerged code, but as we are heading for a more distributed setup I plan to clean it up and integrate it.

- Michael

---- here is an example of the signal groups usage --
for code see
for HAL API usage see: http://git.mah.priv.at/gitweb/emc2-dev.git/blob/4259166865c681017b6009f041ac4d1ed5e16439:/src/hal/halgroups/apiusage.c

# declare a couple of signals
newsig volt float
newsig amps float
newsig havepower bit

# declare a signal group with id 12
# and (up to two) optional parameters
# these are no interpreted by HAL

newg meter 12 4711 815

# add some signals
# a member can have an optional integer param
# again, not interpreted, just carried by HAL

newm meter volt # optional param defaults to 0
newm meter amps 2
newm meter havepower 1

# a signal to be added as a member must
# previously exist, so this will fail:
# newm meter ison

# but this succeeds:
newsig ripple float
newm meter ripple

# display the group
show group meter

# and memory status
status mem

# if you now delete asignal which is a group member
# this fails:
# delsig amps

# to do so, first remove the signal from all
# containing groups like so:
# delm meter amps
# delsig amps # will now succeed
Post by Abel Michael
My work is now put on top of the rtos-integration-preview1 branch from
Michael Haberler.
The functionality was also contained in earlier Versions of the
rt-preempt port I did on the basis of Michael Büschs work. But now, my
patch/adoption is clearer and smaller as the support for rt-preempt is
already there. And of course it's still beta.
Please pull branch shm_interface from
http://gitorious.org/emc-rt-preempt/emc-rt-preempt
cd /src/hal/drivers/shared_memory
make -f Makefile_shm
sudo chrt 90 ./shm_interface_test
http://www.bitmuster.org/projects/images/emc-shm-rt-gui.png
Regards,
Michael
Post by Michael Haberler
I have now integrated the RT-PREEMPT branch as provided by Charles, added the now-working Xenomai-userland thread style, and massaged configure to deal with all of this. The Xenomai-kernel branch I reported about yesterday is fully integrated. If you played with that branch, it's safe to switch.
./configure --with-threads=xenomai-user
./configure --with-threads=rt-preempt-user
./configure --with-threads=rtai
./configure --enable-simulator [--enable-drivers for the hal_parport usermode driver]
for the RT-PREEMT flavor, please install
http://static.mah.priv.at/public/xenomai-debs/linux-headers-3.4.13-rt-preempt-rt22+_0.1_i386.deb
http://static.mah.priv.at/public/xenomai-debs/linux-image-3.4.13-rt-preempt-rt22+_0.1_i386.deb
The notes from README.xenomai wrt initrd and update-grub apply as well.
Please pull from http://git.mah.priv.at/gitweb/emc2-dev.git/shortlog/refs/heads/rtos-integration-preview1
- Michael
- The userland parport driver needs work - it cant claim the parport yet :-/ The nice part is: you can fix it with gdb.
- runtests with rt-preempt-user shows errors, but that is because stderr messages cause it to 'fail' whereas the regression output actually is ok
[so here's some drinking from the firehose for the weekend;) ]
------------------------------------------------------------------------------
LogMeIn Central: Instant, anywhere, Remote PC access and management.
Stay in control, update software, and manage PCs from one command center
Diagnose problems and improve visibility into emerging IT issues
Automate, monitor and manage. Do more in less time with Central
http://p.sf.net/sfu/logmein12331_d2d
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
--
--------------------------------------------------------------
Dipl.-Ing. Michael Abel
Graduate School of advanced Manufacturing Engineering
GSaME - Universität Stuttgart
Institut für Steuerungstechnik
der Werkzeugmaschinen und Fertigungseinrichtungen
ISW - Universität Stuttgart
Seidenstr. 36
70174 Stuttgart
Tel.: ++49 (0) 711 685-82532
Fax : ++49 (0) 711 685-82808
www.gsame.uni-stuttgart.de
www.isw.uni-stuttgart.de
--------------------------------------------------------------
------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
http://p.sf.net/sfu/appdyn_d2d_nov
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
Abel Michael
2012-11-17 23:36:21 UTC
Permalink
Hi Michael,

On Sat, 17 Nov 2012 10:31:44 +0100
Post by John Morris
Hi Michael,
Post by Abel Michael
Hi there,
I've updated my shared memory hal module and LinuxCNC adoption which
enables real time data transfer between LinuxCNC and other real-time
programs running on rt-preempt.
I reviewed your code and I have some questions
Thanks for reviewing my changes
I'm trying to answer your questions
Post by John Morris
First, I am a bit fuzzy as to what those 'other realtime programs' are
- could you explain? if it is of general use that would help to sell it
Other real-time programs might be for example the user part of a "user
space io driver" (uio) "https://www.osadl.org/UIO.uio0.0.html" or real
time simulation engines, which simulate machine kinematics.
Especially some fieldbus PCI cards use these uio drivers as they these
are easier to handle for non kernel developers.
In my case, with the sercans card from Bosch Rexroth, we will probably
need a program for the bus-management, that sits between a regular
driver and the cnc.
Post by John Morris
What I understand this does is periodically copy from/to a fixed set
of HAL pins and a shared memory segment intended for some other code.
That copy process introduces delay and possibly race conditions -

Well, I hope, that the delay to copy a bit of data is neglectable. The
semaphores are there to have the possibility to avoid race conditions.
By the way, in the example I made the, cnc is never blocked it just
releases the semaphore.
Post by John Morris
is it completely out of the question to extend the other code so it
can access pins directly? the big advantage of that would be: no copy,
no race condition, no extra single-purpose component, no RTAPI changes.

I'm not sure what you mean by "access pins directly"? Is it maybe
possible to read from and to write to hal pins? That might be also a
nice option.
Post by John Morris
Please clarify what the 'RTAPI semaphores' mean - obviously they are
intended for communication between your external program and your
component, so I do not understand why it has to go into RTAPI to start
with, which is Linuxcnc-internal (btw please note we just removed
semaphore, fifo and irq handling code from RTAPi because that was never
used, and you need a really good use case to reintegrate it). I
understand the new RTAPI semaphore is only used in your code.

Originally, I've put the semaphore handling stuff into rtapi because
the function prototypes have been already there in rtapi.h.

As the semaphores are there to synchronize real-time processses rtapi
seems to be a good place. Moreover, the implementation will probably
look different on different platforms, another point for hiding this
stuff behind an API. But one has also to take into account, that the rt
IPC probably only makes sense on rt_preempt.

In reality it probably doesn't matter where the semaphore management
code is stored.
Is there maybe a better place available?
Post by John Morris
Post by Abel Michael
From a comment in the code it seems you were aware of race conditions
and consider blocking EMC2 until your component is done. This is not a
good idea because it will change the RT timing behavior.

Indeed, I have the plan to block linuxcnc while another process writes
to the shared memory. This is important to avoid race conditions, but
this must be done in a few micro seconds.
(It might be also nice to use sem_timedwait to wait only for a small
amount of time.)

Remember, what I like to do is basic support field-buses. You won't
need cycle times of 30us there because you still need to transfer data
through a bus system which is far slower

When you have servo drives that do an interpolation by themselves, you
also won't need a high cycle time. Even a few milliseconds might be
enough. I know these toys are expensive, but they are used in the
industry. And this might even be an option to get ready for such
industrial hardware.
Post by John Morris
- I think interfacing to other programs is a valuable line of thought
and might have use cases

Thanks :)
Post by John Morris
- it would help very much if the mechanism were generic, not
special-purpose/fixed set of/fixed types of pins

That's also a good point. I'm going to think about that.
The interface description is in the header file and must be known at
compile time. It may be possible to use two structures in the memory
where one is fixed and describes another dynamic one.
Post by John Morris
- I think the copying mechanism will be a source of trouble and I
would go for a direct access mechanism if remotely possible

Can you maybe explain what you mean with this mechanism?
Post by John Morris
- if you need synchronization primitives, I suggest the existing
non-blocking mutex operations in RTAPI which are based on atomic
operations - blocking is generally not a good idea in RT applications;
rather postpone until next thread invocation instead of blocking.

Well, when I'm right you can't share mutex variables between processes,
that's why I use semaphores. And of course you need to care about
proper real-time programming when you do such things.

It also seems like we need an option to let the user of the interface
choose between postponing, waiting and blocking (Thanks for the hint).
Post by John Morris
--
Currently there is a duplicity of mechanism for status reporting in
LinuxCNC. We have shared memory status objects which are communicated
through NML messages, through special purpose code like usrmotif.cc, and
we have HAL, and we have halrmt glued on top of that. Some would call
that a terrible mess lacking style.
Post by John Morris
I think HAL is the strongest foundation of LinuxCNC, and it makes
therefore sense to consider how to tie HAL into messaging without
grafting several incompatible methods on top of HAL or shared memory one
way or the other, which is the situation we have now.
Post by John Morris
- the may report typically several values together (like in your code, positions x,y,z)
- they are triggered either by timer expiring, or a change of some
value, for _some_ being dependent on the task.
Post by John Morris
I tried to abstract this functionality into HAL objects and commands,
and I arrived at an idea which I call 'HAL signal groups'. The gist of
Post by John Morris
- HAL gets a new object, called 'group'. A group has a HAL name, and
(for now two) integer parameters which are for using code interpretation.
Post by John Morris
- a group can have members which must be signals. Each member
descriptor again carries two parameters for using code interpretation.
Post by John Morris
- the only extensions in HAL are to enable group management, see below for a halcmd example.
- periodically report a group by some mechanism (I used zeroMQ in the
examples below, but it might be your shared memory thing, or event NML).
Post by John Morris
- watch a group for change, and report-if-changed. Now the member
parameters could tell the code *which* of the members are to be
monitored for change.
Post by John Morris
Note that this mechanism is completely generic within HAL, and HAL
itself does not do anything with groups or members. Using components do.
Post by John Morris
I wrote such a generic change reporter, and it can be found (in trial
stage) here:
http://git.mah.priv.at/gitweb/emc2-dev.git/tree/4259166865c681017b6009f041ac4d1ed5e16439:/src/hal/halreport
Post by John Morris
There's a simple example of monitoring a hypothetical power supply
here:
http://git.mah.priv.at/gitweb/emc2-dev.git/blob/4259166865c681017b6009f041ac4d1ed5e16439:/src/hal/halreport/periodic+change-detect.hal
Post by John Morris
The idea is: you get group reports containing volts, amps, fuse-ok and
mains-ok always together, but you trigger the update only if the fuse
blows or mains goes away, and you do that by setting member parameters
and have the using component interpret them.
Post by John Morris
This is unmerged code, but as we are heading for a more distributed
setup I plan to clean it up and integrate it.
Post by John Morris
- Michael
---- here is an example of the signal groups usage --
for code see
http://git.mah.priv.at/gitweb/emc2-dev.git/blob/4259166865c681017b6009f041ac4d1ed5e16439:/src/hal/halgroups/apiusage.c
Post by John Morris
# declare a couple of signals
newsig volt float
newsig amps float
newsig havepower bit
# declare a signal group with id 12
# and (up to two) optional parameters
# these are no interpreted by HAL
newg meter 12 4711 815
# add some signals
# a member can have an optional integer param
# again, not interpreted, just carried by HAL
newm meter volt # optional param defaults to 0
newm meter amps 2
newm meter havepower 1
# a signal to be added as a member must
# newm meter ison
newsig ripple float
newm meter ripple
# display the group
show group meter
# and memory status
status mem
# if you now delete asignal which is a group member
# delsig amps
# to do so, first remove the signal from all
# delm meter amps
# delsig amps # will now succeed
When I understand right, you are thinking about an kind of eventing
mechanism. There are sources of events and subscribers can register to
receive events.
Do I understand correctly?

This would introduce a new nice kind of execution behaviour. It will
probably also reduce processing power when triggers/events happen seldomly.
But does it really help when things happen in every cycle?


Greetings
Michael
Post by John Morris
Post by Abel Michael
My work is now put on top of the rtos-integration-preview1 branch from
Michael Haberler.
The functionality was also contained in earlier Versions of the
rt-preempt port I did on the basis of Michael Büschs work. But now, my
patch/adoption is clearer and smaller as the support for rt-preempt is
already there. And of course it's still beta.
Please pull branch shm_interface from
http://gitorious.org/emc-rt-preempt/emc-rt-preempt
cd /src/hal/drivers/shared_memory
make -f Makefile_shm
sudo chrt 90 ./shm_interface_test
http://www.bitmuster.org/projects/images/emc-shm-rt-gui.png
Regards,
Michael
Post by Michael Haberler
I have now integrated the RT-PREEMPT branch as provided by Charles,
added the now-working Xenomai-userland thread style, and massaged
configure to deal with all of this. The Xenomai-kernel branch I reported
about yesterday is fully integrated. If you played with that branch,
it's safe to switch.
Post by John Morris
Post by Abel Michael
Post by Michael Haberler
./configure --with-threads=xenomai-user
./configure --with-threads=rt-preempt-user
./configure --with-threads=rtai
./configure --enable-simulator [--enable-drivers for the
hal_parport usermode driver]
Post by John Morris
Post by Abel Michael
Post by Michael Haberler
for the RT-PREEMT flavor, please install
http://static.mah.priv.at/public/xenomai-debs/linux-headers-3.4.13-rt-preempt-rt22+_0.1_i386.deb
http://static.mah.priv.at/public/xenomai-debs/linux-image-3.4.13-rt-preempt-rt22+_0.1_i386.deb
Post by John Morris
Post by Abel Michael
Post by Michael Haberler
The notes from README.xenomai wrt initrd and update-grub apply as well.
Please pull from
http://git.mah.priv.at/gitweb/emc2-dev.git/shortlog/refs/heads/rtos-integration-preview1
Post by John Morris
Post by Abel Michael
Post by Michael Haberler
- Michael
- The userland parport driver needs work - it cant claim the
parport yet :-/ The nice part is: you can fix it with gdb.
Post by John Morris
Post by Abel Michael
Post by Michael Haberler
- runtests with rt-preempt-user shows errors, but that is because
stderr messages cause it to 'fail' whereas the regression output
actually is ok
Post by John Morris
Post by Abel Michael
Post by Michael Haberler
[so here's some drinking from the firehose for the weekend;) ]
------------------------------------------------------------------------------
Post by John Morris
Post by Abel Michael
Post by Michael Haberler
LogMeIn Central: Instant, anywhere, Remote PC access and management.
Stay in control, update software, and manage PCs from one command center
Diagnose problems and improve visibility into emerging IT issues
Automate, monitor and manage. Do more in less time with Central
http://p.sf.net/sfu/logmein12331_d2d
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
--
--------------------------------------------------------------
Dipl.-Ing. Michael Abel
Graduate School of advanced Manufacturing Engineering
GSaME - Universität Stuttgart
Institut für Steuerungstechnik
der Werkzeugmaschinen und Fertigungseinrichtungen
ISW - Universität Stuttgart
Seidenstr. 36
70174 Stuttgart
Tel.: ++49 (0) 711 685-82532
Fax : ++49 (0) 711 685-82808
www.gsame.uni-stuttgart.de
www.isw.uni-stuttgart.de
--------------------------------------------------------------
------------------------------------------------------------------------------
Post by John Morris
Post by Abel Michael
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
http://p.sf.net/sfu/appdyn_d2d_nov
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
------------------------------------------------------------------------------
Post by John Morris
Monitor your physical, virtual and cloud infrastructure from a single
web console. Get in-depth insight into apps, servers, databases, vmware,
SAP, cloud infrastructure, etc. Download 30-day Free Trial.
Pricing starts from $795 for 25 servers or applications!
http://p.sf.net/sfu/zoho_dev2dev_nov
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
--
--------------------------------------------------------------
Dipl.-Ing. Michael Abel

Graduate School of advanced Manufacturing Engineering
GSaME - Universität Stuttgart

Institut für Steuerungstechnik
der Werkzeugmaschinen und Fertigungseinrichtungen
ISW - Universität Stuttgart

Seidenstr. 36
70174 Stuttgart

Tel.: ++49 (0) 711 685-82532
Fax : ++49 (0) 711 685-82808

michael.abel-PvR2ET76y1sL63KmMnjC+***@public.gmane.org
michael.abel-mmWg1XfvUW+***@public.gmane.org

www.gsame.uni-stuttgart.de
www.isw.uni-stuttgart.de
--------------------------------------------------------------
Anders Wallin
2012-12-02 10:25:16 UTC
Permalink
Post by Michael Haberler
I have now integrated the RT-PREEMPT branch as provided by Charles, added
the now-working Xenomai-userland thread style, and massaged configure to
deal with all of this. The Xenomai-kernel branch I reported about yesterday
is fully integrated. If you played with that branch, it's safe to switch.
./configure --with-threads=xenomai-user
./configure --with-threads=rt-preempt-user
./configure --with-threads=rtai
./configure --enable-simulator [--enable-drivers for the hal_parport usermode driver]
for the RT-PREEMT flavor, please install
http://static.mah.priv.at/public/xenomai-debs/linux-headers-3.4.13-rt-preempt-rt22+_0.1_i386.deb
http://static.mah.priv.at/public/xenomai-debs/linux-image-3.4.13-rt-preempt-rt22+_0.1_i386.deb
The notes from README.xenomai wrt initrd and update-grub apply as well.
Please pull from
http://git.mah.priv.at/gitweb/emc2-dev.git/shortlog/refs/heads/rtos-integration-preview1
For mere mortals (not kernel hacker gurus), would it be possible to write
down a step-by-step guide for how to test these new developments on e.g.
Ubuntu 12.04LTS or 12.10?
I'd be happy to write down some notes in the wiki, but I don't know all the
steps yet... I am doing something like this:
1. get michael's kernel repo from git://git.mah.priv.at/linuxcnc-kernel
2. checkout the branch you want (xenomai, rt-preempt)
3. make xconfig (just defaults are OK?), make
4. what now? Move the bzImage to /boot ? How do I get it to show up in the
GRUB boot menu?

as for the linuxcnc part I think I can manage that, following the "install
from source" guide with minor modifications from here
http://wiki.linuxcnc.org/cgi-bin/wiki.pl?Installing_LinuxCNC

On x86 hardware, are there any particular reasons for choosing between
rt-preempt and xenomai?
Are both of these kernels something everyone DIY builds, or are there
stable and updated repos for the kernels?
Did anyone compare RTAI vs rt-preempt vs xenomai on the same hardware? Will
it make any difference for applications where only a servo-thread at ca 1ms
is used?

Anders
Michael Haberler
2012-12-02 11:48:25 UTC
Permalink
Post by Anders Wallin
Post by Michael Haberler
I have now integrated the RT-PREEMPT branch as provided by Charles, added
the now-working Xenomai-userland thread style, and massaged configure to
deal with all of this. The Xenomai-kernel branch I reported about yesterday
is fully integrated. If you played with that branch, it's safe to switch.
./configure --with-threads=xenomai-user
./configure --with-threads=rt-preempt-user
./configure --with-threads=rtai
./configure --enable-simulator [--enable-drivers for the hal_parport usermode driver]
for the RT-PREEMT flavor, please install
http://static.mah.priv.at/public/xenomai-debs/linux-headers-3.4.13-rt-preempt-rt22+_0.1_i386.deb
http://static.mah.priv.at/public/xenomai-debs/linux-image-3.4.13-rt-preempt-rt22+_0.1_i386.deb
The notes from README.xenomai wrt initrd and update-grub apply as well.
Please pull from
http://git.mah.priv.at/gitweb/emc2-dev.git/shortlog/refs/heads/rtos-integration-preview1
For mere mortals (not kernel hacker gurus), would it be possible to write
down a step-by-step guide for how to test these new developments on e.g.
Ubuntu 12.04LTS or 12.10?
I'd be happy to write down some notes in the wiki, but I don't know all the
1. get michael's kernel repo from git://git.mah.priv.at/linuxcnc-kernel
yes
Post by Anders Wallin
2. checkout the branch you want (xenomai, rt-preempt)
yes
Post by Anders Wallin
3. make xconfig (just defaults are OK?), make
look in the toplevel linuxcnc subdirectory of that branch. This should contain configs which are known work, and a build script. Dont start inventing configs from scratch, this has been a loooong path to arrive at what's found there
Post by Anders Wallin
4. what now? Move the bzImage to /boot ? How do I get it to show up in the
GRUB boot menu?
if you use my build scripts - just install the resulting .debs with dpkg -i <debnames ...>

if you do it manually, post build, you do the:
make modules_install headers_install
yes, move bzImage to /boot/vmlinuz-.....
then update-initramfs -c -k <kernel-version>
and 'update-grub'
Post by Anders Wallin
as for the linuxcnc part I think I can manage that, following the "install
from source" guide with minor modifications from here
http://wiki.linuxcnc.org/cgi-bin/wiki.pl?Installing_LinuxCNC
there's a longish list of options, some old gone, the important ones are:

given no option, configure tries to determine the current kernel version and inspect /boot/config-`uname -r` to see what's running, and will set thread style appropriately. For xenomai it defaults to --with-threads=xenomai-user, and for RT_PREEMPT it defaults to --with-threads=rt-preempt-user. RTAI works without further ado; you can always cross-build by forcing a thread style and pointing to a kernel config by --with-kernel=/boot/config-<kernelversion>.

--with-threads=posix # the old simulator build; you can add --enable-drivers which will build a simulator with hal_parport - technically its not a simulator anymore but it can drive a machine, however with absolutely lousy latency, this is really good only for non-RT type standalone applications when you dont need RT behaviour
ad dont want to/cannot install an RT kernel

--with-threads=xenomai-user # this is likely what you want
--with-threads=rt-preempt-user # does work to but has signifcantly worse latency values than xenomai-ser

for platforms we have:

--with-platform=beaglebone and --with-platform=raspberry ; defaults to PC
Post by Anders Wallin
On x86 hardware, are there any particular reasons for choosing between
rt-preempt and xenomai?
see above
Post by Anders Wallin
Are both of these kernels something everyone DIY builds, or are there
stable and updated repos for the kernels?
currently only DIY builds; and chances for Xenomai stock kernels are anywhere from none to homooeopathic; with RT_PREEMPT it's very likely that a stock kernel could be used.
Post by Anders Wallin
Did anyone compare RTAI vs rt-preempt vs xenomai on the same hardware? Will
it make any difference for applications where only a servo-thread at ca 1ms
is used?
latency ordering is: RTAI, Xenomai-User, Xenomai-Kernel, RT_PREEMPT, Posix from best to worse

I would think for a servo config the xenomai-user version would work, likely also rt-preempt

NB: we dont have PCI drivers yet, so no hostmot and colleagues!
-m
Post by Anders Wallin
Anders
------------------------------------------------------------------------------
DESIGN Expert tips on starting your parallel project right.
http://goparallel.sourceforge.net/
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
Charles Steinkuehler
2012-11-02 15:33:04 UTC
Permalink
Post by Charles Steinkuehler
./configure --enable-simulator [--enable-drivers for the
hal_parport usermode driver]
...and what is it for kernel-mode xenomai?
<heh> ./configure tells me it's xenomai-kernel...building now.

- --
Charles Steinkuehler
charles-***@public.gmane.org
Michael Haberler
2012-11-02 15:44:16 UTC
Permalink
watch out - since a kernel is NOT a unique description of the build, you still want to force

./configure --with-threads=xenomai-kernel

or you get the default, which is xenomai-user

-m
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Post by Charles Steinkuehler
./configure --enable-simulator [--enable-drivers for the
hal_parport usermode driver]
...and what is it for kernel-mode xenomai?
<heh> ./configure tells me it's xenomai-kernel...building now.
- --
Charles Steinkuehler
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iEYEARECAAYFAlCT57AACgkQLywbqEHdNFykmQCfeXdpKOwHKcEN8585izNvlsef
0okAoLWW++4w2/EL0dP2fjc+GPB/THNl
=gKTz
-----END PGP SIGNATURE-----
------------------------------------------------------------------------------
LogMeIn Central: Instant, anywhere, Remote PC access and management.
Stay in control, update software, and manage PCs from one command center
Diagnose problems and improve visibility into emerging IT issues
Automate, monitor and manage. Do more in less time with Central
http://p.sf.net/sfu/logmein12331_d2d
_______________________________________________
Emc-developers mailing list
https://lists.sourceforge.net/lists/listinfo/emc-developers
Michael Haberler
2012-11-02 15:47:59 UTC
Permalink
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
I have now integrated the RT-PREEMPT branch as provided by
Charles, added the now-working Xenomai-userland thread style, and
massaged configure to deal with all of this. The Xenomai-kernel
branch I reported about yesterday is fully integrated. If you
played with that branch, it's safe to switch.
Awesomely groovy!
I'm at this very moment trying to pull the xenomai kernel stuff to
build and test on my hardware. Should I go ahead and pull this new
branch?
yes, definitely - the xenomai-kernel mode branch is fully integrated.
./configure --with-threads=xenomai-user
./configure --with-threads=rt-preempt-user
./configure --with-threads=rtai
./configure --enable-simulator [--enable-drivers for the
hal_parport usermode driver]
...and what is it for kernel-mode xenomai?
In place. I said so yesterday ;)

-M
- --
Charles Steinkuehler
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iEYEARECAAYFAlCT5sIACgkQLywbqEHdNFxHagCePJ5w9e+Zzp9bBcSR3MSd9iwl
bogAoPd5dxUb836+6LPVuZCxMz9nNf/6
=Nc1y
-----END PGP SIGNATURE-----
Loading...