> : So the best way is the way how did you suggested. Anyway is there a performance
> : factor to use unsigned char versus unsigned int ? I believe to remember that
> : one should use basic types (int and double) on performance programs ? Any
> : experience? I compiled the kernel program (written in C) with -align-double etc.
>
> The perfomance difference not so significant, rewriting critical paths in
> asm is more effective usually. It should be noted that using
> -malign-double option can lead to different struct fields aligning, even
> in the same app.
Oh dear... Can I avoid this by using
typedef struct {
flag_t inuse;
flag_t valid;
double um[65536]
} __attribute__ ((aligned)) shm_slut_t;
??? Is it guarantee that all structures (inside shm, inside local static copy,
inside kernel space code produced by Gnu-C and user space program compiled by
Gnu-C++) have the same aligment - even if compiled with the Option
-align-double? Or could I use an explizit __attribute__ ((aligned (size))) .
Which is a good size for those structures ??? __attribute__((packed)) is the
safest way at moment, because they didn't have any aligment (I have have right
read the gcc-info) but, it's a performance killer and I live from loock up
tables (LUT) and performance (it's a controller task for magnetic bearing).
Thanks Olaf
-- [rtl] ---
To unsubscribe:
echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR
echo "unsubscribe rtl <Your_email>" | mail [EMAIL PROTECTED]
---
For more information on Real-Time Linux see:
http://www.rtlinux.org/rtlinux/