Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 1 Dec 1997 16:49:52 -0500 (EST)
From:      "John S. Dyson" <toor@dyson.iquest.net>
To:        nate@mt.sri.com (Nate Williams)
Cc:        toor@dyson.iquest.net, nate@mt.sri.com, current@FreeBSD.ORG
Subject:   Re: FYI: usage of new AIO calls
Message-ID:  <199712012149.QAA05084@dyson.iquest.net>
In-Reply-To: <199712012129.OAA12636@mt.sri.com> from Nate Williams at "Dec 1, 97 02:29:57 pm"

next in thread | previous in thread | raw e-mail | index | archive | help
Nate Williams said:
> > > > > What is a VCHR device?  You mention it quite a lot in the commit
> > > > > messages, but I have no idea what it is, unless it's like a acronym
> > > > > cross combining VHS and VCR. :)
> > > >
> > > > RAW disk I/O is an example.
> > > 
> > > But, what is it?  Raw disk I/O is an example of many things unrelated to
> > > VCHR, so telling me an example of something still doesn't tell me what a
> > > VCHR device is.
> >
> > I am surprised, do you really not know?
> 
> I really don't know what VCHR is.  I know what raw disk I/O is, but raw
> disk I/O is an example of many things, so I want to know precisely what
> VCHR is, not what are examples of it.
> 
> Example, if you didn't know what Nate's new acronym 'DSM' was, and I
> said "floppy disks are an example of it", you still wouldn't know what
> it was.  It could be a form-factor, a type of controller, or any number
> of things.  Giving an example of something that is 'VCHR' doesn't
> explain what VCHR is.
> 
> 
Okay, well it wasn't invented by me.  Take a look at the headers in
/sys/sys and the VFS code in /sys/kern.  VCHR files are character devices
that you would see the 'c' in the first column for 'ls -l'.  VCHR takes alot
less to type than 'character devices or files', and alot less ambiguous.  It
is of course, possible to have a VCHR device without a directory entry for
it...

If I use the term character devices, or character files, I can imagine
significant ambiguity or confusion.  (For me, the descriptive terms require
significant interpretation of associated text to figure out exactly what is
being said.)  It is easier and more accurate to use the specific
internal terminology.

If you know what the AIO/LIO functions are for, and have software that
can use them, it is pretty clear how useful they are.  (Note that I
didn't realize how useful they are until about a year ago, so if you
don't know -- don't feel bad.)  They are very very important for database
performance, and are one way to help a system work well in that application.

The code that I posted earlier is an example that can be used to write
in a multiply buffered fashion to a tape backup device (another VCHR
device.)

This mechanism allows for true multiple buffered I/O for all file descriptors
without the bogus historical hacks used on earlier U**X clone implementations.
Many commercial UNIX's have had this for a while.

-- 
John
dyson@freebsd.org
jdyson@nc.com



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199712012149.QAA05084>