fmII
Sun, Jul 27th home | browse | articles | contact | chat | submit | faq | newsletter | about | stats | scoop 01:23 UTC
in
Section
login «
register «
recover password «
[Project] add release | add branch | add screenshot | broken links | change owner | email subscribers | update project | update branch (urls) [Project]

 Virtual Ring Buffer - Default branch
Section: Unix

 

Added: Sat, Mar 3rd 2001 11:05 UTC (7 years, 4 months ago) Updated: Mon, Mar 6th 2006 22:35 UTC (2 years, 4 months ago)


About:
The VRB library is a virtual ring buffer. It uses 2 mirrored ranges of memory to avoid most needs to check for buffer wraparound. This allows the caller to have direct access to buffer space and buffer data as a linear contiguous block.

Author:
Phil Howard <vrb __at__ ipal __dot__ org> [contact developer]

Rating:
(not rated)

Homepage:
http://vrb.slashusr.org/
Changelog:
http://vrb.slashusr.org/ChangeLog.txt
Mirror site:
http://vrb.sourceforge.net/

Trove categories: [change]
[Development Status]  4 - Beta
[Intended Audience]  Developers
[License]  OSI Approved :: GNU Lesser General Public License (LGPL)
[Operating System]  POSIX
[Programming Language]  C
[Topic]  Software Development :: Libraries

Dependencies: [change]
No dependencies filed

 
Project admins: [change]
» Phil Howard (Owner)

» Rating: (not rated)
» Vitality: 0.00% (Rank 9174)
» Popularity: 0.58% (Rank 10127)

project statsdownload stats
(click to enlarge graphs)
   Record hits: 6,822
   URL hits: 3,897
   Subscribers: 11

Other projects from the same categories:
Pluggable Identification Modules
NSFileHandleExt
LCD / LCD::MatrixOrbital
TipRPC
Oracle Reports Barcode PLL

Users who subscribed to this project also subscribed to:
rsync
Paper Harbour
The Global File System
nagios-check_apt
Node Director


Add comment · Rate this project · Subscribe to new releases · Ignore this project · Email this project to a friend · Project record in XML

 Branches

Branch Version Last release License URLs
Default 0.5.0 07-Mar-2006 GNU Lesser General Public License (LGPL) Homepage Changelog

 Comments

[»] Virtual ring buffer
by Warren Dale - Nov 18th 2001 19:24:09

SMALL BUG 1
-----------
File vrb_init.c line 255:
if ( ! ( tempname = alloca( strlen( arg_name ) ) ) ) {
Surely this should be:
if ( ! ( tempname = alloca( strlen( arg_name ) + 1 ) ) ) {

SMALL BUG 2
-----------
File vrb_prefix.h line 201:
#define vrb_is_full(b) (((b)->length)==((b)->capacity))
You probably meant:
#define vrb_is_full(b) ((vrb_data_len((b)))==((b)->capacity))

CLARIFICATION
-------------
In vrb_init.c when (arg_name == NULL) you need to make two shmat() calls, and you require that the return addresses are exactly "req_size" bytes apart.
Why do you do you first make a mmap() call and then an mummap() call?
Does that -really- enhance your chances?
Will you necessarily get the same address as that from mmap()?

[reply] [top]


    [»] Re: Virtual ring buffer
    by Phil Howard - Dec 10th 2001 05:57:30

    If the calls to shmat() are made with the address (arg 2) specified as 0, the system will find an "unmapped" region of address space. There is no guarantee it will place the mapping of 2 such calls together, as VRB needs. Only by specifying an exact address can this be guaranteed. And in order to know what such addresses should be, mmap() is called initially to find an opening in the address space of the proper size (twice the buffer need).

    The 2 bugs have now been corrected in the latest release, 0.3.0 (beta).

    [reply] [top]




© Copyright 2008 SourceForge, Inc., All Rights Reserved.
About freshmeat.net •  Privacy Statement •  Terms of Use •  Trademark Guidelines •  Advertise •  Contact Us • 
ThinkGeek •  Slashdot  •  Linux.com •  SourceForge.net  •  Jobs