[Vm-dev] Re: "missing" exports on the windows vm

Nicolai Hess nicolaihess at web.de
Sat Sep 12 22:07:25 UTC 2015


2015-05-21 20:35 GMT+02:00 Nicolai Hess <nicolaihess at web.de>:

>
>
> 2015-05-06 0:11 GMT+02:00 Nicolai Hess <nicolaihess at web.de>:
>
>> We have a failing test case for NB
>> NBInterpreterProxyTest>>#testStackPointer
>> it fails because
>> NativeBoost loadSymbol: 'stackPointerAddress' fromModule: NativeBoost
>> VMModule
>> returns nil
>>
>> This works for the linux vm!
>>
>> There are other methods that can be loaded, for example:
>> (NativeBoost loadSymbol: 'primitiveAllObjects' fromModule: NativeBoost
>> VMModule)
>> -> returns an address.
>>
>> This stopped working for the windows pharo vm around june 2014. The
>> source that
>> changed is cointerp.h, the prior version had EXPORT(...) declarations
>> around all
>> functions in cointerp.h, the current version not.
>>
>> Three questions:
>>
>> 1. Why does this still work on linux? Does it export all functions
>> declared in
>>     a header?
>> 2. why was it changed? (I could not found the change in the code
>> generator, maybe we
>>    exported all functions with pragma #api and now only those with pragma
>> #export ?
>> 3. do we need this function to be exported? Apart from this testcases,
>> this method is
>>  called the on image startup, but the nil return does not harm.
>>  It seems it is not part of the main vm api (like the interpreter proxy
>> functions callable from external modules) and I didn't see code thet depend
>> on this.
>>
>> There are similiar functions for which we load the function address on
>> startup:
>>  cStackPointerAddress and cFramePointerAddress, this seems to work, but I
>> don't know if the       expected result is different.
>>
>> In NBInterpreterProxy>>#initialize, we try to load all fourmethods:
>> stackPointerAddress/framePointerAddress -> nil
>> cStackPointerAddress / cFramePointerAddress -> not nil
>>
>>
>>
>> nicolai
>>
>>
>
> Anyone knows why the exports changed on windows?
> Or if we need the stackPointerAddress/framePointerAddress methods?
>
>
Maybe I'll just close the issue as won't fix. On the other hand, we now
have this
failing test (skipped for windows), so maybe I will remove the test.

But still, I would like to know if this change was by accident or on
purpose. If it
was on purpose, maybe there is a way to make this test succeed on windows
too?



>
> nicolai
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/vm-dev/attachments/20150913/065849b5/attachment.htm


More information about the Vm-dev mailing list