Boost C++ Libraries: Ticket #3325: Limited support for mapping regions to specific addresses in Linux https://svn.boost.org/trac10/ticket/3325 <p> Hi, </p> <p> Changeset 3098 removed the use of MAP_FIXED when an address was provided to boost::mapped_region's constructor. I have a use-case where I need to construct a partially overlapping set of memory mappings. Without MAP_FIXED, on Linux mmap() doesn't use my address hint (because of the overlap) and my use-case fails. </p> <p> I have read the short debate about the use of MAP_FIXED being dangerous and support being withdrawn and I'd like to challenge the conclusion: </p> <p> 1) Overlapping mmap's are part of a pattern for implementing a poor mans circular addressing on platforms that don't support that. Currently this pattern is ruled out. </p> <p> 2) Whilst some might cut themselves with the sharp knife of overlapping mmaps, that isn't in a sufficient reason to remove a feature supporting legitimate use-cases. </p> <p> I've patched this locally for my purposes. Perhaps we need an additional flag to turn on support for overlapping mmaps (where this exists - which isn't Windows)? </p> <p> I've flagged this as a Showstopper as I would not be able to complete my solution without the patch I've put in place. </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/3325 Trac 1.4.3 Andy Schneider <andrew.schneider@…> Fri, 07 Aug 2009 16:49:38 GMT <link>https://svn.boost.org/trac10/ticket/3325#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/3325#comment:1</guid> <description> <p> Another solution would be to separate out the mapping action from some 'reserve virtual address range' function. That would allow you to reserve a virtual address range and then map a file into that without explicitly having an overlapping mmap exposed in the API. It'd solve one of the patterns for using overlapping mappings on Linux. It's not fully general though. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Steven Watanabe</dc:creator> <pubDate>Sat, 08 Aug 2009 19:22:21 GMT</pubDate> <title>component changed; owner set https://svn.boost.org/trac10/ticket/3325#comment:2 https://svn.boost.org/trac10/ticket/3325#comment:2 <ul> <li><strong>owner</strong> set to <span class="trac-author">Ion Gaztañaga</span> </li> <li><strong>component</strong> <span class="trac-field-old">None</span> → <span class="trac-field-new">interprocess</span> </li> </ul> Ticket Ion Gaztañaga Thu, 26 Aug 2010 11:38:20 GMT status changed; resolution set https://svn.boost.org/trac10/ticket/3325#comment:3 https://svn.boost.org/trac10/ticket/3325#comment:3 <ul> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">wontfix</span> </li> </ul> <p> For portability MAP_FIXED won't be supported. </p> Ticket