Re: [Xenomai-core] [PATCH] blackfin: build xenomai in FLAT format

2009-02-25 Thread Gilles Chanteperdrix
yi li wrote: On Wed, Feb 25, 2009 at 12:30 AM, Philippe Gerum r...@xenomai.org wrote: 2. libpthread_rt.la should not depend on lpthread. Nak. In flat mode, turning the link dependencies order upside down will not buy us anything. Two-phase link is the only way to prevent circular/invalid

Re: [Xenomai-core] [PATCH 2/2] rtdk: Add assert_context helpers

2009-02-25 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Provide assert_nrt helper that checks if the caller is either not a shadow thread or is currently running in relaxed mode. If not, SIG_XCPU is raised. This service is then used to provide wrappers for glibc functions that are not realtime-safe but do not always trigger a

Re: [Xenomai-core] [PATCH] Fix gatekeeper affinity

2009-02-24 Thread Gilles Chanteperdrix
Jan Kiszka wrote: As the xnsched structures get initialized later, during xnpod_init, xnsched_cpu always returned 0 in the gatekeeper_thread prologue. That caused binding of all gatekeepers to CPU 0. Signed-off-by: Jan Kiszka jan.kis...@siemens.com --- ksrc/nucleus/shadow.c |5 -

Re: [Xenomai-core] [PATCH] Fix gatekeeper affinity

2009-02-24 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: As the xnsched structures get initialized later, during xnpod_init, xnsched_cpu always returned 0 in the gatekeeper_thread prologue. That caused binding of all gatekeepers to CPU 0. Signed-off-by: Jan Kiszka jan.kis

Re: [Xenomai-core] XENO_OPT_SYS_STACKPOOLSZ vs. switchtest

2009-02-19 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Hi Gilles, how much XENO_OPT_SYS_STACKPOOLSZ do I need to run switchtest for default settings? At least on x86-64, the default 32K is not enough. Unless we talk about GB ;), maybe it makes sense to adjust the default size

Re: [Xenomai-core] XENO_OPT_SYS_STACKPOOLSZ vs. switchtest

2009-02-19 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Hi Gilles, how much XENO_OPT_SYS_STACKPOOLSZ do I need to run switchtest for default settings? At least on x86-64, the default 32K is not enough. Unless we talk about GB ;), maybe

Re: [Xenomai-core] XENO_OPT_SYS_STACKPOOLSZ vs. switchtest

2009-02-19 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Philippe Gerum wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Hi Gilles, how much XENO_OPT_SYS_STACKPOOLSZ do I need to run switchtest for default settings? At least on x86-64, the default 32K

Re: [Xenomai-core] [PATCH v2 1/4] POSIX: Fix SCHED_RR thread creation

2009-02-17 Thread Gilles Chanteperdrix
Jan Kiszka wrote: @@ -192,6 +192,9 @@ static void *__pthread_trampoline(void *arg) param.sched_priority = iargs-prio; policy = iargs-policy; + if (policy == SCHED_RR) + /* Restrict round-robin scheduling to the Xenomai domain. */ + policy =

Re: [Xenomai-core] [PATCH v2 1/4] POSIX: Fix SCHED_RR thread creation

2009-02-17 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: @@ -192,6 +192,9 @@ static void *__pthread_trampoline(void *arg) param.sched_priority = iargs-prio; policy = iargs

Re: [Xenomai-core] SMP build failure (2.6.28)

2009-02-12 Thread Gilles Chanteperdrix
Paul wrote: On Thursday 12 February 2009, Gilles Chanteperdrix wrote: Paul wrote: Patching a 2.6.28.2 with the relevant patch in trunk, using a config with SMP enabled resulted in: LD kernel/xenomai/arch/built-in.o CC kernel/xenomai/nucleus/heap.o In file included from

Re: [Xenomai-core] trunk: xnsched_set_policy seems to set only cprio

2009-01-28 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Hi, unfortunately I'm forced to switch to other bugs, but I found out a bit more about the issue that pthread_getschedparam doesn't return the correct policyprio under trunk - at least when called from threads created via pthread_create as SCHED_FIFO: Such threads start

Re: [Xenomai-core] Pending patches

