[ENH] B3D Acceleration for X

Bert Freudenberg bert at isg.cs.uni-magdeburg.de
Sun May 20 12:22:37 UTC 2001


On Sat, 19 May 2001, Greg A. Woods wrote:

> [ On Sunday, May 20, 2001 at 02:30:29 (+0200), Bert Freudenberg wrote: ]
> > Subject: [ENH] B3D Acceleration for X
> >
> > this is the X specific part for Andreas' new B3DAcceleratorPlugin.
>
> I can't wait to try it!

Then go ahead! ;-)

> > When you compiled it (extract into src dir, configure, make), put
> > B3DAcceleratorPlugin.so into the current directory where you start Squeak
> > from.  The VM is lacking two exports so you need to change
> > platform.exports before compiling a new VM (see NOTES). See Squeak3D.log
> > for errors.
>
> Not having done much with the Squeak VM under unix yet (other than debug
> and fix a problem in the 3.0pre2 w.r.t. 8-bit displays), I don't yet
> know anything about these runtime loadable modules.  The one I'm running
> on NetBSD is just one program, no .so's (though it's linked dynamically
> with the system and X11 libraries).
>
> However I'm really reluctant to use runtime loadable modules in other
> things so I'm thinking I might be best to avoid them in Squeak too.

I figured it might be better to not have the VM itself depend on OpenGL.
Also, for debugging it's way easier with an external module - I don't need
to restart the VM but just compile the external module, do
	Smalltalk unloadModule: 'B3DAcceleratorPlugin'
and it gets reloaded on next use. Very handy.

> What's involved with just linking these things directly into the VM
> binary if I want to?  This is a modern Unix, after all, with dynamic
> text paging and all that so a loadable module is only going to slow
> things down anyway....

I don't think it is a noticable slow-down: after all, the VM loads a
couple of shared libs anyway (libc, libm, libX11, libXext, libdl, libnsl).
That said, I, too, like a single executable better than one that needs a
bunch of shared libraries.

To compile it internally, the only thing needed should be to include the
B3DAcceleratorPlugin into the list of internal modules when generating a
new VM. It might be necessary to put all the files from the
B3DAcceleratorPlugin directory into the src/unix or src/generated
directory. And you have to dynamically link libGL into the VM - put
something like "AC_CHECK_LIB(GL, glBegin)" into configure.in.

-- Bert





More information about the Squeak-dev mailing list