From: Philippe Gerum <rpm@xenomai.org>
To: Roderik.Wildenburg@domain.hid
Cc: xenomai@xenomai.org
Subject: Re: [Xenomai-help] rt_queue_write error: "Cannot allocate memory "; bug or feature ?
Date: Tue, 20 Nov 2007 14:59:07 +0100 [thread overview]
Message-ID: <4742E82B.1040000@domain.hid> (raw)
In-Reply-To: <5D63919D95F87E4D9D34FF7748CE2C2AE092AC@ARVMAIL1.mra.roland-man.biz>
Roderik.Wildenburg@domain.hid wrote:
>> No more than one block is allocated at any given time in your example.
>> This is expected due to the priority scheme your test
>> undergoes. In any
>> case, 282 bytes (+ a few bytes message header) should grab
>> one 512-byte
>> buffer here. For anything below the size of a logical page (4k in
>> 2.3.x), the allocator picks the next power of 2 greater or
>> equal to the
>> requested size.
>
> Is it possible that a allocated block remembers the size he is allocated
> for
> and that the block is just usable for this size even after the block is
> freed ?
>
The block will belong to a 512-byte pool until all the blocks from the
same pool are free, in which case the entire page the pool sits on will
be moved to a free page list, and recycled for blocks of any size.
>> What if you don't set any limit to the queue elements, i.e. passing
>> Q_UNLIMITED instead of 10. Does this change the behaviour?
>>
>
> This does not help. What helps is increasing the queue size to e.g.
> MAXLEN*100 = 200000
> (rt_queue_create(&qtest1q, "qtest1q", MAXLEN*100, Q_UNLIMITED, Q_FIFO))
>
> Could you please try to run my example on your machine, or are you
> shure, that this
> problem is specific to our platform ? Thank you for your help !
This is likely not a platform specific issue. You may want to run your
small test on v2.4-rc6 on your side.
>
> Best regards
> Roderik
>
> MAN Roland Druckmaschinen AG
> Vorsitzender des Aufsichtsrates: Hanno C. Fiedler
> Vorstand: Gerd Finkbeiner (Vorsitzender), Dr. Ingo Koch, Dr. Markus Rall, Paul Steidle
> Sitz der Gesellschaft: Offenbach am Main, Registergericht: Amtsgericht Offenbach HRB-Nr. 42592
> USt-Ident-Nr. DE 250200933
>
--
Philippe.
next prev parent reply other threads:[~2007-11-20 13:59 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-11-19 13:43 [Xenomai-help] rt_queue_write error: "Cannot allocate memory "; bug or feature ? Roderik.Wildenburg
2007-11-19 14:35 ` Philippe Gerum
2007-11-19 15:11 ` Roderik.Wildenburg
2007-11-19 18:06 ` Philippe Gerum
2007-11-20 8:51 ` Roderik.Wildenburg
2007-11-20 13:59 ` Philippe Gerum [this message]
2007-11-21 14:07 ` Roderik.Wildenburg
2007-11-23 17:08 ` Philippe Gerum
2007-11-28 9:21 ` Roderik.Wildenburg
2007-11-28 9:43 ` Philippe Gerum
2007-11-28 10:05 ` Roderik.Wildenburg
2007-11-28 10:22 ` Philippe Gerum
-- strict thread matches above, loose matches on Subject: below --
2007-11-28 13:03 Roderik.Wildenburg
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4742E82B.1040000@domain.hid \
--to=rpm@xenomai.org \
--cc=Roderik.Wildenburg@domain.hid \
--cc=xenomai@xenomai.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.