2009-01-27 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Jan Kiszka wrote: Philippe Gerum wrote: We should indeed postpone this just in case the upper layer indexes the extra state on the minor value. We can also simplify a few things doing so. --- ksrc/nucleus/pipe.c (revision 4565) +++ ksrc/nucleus/pipe.c (working

Re: [Xenomai-core] Pending patches

2009-01-27 Thread Gilles Chanteperdrix
Philippe Gerum wrote: Jan Kiszka wrote: Philippe Gerum wrote: We should indeed postpone this just in case the upper layer indexes the extra state on the minor value. We can also simplify a few things doing so. --- ksrc/nucleus/pipe.c (revision 4565) +++ ksrc/nucleus/pipe.c

Re: [Xenomai-core] [PATCH] xnpipe: Fix minor number management

2009-01-27 Thread Gilles Chanteperdrix
Jan Kiszka wrote: This is an attempt to fix the bugs found in the minor number management: - changing the bitmap requires atomic operations - clrbits/setbits work against xnarch_atomic_t, and that is only 32 bit wide on x86-64 I think we should rather fix xnarch_atomic_t to be the size of a

Re: [Xenomai-core] [PATCH] xnpipe: Fix minor number management

2009-01-27 Thread Gilles Chanteperdrix
Gilles Chanteperdrix wrote: As for the find_first_bit, why not simply taking the nklock in xnpipe_minor_free ? This is a first masking section, so this should not matter a lot. a short masking section -- Gilles

[Xenomai-core] [RFC] FPU support

2009-01-27 Thread Gilles Chanteperdrix
Hi, having to work on twice consecutive FPU issues made me think a bit about the situation of FPU support in Xenomai. What makes our FPU support code so complex? It is the fact that we support eager FPU context save/restore for both user-space and kernel-space real-time threads which ask it

Re: [Xenomai-core] [RFC] FPU support

2009-01-27 Thread Gilles Chanteperdrix
Paul wrote: Hi Giles On Tuesday 27 January 2009, Gilles Chanteperdrix wrote: So, the question is: are there people around who either: - need FPU support for kernel-space real-time threads; - do not want to pay the price of a trap when using the FPU in user-space. One application that I

Re: [Xenomai-core] [PATCH] uClibc compile failure

2009-01-20 Thread Gilles Chanteperdrix
Philippe Gerum wrote: Fillod Stephane wrote: Hi, I haven't seen a reply to this patch, maybe it has been missed? Actually, it was on queue but delayed by the inlined patch. The shm_open/unlink should be fixed by now in both the v2.4.x and trunk You mean mmap64/ftruncate64, right? --

Re: [Xenomai-core] Pending patches

2009-01-15 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Hi, currently I have the following six patches in my assorted queue (git://git.kiszka.org/xenomai.git queue/assorted). All have been posted before, I just rebased them since then a few times. Should I repost any/all of them (would be no problem), or are some already queued

Re: [Xenomai-core] Pending patches

2009-01-15 Thread Gilles Chanteperdrix
Gilles Chanteperdrix wrote: Jan Kiszka wrote: Hi, currently I have the following six patches in my assorted queue (git://git.kiszka.org/xenomai.git queue/assorted). All have been posted before, I just rebased them since then a few times. Should I repost any/all of them (would be no problem

Re: [Xenomai-core] Pending patches

2009-01-15 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Hi, currently I have the following six patches in my assorted queue (git://git.kiszka.org/xenomai.git queue/assorted). All have been posted before, I just rebased them since then a few times. Should I repost any/all of them

Re: [Xenomai-core] Clock drift.

2009-01-15 Thread Gilles Chanteperdrix
Philippe Gerum wrote: Gilles Chanteperdrix wrote: Philippe Gerum wrote: Gilles Chanteperdrix wrote: Hi, I run clocktest on a system here, not running NTP, using CONFIG_GENERIC_CLOCKEVENT, with a systematic drift of 3us/s. How can this happen? Does it come from the error due to the multiply

Re: [Xenomai-core] Clock drift.

2009-01-15 Thread Gilles Chanteperdrix
Gilles Chanteperdrix wrote: Philippe Gerum wrote: Gilles Chanteperdrix wrote: Philippe Gerum wrote: Gilles Chanteperdrix wrote: Hi, I run clocktest on a system here, not running NTP, using CONFIG_GENERIC_CLOCKEVENT, with a systematic drift of 3us/s. How can this happen? Does it come from

Re: [Xenomai-core] Clock drift.

2009-01-15 Thread Gilles Chanteperdrix
Gilles Chanteperdrix wrote: Gilles Chanteperdrix wrote: Philippe Gerum wrote: Gilles Chanteperdrix wrote: Philippe Gerum wrote: Gilles Chanteperdrix wrote: Hi, I run clocktest on a system here, not running NTP, using CONFIG_GENERIC_CLOCKEVENT, with a systematic drift of 3us/s. How can

[Xenomai-core] Clock drift.

2009-01-14 Thread Gilles Chanteperdrix
Hi, I run clocktest on a system here, not running NTP, using CONFIG_GENERIC_CLOCKEVENT, with a systematic drift of 3us/s. How can this happen? Does it come from the error due to the multiply and shift used for tsc to/from ns conversions ? TIA, --

Re: [Xenomai-core] Clock drift.

2009-01-14 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Hi, I run clocktest on a system here, not running NTP, using CONFIG_GENERIC_CLOCKEVENT, with a systematic drift of 3us/s. How can this happen? Does it come from the error due to the multiply and shift used for tsc to/from ns conversions

Re: [Xenomai-core] Clock drift.

2009-01-14 Thread Gilles Chanteperdrix
Philippe Gerum wrote: Gilles Chanteperdrix wrote: Hi, I run clocktest on a system here, not running NTP, using CONFIG_GENERIC_CLOCKEVENT, with a systematic drift of 3us/s. How can this happen? Does it come from the error due to the multiply and shift used for tsc to/from ns conversions

Re: [Xenomai-core] Oops when exiting Xenomai POSIX application

2009-01-01 Thread Gilles Chanteperdrix
Wolfgang Grandegger wrote: Hello, first a Happy New Year to everybody. With the POSIX skin of Xenomai trunk I get the following Oops when I exit my application (with ^C) on my PowerPC : Xenomai: fatal: removing non-linked element, holder=c78e69c8, qslot=c7b03030 at

Re: [Xenomai-core] Oops when exiting Xenomai POSIX application

2009-01-01 Thread Gilles Chanteperdrix
Wolfgang Grandegger wrote: Hello, first a Happy New Year to everybody. With the POSIX skin of Xenomai trunk I get the following Oops when I exit my application (with ^C) on my PowerPC : Xenomai: fatal: removing non-linked element, holder=c78e69c8, qslot=c7b03030 at

Re: [Xenomai-core] [PATCH v2 0/5] NMI watchdog fixes / enhancements

2008-12-29 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Regarding this thread, I would appreciate if we could just stay on topic. If you don't have the time for the patches, then it's absolutely OK, just leave them alone. I am reluctant to test patches which are explicitely labeled

Re: [Xenomai-core] [PATCH v2 0/5] NMI watchdog fixes / enhancements

2008-12-23 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Changes since last round: - Fix build breakage of trunk against 2.6.27 - Make rthal_nmi_release more robust (additional patch) - Fix issue of last patch on 32 bit (untested last-minute changes...) All patches are also available at git://git.kiszka.org/xenomai.git

Re: [Xenomai-core] [PATCH 0/3] NMI watchdog fixes / enhancements

2008-12-20 Thread Gilles Chanteperdrix
Jan Kiszka wrote: This is basically a repost of the NNI watchdog series I sent out a few weeks ago. I just rebased things over latest trunk and fixed some warnings. All patches are also available at git://git.kiszka.org/xenomai.git nmi-wd-queue That is a lot of stuff to review. I am afraid

Re: [Xenomai-core] [PATCH 0/3] NMI watchdog fixes / enhancements

2008-12-20 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: This is basically a repost of the NNI watchdog series I sent out a few weeks ago. I just rebased things over latest trunk and fixed some warnings. All patches are also available at git://git.kiszka.org/xenomai.git nmi-wd-queue

Re: [Xenomai-core] [PATCH 1/6] Handle priority changes of SCHED_RR tasks

2008-12-15 Thread Gilles Chanteperdrix
Jan Kiszka wrote: If shadowed Linux tasks with SCHED_RR policy change their priority, do_setsched_event currenty ignores this. Extend the condition to catch this case as well. Signed-off-by: Jan Kiszka jan.kis...@siemens.com --- ksrc/nucleus/shadow.c |2 +- 1 files changed, 1

Re: [Xenomai-core] [PATCH 3/6] POSIX: Optimize pthread_setschedparam fast path

2008-12-15 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Optimize __wrap_pthread_setschedparam without HAVE___THREAD for the case that an already mapped shadow is modifying its own scheduling parameters. Signed-off-by: Jan Kiszka jan.kis...@siemens.com --- src/skins/posix/thread.c |3 +-- 1 files changed, 1

Re: [Xenomai-core] [PATCH 3/6] POSIX: Optimize pthread_setschedparam fast path

2008-12-15 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Optimize __wrap_pthread_setschedparam without HAVE___THREAD for the case that an already mapped shadow is modifying its own scheduling parameters. Signed-off-by: Jan Kiszka jan.kis...@siemens.com --- src/skins/posix

Re: [Xenomai-core] SCHED_RR

2008-12-06 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Hi Gilles, here is a trivial test case on my desk that points to SCHED_RR issues of the POSIX skin: simple pthread_create

Re: [Xenomai-core] SCHED_RR

2008-12-05 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Hi Gilles, here is a trivial test case on my desk that points to SCHED_RR issues of the POSIX skin: simple pthread_create with an attribute block that has SCHED_RR set, but neither SCHED_RR nor the priority reach the new thread. The way the scheduling policy and

Re: [Xenomai-core] SCHED_RR

2008-12-05 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Hi Gilles, here is a trivial test case on my desk that points to SCHED_RR issues of the POSIX skin: simple pthread_create with an attribute block that has SCHED_RR set, but neither SCHED_RR nor the priority reach the new thread

Re: [Xenomai-core] SCHED_RR

2008-12-05 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Hi Gilles, here is a trivial test case on my desk that points to SCHED_RR issues of the POSIX skin: simple pthread_create with an attribute block that has SCHED_RR set

Re: [Xenomai-core] [PATCH] Mark libs with nodlopen when using initial-exec TLS

2008-11-21 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Some naive optimist once claim that the dynamic linker would detect if we try to dlopen some Xenomai lib (directly or indirectly) which uses the optimised initial-exec TLS variables. He was wrong of course. It takes the special marker nodlopen to achieve this, and that's what

Re: [Xenomai-core] nodiv xnarch_ns_to_tsc for x86-64

2008-11-21 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Hi Gilles, I assumed you armed nodiv ns-to-tsc for x86-64, given that the services are in place now. But my test case just crashed another box even though latest SVN was installed. Any reason for not converting yet? Yes, I only tested the routine performance, not tested

Re: [Xenomai-core] nodiv xnarch_ns_to_tsc for x86-64

2008-11-21 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Hi Gilles, I assumed you armed nodiv ns-to-tsc for x86-64, given that the services are in place now. But my test case just crashed another box even though latest SVN was installed. Any reason for not converting yet? Yes, I

Re: [Xenomai-core] [PATCH] Refactor management of auto-shadowing, TLS and dlopen

2008-11-21 Thread Gilles Chanteperdrix
Jan Kiszka wrote: +#ifndef CONFIG_XENO_POSIX_AUTO_MLOCKALL if (mlockall(MCL_CURRENT | MCL_FUTURE)) { perror(Xenomai Posix skin init: mlockall); exit(EXIT_FAILURE); } Errr... I do not get it, the mlockall should take place if AUTO_MLOCKALL is set, no ?

Re: [Xenomai-core] [Xenomai-commits] r4392 - /trunk/include/asm-x86/arith_64.h

2008-11-16 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Author: gch Date: Sun Nov 16 03:30:40 2008 New Revision: 4392 URL: http://svn.gna.org/viewcvs/xenomai?rev=4392view=rev Log: Implement nodiv_ullimd on x86_64 Modified: trunk/include/asm-x86/arith_64.h Nice. This solves the user

[Xenomai-core] [patch] fault mmaped area upon rtdm_mmap_to_user.

2008-11-15 Thread Gilles Chanteperdrix
Hi Jan, I have just commited a modification of the nucleus heap which allows faulting newly mapped pages. However, I noticed that we should modify rtdm_mmap_to_user as in the attached patch. At this chance, I also noticed that there is no way to ask for uncached memory to rtdm_mmap_to_user, how

Re: [Xenomai-core] llimd.

2008-10-31 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Hi Jan, I see that the implementation of rthal_llmulshft seems to account for the first argument sign. Does it work ? Namely, in the generic implementation will __rthal_u96shift propagate the sign

Re: [Xenomai-core] llimd.

2008-10-31 Thread Gilles Chanteperdrix
Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Hi Jan, I see that the implementation of rthal_llmulshft seems to account for the first argument sign. Does it work ? Namely, in the generic implementation

Re: [Xenomai-core] llimd.

2008-10-31 Thread Gilles Chanteperdrix
Gilles Chanteperdrix wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Hi Jan, I see that the implementation of rthal_llmulshft seems to account for the first argument sign. Does it work ? Namely, in the generic

Re: [Xenomai-core] llimd.

2008-10-30 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Hi Jan, I see that the implementation of rthal_llmulshft seems to account for the first argument sign. Does it work ? Namely, in the generic implementation will __rthal_u96shift propagate the sign bit ? Yes, this works (given

Re: [Xenomai-core] rtdm_mmap_to_user() remapping problem on powerpc arch.

2008-10-29 Thread Gilles Chanteperdrix
Matteo Facchinetti @ Sirius Electronic Systems S.R.L. wrote: Hi all, I'm using framework RTDM to develop my driver on embedded system mpc5200 based. (kernel 2.6.24.4 (powerpc arch) - xenomai 2.4.3). I've need to use rtdm_mmap_to_user() to share a kmalloc() kernel memory in userspace.

[Xenomai-core] llimd.

2008-10-28 Thread Gilles Chanteperdrix
Hi Jan, I see that the implementation of rthal_llmulshft seems to account for the first argument sign. Does it work ? Namely, in the generic implementation will __rthal_u96shift propagate the sign bit ? If yes, do you see a way llimd could be made to work the same way ? This way we would avoid

Re: [Xenomai-core] Comedi buffer management.

2008-10-21 Thread Gilles Chanteperdrix
Alexis Berlemont wrote: Hi Gilles, Sorry for answering so late. I was unable to regularly check my private mails the last week; I missed yours. I commited in trunk a fix of Xenomai heap management for the highmem case. What the patch does is essentially replacing __va_to_kva (which does

Re: [Xenomai-core] [PATCH 1/1] Use SIGWINCH to trigger priority change in user-space.

2008-10-20 Thread Gilles Chanteperdrix
Gilles Chanteperdrix wrote: Philippe Gerum wrote: Well, what about merging the solutions: trap the signal from the library constructor by default for people relying on #1, AND document the shadow signal handler for people who can do #2? For me, merging the two, would mean keep

Re: [Xenomai-core] [PATCH 1/1] Use SIGWINCH to trigger priority change in user-space.

2008-10-20 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Gilles Chanteperdrix wrote: Philippe Gerum wrote: Well, what about merging the solutions: trap the signal from the library constructor by default for people relying on #1, AND document the shadow signal handler for people who can do #2? For me

[Xenomai-core] Warning when compiling trunk.

2008-10-20 Thread Gilles Chanteperdrix
I get this warning when compiling trunk: checking for __thread... rm: cannot remove `conftest1.dir': Is a directory yes -- Gilles. ___ Xenomai-core mailing list Xenomai-core@gna.org

Re: [Xenomai-core] Warning when compiling trunk.

2008-10-20 Thread Gilles Chanteperdrix
Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: I get this warning when compiling trunk: checking for __thread... rm: cannot remove `conftest1.dir': Is a directory yes That simple, it's a typo in this line: http://www.rts.uni-hannover.de/xenomai/lxr/source

Re: [Xenomai-core] Warning when compiling trunk.

2008-10-20 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: I get this warning when compiling trunk: checking for __thread... rm: cannot remove `conftest1.dir': Is a directory yes That simple, it's a typo in this line: http

Re: [Xenomai-core] Warning when compiling trunk.

2008-10-20 Thread Gilles Chanteperdrix
Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: I get this warning when compiling trunk: checking for __thread... rm: cannot remove `conftest1.dir': Is a directory yes That simple, it's

Re: [Xenomai-core] Warning when compiling trunk.

2008-10-20 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: I get this warning when compiling trunk: checking for __thread... rm: cannot remove `conftest1

Re: [Xenomai-core] Warning when compiling trunk.

2008-10-20 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: I get this warning when compiling trunk

Re: [Xenomai-core] Warning when compiling trunk.

2008-10-20 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Well I am busy with the ARM FCSE now. Do you want my test case ? Yes, hoping that it triggers on x86 as well. And is toolchain independent. -- Gilles. #include stdio.h #include sys/mman.h #include

Re: [Xenomai-core] Warning when compiling trunk.

2008-10-20 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Well I am busy with the ARM FCSE now. Do you want my test case ? Yes, hoping that it triggers on x86 as well. And is toolchain independent. It doesn't trigger. Can you reproduce on x86? I think

Re: [Xenomai-core] Warning when compiling trunk.

2008-10-20 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Well I am busy with the ARM FCSE now. Do you want my test case ? Yes, hoping that it triggers on x86 as well. And is toolchain independent. It doesn't trigger. Can you reproduce on x86? Beware, I

Re: [Xenomai-core] [PATCH 1/1] Use SIGWINCH to trigger priority change in user-space.

2008-10-19 Thread Gilles Chanteperdrix
Jan Kiszka wrote: I wonder if we shouldn't switch the signal hooking strategy: So far we install the handler at shadow thread creation time, saving a potentially installed handler of the application for redirection of Xenomai-unrelated events. But that only works if the application installed

Re: [Xenomai-core] [PATCH 1/1] Use SIGWINCH to trigger priority change in user-space.

2008-10-19 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: I wonder if we shouldn't switch the signal hooking strategy: So far we install the handler at shadow thread creation time, saving a potentially installed handler of the application for redirection of Xenomai-unrelated events

Re: [Xenomai-core] [PATCH 1/1] Use SIGWINCH to trigger priority change in user-space.

2008-10-19 Thread Gilles Chanteperdrix
Gilles Chanteperdrix wrote: Gilles Chanteperdrix wrote: Hi, here is a patch which implements the idea discussed previously of re-using SIGWINCH to trigger priority changes in user-space. There is only one patch, but the files should have been put in a logical order to make review easier

Re: [Xenomai-core] [PATCH 1/1] Use SIGWINCH to trigger priority change in user-space.

2008-10-19 Thread Gilles Chanteperdrix
Philippe Gerum wrote: Philippe Gerum wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: I wonder if we shouldn't switch the signal hooking strategy: So far we install the handler at shadow thread creation time, saving a potentially installed

Re: [Xenomai-core] [PATCH 1/1] Use SIGWINCH to trigger priority change in user-space.

2008-10-19 Thread Gilles Chanteperdrix
Philippe Gerum wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: I wonder if we shouldn't switch the signal hooking strategy: So far we install the handler at shadow thread creation time, saving a potentially installed handler

[Xenomai-core] [PATCH 1/1] Use SIGWINCH to trigger priority change in user-space.

2008-10-18 Thread Gilles Chanteperdrix
Hi, here is a patch which implements the idea discussed previously of re-using SIGWINCH to trigger priority changes in user-space. There is only one patch, but the files should have been put in a logical order to make review easier. Index: include/nucleus/thread.h

Re: [Xenomai-core] [PATCH 1/1] Use SIGWINCH to trigger priority change in user-space.

2008-10-18 Thread Gilles Chanteperdrix
Gilles Chanteperdrix wrote: Hi, here is a patch which implements the idea discussed previously of re-using SIGWINCH to trigger priority changes in user-space. There is only one patch, but the files should have been put in a logical order to make review easier. Since there are chances

Re: [Xenomai-core] [PATCH 00/13] Generic fast xnsynch support more

2008-10-18 Thread Gilles Chanteperdrix
Jan Kiszka wrote: PS: Hope this series is compatible with more mail clients /wrt commenting on the inlined patches. I tested and it is true I could reply to your patches. However, your mailer does not put any Content-type of Content-encoding info. This may be a problem for some. --

Re: [Xenomai-core] [PATCH 08/12] Use fast xnsynch with native skin

2008-10-17 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Same remark for the #ifdefs. Yes, but most cases (maybe except for owner checking) are unavoidable due to heavy differences. I hope that we may have only FASTXNSYCH archs one day. I also do not understand your modification

Re: [Xenomai-core] [PATCH 08/12] Use fast xnsynch with native skin

2008-10-17 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Same remark for the #ifdefs. Yes, but most cases (maybe except for owner checking) are unavoidable due to heavy differences. I hope that we may have only FASTXNSYCH archs one day

Re: [Xenomai-core] [PATCH 08/12] Use fast xnsynch with native skin

2008-10-17 Thread Gilles Chanteperdrix
Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Same remark for the #ifdefs. Yes, but most cases (maybe except for owner checking) are unavoidable due to heavy differences. I hope that we may have

Re: [Xenomai-core] [PATCH 08/12] Use fast xnsynch with native skin

2008-10-17 Thread Gilles Chanteperdrix
Jan Kiszka wrote: But that is what cond_wait is about: releasing the associated lock to whoever gets it - either directly or via lock-stealing. I see no problem here. Moreover, lockcnt is never used (and must not!) as an indication if a lock is free. It is a pure helper for the lock owner to

Re: [Xenomai-core] [PATCH 00/12] Generic fast xnsynch support more

2008-10-17 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Here comes a significantly reworked patch series to improve fast mutex support of Xenomai. This approach now introduces a generic fast xnsynch core and converts the existing POSIX implementation over. It also comes with a second user, the Native skin. Additionally, it

Re: [Xenomai-core] [PATCH 00/13] Generic fast xnsynch support more

2008-10-17 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Hopefully the last round, addressing remarks brought up on the last posting. The changes are: [Patches 7-9] - define xnsynch_owner_check as xnsynch-implementation-independent way to check provided and current synch owner match (reduces #ifdefs) [Patches 6 and 9] -

Re: [Xenomai-core] [PATCH 0/2] Fix and improve task/thread inquire services

2008-10-16 Thread Gilles Chanteperdrix
Jan Kiszka wrote: This series fixes the issues around rt_task_inquire I posted yesterday. Additionally, it introduces an analogous services pthread_inquire_np for the POSIX skin. That allows, among other things, to implement test cases for the upcoming fast xnsynch/mutex patches. Ok. Since

Re: [Xenomai-core] [PATCH 00/12] Generic fast xnsynch support more

2008-10-16 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Here comes a significantly reworked patch series to improve fast mutex support of Xenomai. This approach now introduces a generic fast xnsynch core and converts the existing POSIX implementation over. It also comes with a second user, the Native skin. Additionally, it

Re: [Xenomai-core] [PATCH 02/12] Handle-based xeno_get_current service

2008-10-16 Thread Gilles Chanteperdrix
Jan Kiszka wrote: ok for me. -- Gilles. ___ Xenomai-core mailing list Xenomai-core@gna.org https://mail.gna.org/listinfo/xenomai-core

Re: [Xenomai-core] [PATCH 03/12] Remove xnarch_atomic_intptr

2008-10-16 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Ok. -- Gilles. ___ Xenomai-core mailing list Xenomai-core@gna.org https://mail.gna.org/listinfo/xenomai-core

Re: [Xenomai-core] [PATCH 04/12] Spread xeno_set_current under all skins

2008-10-16 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Ok. -- Gilles. ___ Xenomai-core mailing list Xenomai-core@gna.org https://mail.gna.org/listinfo/xenomai-core

Re: [Xenomai-core] [PATCH 05/12] Factor out xnsynch_acquire/release

2008-10-16 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Ok. -- Gilles. ___ Xenomai-core mailing list Xenomai-core@gna.org https://mail.gna.org/listinfo/xenomai-core

Re: [Xenomai-core] [PATCH 06/12] Lockless fast path for xnsynch_acquire/release

2008-10-16 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Ok. Though I do not see the point of the FASTSEM/FASTSYNCH rename. FASTSEM is short, and we are not much interested in getting anything else than semaphores faster. -- Gilles. ___

Re: [Xenomai-core] [PATCH 07/12] Convert POSIX skin to fast xnsynch

2008-10-16 Thread Gilles Chanteperdrix
Jan Kiszka wrote: This patch contains too many #ifdefs. Things like #ifdef CONFIG_XENO_FASTSYNCH if (xnsynch_fast_owner_check(...)) #else if (xnsynch_owner(...) == ...) #endif could be replaced with only one macro xnsynch_check_owner in synch.h that would be defined with some #ifdefs, and used

Re: [Xenomai-core] [PATCH 08/12] Use fast xnsynch with native skin

2008-10-16 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Same remark for the #ifdefs. I also do not understand your modification of rt_cond_wait_inner, this code is very tense; posix and native had the same bug in this area at different times, so this change should probably be made separately. --

Re: [Xenomai-core] [PATCH 09/12] Optionally replace pthread_getspecific with TLS variables

2008-10-16 Thread Gilles Chanteperdrix
Jan Kiszka wrote: The real downside here is a lot of #ifdef clutter. What about the idea of defining an API to abstract the differences between pthread_get/setspecific and __thread and have #ifdef only in one header ? -- Gilles.

Re: [Xenomai-core] [PATCH 10/12] Report current shadow thread mode to user space

2008-10-16 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Ok. I still liked the solution of using a piece of shared heap. This was more general and would have allowed us to use this piece of shared heap for future purposes. -- Gilles. ___

Re: [Xenomai-core] [PATCH 11/12] Ensure mode switch in mutex fast paths

2008-10-16 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Ok. -- Gilles. ___ Xenomai-core mailing list Xenomai-core@gna.org https://mail.gna.org/listinfo/xenomai-core

Re: [Xenomai-core] [PATCH 12/12] Enable SMP support for user libs by default

2008-10-16 Thread Gilles Chanteperdrix
Jan Kiszka wrote: I do not like this patch. This sould be solved using the existing features system. I do not want SMP to be enabled by default. -- Gilles. ___ Xenomai-core mailing list Xenomai-core@gna.org

Re: [Xenomai-core] rt_task_info.status encoding

2008-10-16 Thread Gilles Chanteperdrix
Jan Kiszka wrote: I start to believe we are arguing with different (miss-)use case in mind. Mine is definitely not about helping the user to switch the thread mode even more actively. It is about validating application states, it is about thread state reflection without any other actions than

Re: [Xenomai-core] [PATCH 06/12] Lockless fast path for xnsynch_acquire/release

2008-10-16 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Ok. Though I do not see the point of the FASTSEM/FASTSYNCH rename. FASTSEM is short, and we are not much interested in getting anything else than semaphores faster. We aren't

Re: [Xenomai-core] rt_task_info.status encoding

2008-10-15 Thread Gilles Chanteperdrix
Philippe Gerum wrote: Jan Kiszka wrote: Hi, the documentation refers to the Native Task Status (T_*) when it comes to documenting rt_task_info.status. That is not correct. That field contains far more flags than T_* is describing and, even worse, comes with two collisions: T_PRIMARY and

Re: [Xenomai-core] __thread instead of pthread_get/setspecific

2008-10-14 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Hi, looking into the xeno_in_primary_mode thing I wondered how to make the thread state quickly retrievable. Going via pthread_getspecific as we do for xeno_get_current appears logical - but not optimal. Though getspecific is optimized for speed, it remains a function

Re: [Xenomai-core] __thread instead of pthread_get/setspecific

2008-10-14 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: It will always remain orders of magnitude heavier than __thread variables which are a) inlined and b) should only need two memory accesses at worst. Moreover, it is clearly

Re: [Xenomai-core] __thread instead of pthread_get/setspecific

2008-10-14 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: It will always remain orders of magnitude heavier than __thread variables which are a) inlined and b) should only need two memory

Re: [Xenomai-core] __thread instead of pthread_get/setspecific

2008-10-14 Thread Gilles Chanteperdrix
Jan Kiszka wrote: So if I get an OK for the proposal, I'll convert the rest, too. From my point of view, it really is a micro-optimization, which uselessly clutters code and configure script. But I really have no concrete objection, especially since you say that __thread is the future, not

Re: [Xenomai-core] __thread instead of pthread_get/setspecific

2008-10-14 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Ack. There are rt_printf (rtdk) and the task-self services of vxworks, vrtx and native skins. So if I get an OK for the proposal, I'll convert the rest, too. And I really do not understand how the keys can be chosen at compilation-time, especially in the situation where

Re: [Xenomai-core] __thread instead of pthread_get/setspecific

2008-10-14 Thread Gilles Chanteperdrix
Jan Kiszka wrote: Gilles Chanteperdrix wrote: Jan Kiszka wrote: It will always remain orders of magnitude heavier than __thread variables which are a) inlined and b) should only need two memory accesses at worst. Moreover, it is clearly the future, while the importance of pthread_getspecific

<    3   4   5   6   7   8   9   10   11   12   >