I am looking to port a utility to Ruby.  The problem is that
it must read large amounts of binary data from a file (or
possibly socket or pipe) into an array at frequent intervals,
and then update a GUI representation of the array.

The array has on the order of 5000 - 50,000 items (fixed
for each use of the utility).  The items are each records
with three 32-bit integers and two 16-bit integers.  The
array is refreshed from the file/pipe/socket at a user-
settable interval which is typically under 20 seconds.
(The file is undergoing constant updating by the Operating
System, in my case NetBSD).

I have the utility written in Tcl/Tk but it just barely 
meets the performance requirements and is difficult to
extend and modify.  Ruby looks like it might be just
the thing, if I could find answers to these issues:

1)  Are there packages/extensions/modules available
    for reading large amounts of binary data into arrays
    of structures?  I know that binary data can be read
    a "char" at a time, but this is likely to be too
    slow.

2)  What is the best library to use to get fastest
    performance in displaying a large array of data?
    (Each element of the array is displayed as a small
    bar of different size and color). I recall reading 
    somewhere that gtk was faster than Tk.  Is this true?

Thank you for help with either problem.  I am looking 
forward to programming in Ruby.

  --Dwight Tuinstra
    tuinstra / clarkson.edu