[Vm-dev] SmalltalkeImage current listLoadedModules (i) and (e) refers to Internal and External modules.

David T. Lewis lewis at mail.msen.com
Sat Nov 9 23:27:16 UTC 2013


On Sat, Nov 09, 2013 at 02:21:51PM -0800, gettimothy wrote:
>  
> is my assumption that (i) and (e) from the listLoadedModules refer to Internal and External ?
> 
> 
> SmalltalkImage current listLoadedModules asSortedCollection: [:a :b | a < b] 
>  a SortedCollection(
> 'B2DPlugin VMMaker.oscog-eem.69 (i)' 
> 'BitBltPlugin VMMaker.oscog-eem.115 (i)' 
> 'CroquetPlugin VMMaker-oscog.40 (i)'   <<post VMMaker
>  'FilePlugin VMMaker.oscog-eem.97 (i)' 
> 'FloatArrayPlugin VMMaker-oscog.40 (i)' 
> 'FloatMathPlugin VMMaker-oscog.40 (i)' <<post VMMaker 
> 'IA32ABI VMMaker.oscog-eem.99 (i)' 
> 'JPEGReadWriter2Plugin VMMaker-oscog.40 (i)'   <<post VMMaker
>  'LargeIntegers v1.5 VMMaker.oscog-eem.72 (i)'
>  'Matrix2x3Plugin VMMaker-oscog.40 (i)' 
> 'MiscPrimitivePlugin VMMaker-oscog.40 (i)' 
> 'SecurityPlugin VMMaker-oscog.40 (i)' 
> 'SocketPlugin VMMaker-oscog.40 (i)'
>  'SoundPlugin VMMaker-oscog.54 (i)'
>  'UUIDPlugin VMMaker-oscog.47 (e)' 
> 'ZipPlugin VMMaker-oscog.40 (i)')
> 

Yes, that's exactly right. In most cases, a plugin may be compiled either as
an internal plugin or an external plugin, and the same source code is used in
either case. When compiled as an internal plugin, a plugin is linked directly
into the VM executable. When external, it is a separate shared library or dll
file that is loaded on demand when something in the image tries to use a
primitive in the plugin.

> If I do 
> SmalltalkImage current listBuiltinModules asSortedCollection: [:a :b | a < b]  
> all the results have an (i). 
> 

Right. These are internal plugins that are available directly in the VM executable.
In contrast, the UUIDPlugin (which is an external plugin in this example) shows
up in the listLoadedModules because something in the image has created a new UUID
instance, and the VM loaded the UUIDPlugin in order to find the necessary primitive
for creating it.

Dave



More information about the Vm-dev mailing list