|
|
您好, 在使用OMAPL138 evm过程中,我使用了MessageQ和ringIO来传输数据。利用ipcs -l ,情况如下:
1 o) m" g# y# U& o, n1 Vroot@tl:~# ipcs -l
. E% Z% V, T8 f+ R
|& p9 E; i- U1 `( P3 Q* w U! P------ Shared Memory Limits --------
! _+ z. _, T+ R r2 tmax number of segments = 4096
# y8 a; } K3 Z6 z8 F) {; U* v# k) jmax seg size (kbytes) = 327688 M7 k Y$ a8 L) d$ f6 G: O8 P% k* R1 s
max total shared memory (kbytes) = 8388608
8 S; k) h: y8 B5 l) K/ H5 O' ?min seg size (bytes) = 1% Q, R* J. p- W7 C) ?7 d" N
& p2 }% w2 E% t' w$ c7 C------ Semaphore Limits --------5 T5 s5 X1 ]2 ?: \0 v0 h# ]) K# m
max number of arrays = 1281 h/ J$ R Z+ e) u# ?
max semaphores per array = 2504 d- ~' S3 u- u$ m: {; x5 Z C" d
max semaphores system wide = 32000
0 j2 E5 ?( V- b' p3 z* emax ops per semop call = 322 e* G, c( Y- }! H0 a: `! ^( t
semaphore max value = 32767- e; J7 @1 L3 J6 m% Q# |4 g
7 L% c! p. L. }4 l
------ Messages Limits --------$ ^ {: \6 @- R" @' ]
max queues system wide = 178 s4 C6 |9 R0 Z! j" Y* _
max size of message (bytes) = 81923 S' S% u3 ]1 F3 v
default max size of queue (bytes) = 16384! }7 R: @4 G0 L
6 ^1 q9 M8 j% E% `
) l! l. J8 [3 N1 {6 X* [, e* @) L但是,用ipcs -a 1 S7 q& E/ o- W2 ?9 S6 c
root@tl:~# ipcs -a0 ]4 V! Y6 i/ p& o# R# d1 V% j- U
9 [" R8 }1 ^# T( F3 q
------ Shared Memory Segments --------
$ V/ @0 g5 c4 P9 rkey shmid owner perms bytes nattch status + A: M, V' ~" T- [' o" t; Z. |
0x00000000 0 root 600 1024 1 dest
4 d3 X. ^* C8 c$ g0x00000000 196609 root 600 1024 1 dest , n1 S* g" n5 U. { ?; i$ f
7 J$ Y, p1 t6 L$ ?6 l, N! H------ Semaphore Arrays --------
. C L6 V% M1 S% _ H4 v( y8 ^& jkey semid owner perms nsems
% z0 |+ Z. U# c& t0x6411074d 0 root 600 1 " g4 Y2 v8 |3 V" j
0x64110957 163841 root 600 1 : Q" a F* [& \1 x. T
0x641109a1 196610 root 600 1
c) u$ y: J8 L( x: M. Z& g0 f+ \" I* a, I& Y! ~0 g
------ Message Queues --------
( U) U2 J4 B& E6 ?key msqid owner perms used-bytes messages 0 l9 V- }8 i a* a5 j
7 E# Y' S( L2 }& k
9 Z: Y4 A7 n3 X$ y4 s/ G
请问,我的共享内存使用大小为 (float *)ring_buffer_acquired(ad->buffer, 2320 * sizeof(float)*18); 远大于1024BYTE ,请问为什么?
- ?3 |% `5 v5 z: O6 T
) Z. W5 E! @ r( ? |
|