Pharo-dev
By thread
pharo-dev@lists.pharo.org
By month
Messages by month
- ----- 2026 -----
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2025 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2011 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2010 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2009 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2008 -----
- December
- November
- October
- September
- August
- July
- June
- May
November 2012
- 98 participants
- 1194 messages
[Pharo-project] Nautilus does not run test from superclass?
by Mariano Martinez Peck
Hi. I have a class XX that have some test methods.
I have a subclass YYY that have some others. If I run the tests of YYY, the
tests of XX are not run....
Even if YYY shouldInheritSelectors -> true
Do I open an issue?
--
Mariano
http://marianopeck.wordpress.com
Nov. 16, 2012
[Pharo-project] [update 2.0] #20400
by Marcus Denker
20400
-----
Issue 6975: move some RGMethodDefinition to Ring-Monticello package
http://code.google.com/p/pharo/issues/detail?id=6975
Issue 6973: two ClassDescription>> #correspondingForTest issues
http://code.google.com/p/pharo/issues/detail?id=6973
Issue 6970: Morphic dependency in checkBasicClasses
http://code.google.com/p/pharo/issues/detail?id=6970
Diff information:
http://ss3.gemstone.com/ss/Pharo20/Ring-Monticello-MarcusDenker.10.diff
http://ss3.gemstone.com/ss/Pharo20/Ring-Core-Kernel-MarcusDenker.86.diff
http://ss3.gemstone.com/ss/Pharo20/NautilusCommon-MarcusDenker.103.diff
http://ss3.gemstone.com/ss/Pharo20/Nautilus-MarcusDenker.376.diff
http://ss3.gemstone.com/ss/Pharo20/Kernel-MarcusDenker.1248.diff
--
Marcus Denker -- http://marcusdenker.de
Nov. 16, 2012
Re: [Pharo-project] [Pharo-users] CategorySaver
by Mariano Martinez Peck
On Mon, Nov 12, 2012 at 10:14 PM, Sebastian Nozzi <sebnozzi(a)gmail.com>wrote:
> 2012/11/12 Fernando Olivero <fernando.olivero(a)usi.ch>:
> > Sebastian, thanks for sharing your code and thoughts.
>
> Hey, you're welcome.
>
> > Maybe what Mariano was implying is that you already have the data for the
> > backup in the changes, and having yet another mechanism for that adds
> > complexity to the system.
>
> As I said, I think I should not have posted on "pharo project".
No, it was perfect to publish here, so that we can discuss :)
> I
> didn't mean this as a contribution to the project per se, but to the
> community (as a user, to the users). I am not suggesting for a second
> that it should be part of the system. It's something I coded for me,
> and wanted to share.
>
> And of course, everyone is free *not* to use it ;-)
>
But it is the opposite, I was asking to do the other way around: analyze
whether we should include it in Pharo :)
>
> > I think is a good idea, but too focused on the categories you choose up
> > front..and not on those actual changes you perform on the system.
>
> I would like to know how to ask the system what classes did I change.
> But the only things I found took minutes to execute (asking every
> class for its authors, or something like that). Very brute-fore. I'm
> sure there is a better approach I am not aware of.
>
> > Which is why the recovering from the changes file is better.
>
> I don't see it as "which one is better". I am honoured that this was
> interpreted as a serious theoretical "inclusion" as a Pharo feature,
> with shortcomings or not :-)
>
:)
Again, thanks for sharing this. I just wanted to know whether it makes
sense to include it in Pharo.
--
Mariano
http://marianopeck.wordpress.com
Nov. 16, 2012
Re: [Pharo-project] Pharo Association
by Marcus Denker
Thank you for your suggestions!
I am making a list of what to improve and added them (the association pharo vs. pharo association one I think is not to fix sadly...)
Marcus
On Nov 16, 2012, at 4:50 AM, Ben Coman <btc(a)openInWorld.com> wrote:
>
> Well done getting all this up an running. Some minor feedback on the web site...
>
> 1. I would guess that one of the more important purposes of the site is that people sign up. So don't hide the signup and login buttons away from the the front page. There is room on the right hand side of the title bar.
> Once logged in these could change to the membername and logout button.
>
> 2. Paypal says the payment transaction will appear on my bank statement as "PayPal*ASSOCIATION". I guess that because the payment goes to "Association Pharo".
> It would be nicer if the payment when to "Pharo Association" so that my bank statement said "PayPal*PHARO" - but I don't expect you could change that.
>
> 3. When choosing subscription type, the term "_simple_ member" to distinguish from "premium member" feels a bit condescending and unnecessary. Just "member" on its own is enough to distinguish from "premium member".
>
> simple = *2. *A fool; a simpleton.[1] /b //(1)/ *:* stupid <http://www.merriam-webster.com/dictionary/stupid> /(2)/ *:* mentally retarded [2]
> [1] http://www.thefreedictionary.com/simple
> [2] http://www.merriam-webster.com/dictionary/simple
>
> 4. Perhaps when members add contribution for display on the slide show, these could be added to the "What's new" sidebar. This might help increase the show of activity.
> As an aside, I love the name "Pharo" for the project but it is unfortunate that "Pharo" is such a widely used name with 3,000,000 unrealated results on google search, and "pharo.com" domain being used for other purposes. A tip for others making up new project names is to choose one with a small number of results on Google. A service like http://wordoid.com/ can help.
>
> Marcus Denker wrote:
>> Hello,
>>
>> We are happy to announce the Pharo User Association:
>>
>> http://association.pharo.org
>>
>> The goal of the Pharo User Association is to support Pharo development and
>> promotion.
>> There are two individual memberships
>>
>> - Individual Pharo Association Member: Yearly fee 40 Euros
>> - Golden Individual Pharo Association Member: Yearly fee 99 Euros
>>
>> You will get
>> - reduction access to pharo conferences,
>> - reduction for training and access to teaching material,
>> - be part of the pharoAssociation-individual-members mailing-list,
>> - an account at the pharo association web site.
>>
>> This Association is complementary to the Pharo consortium managed by INRIA. The Consortium is for entities such as companies, research teams, or institutes.
>> For more information, see: http://www.pharo-project.org/community/consortium
>>
>> The funds collected by the Association will be used in coordination with the Consortium to support the development of Pharo.
>>
>> The Pharo Board and Pharo Core Team.
>>
>>
>>
>>
>
>
--
Marcus Denker -- http://marcusdenker.de
Nov. 16, 2012
Re: [Pharo-project] [NativeBoost] calls to munmap always fail on OS X 10.8.2
by Max Leske
It seems I found a fix. I simply copied the code from the "mmap" call over to "munmap". Can somebody (Igor?) *please* confirm that this is ok to do? My tests are green but I'm really not sure about thisâ¦
Here's the new code for NBMacExternalHeapManager>>unmap:length:
NBMacExternalHeapManager >>unmap: addr length: len
<primitive: #primitiveNativeCall module: #NativeBoostPlugin error: errorCode>
"unmap memory page"
^ NBFFICallout
cdecl: #( int (uint addr, ulong len) )
emitCall: [:gen | | munmap |
munmap := NativeBoost forCurrentPlatform getGlobalSymbolPointer: 'munmap'.
gen asm mov: munmap asUImm32 to: gen asm EAX.
gen asm call: gen asm EAX
]
options: #( - optDirectProxyFnAddress )
Cheers,
Max
On 16.11.2012, at 14:11, Max Leske <maxleske(a)gmail.com> wrote:
> A followup on the munmap issue:
>
> I think it has something to do with how NativeBoost does the lookup. I looked at the way that "mmap" is called and noticed that the selector #getGlobalSymbolPointer: is being used. Resolving "munmap" with this selector succeeds while doing
>
> NativeBoost loadSymbol: 'munmap' aName fromModule: -2
>
> (which is what happens when the heap manager tries to call "munmap") results the stack trace shown below.
>
> I'll keep digging...
>
>
> On 15.11.2012, at 17:20, Max Leske <maxleske(a)gmail.com> wrote:
>
>> Hi
>>
>> When NativeBoost tries to call munmap to free a page (happens because a pointer I freed was the last reserved one in that page) it will throw a NBFFICalloutError (every time) because (I think) it can't find the symbol. I have absolutely no clue how to fix this so I'm in need of help.
>>
>> System: OS X 10.8.2
>> Image: 1.4
>> NativeBoost-Core: CamilloBruni.80 (Installed by using the latest NBInstaller)
>>
>> Cheers,
>> Max
>>
>> Here's the stack:
>>
>> 15 November 2012 5:04:23.895 pm
>>
>> VM: Mac OS - intel - 1082 - NBCoInterpreter NativeBoost-CogPlugin-IgorStasenko.14 uuid: da3a649c-e2b2-bd4c-aa2f-9c2ebdb2658a Oct 26 2012, StackToRegisterMappingCogit VMMaker-oscog-EstebanLorenzano.164 uuid: d77dee73-00f5-4d00-847b-00646b08329d Oct 26 2012, git://gitorious.org/cogvm/blessed.git Commit: 48af8595004fd0ec3a3ac6d44c3d7516a87981ca Date: 2012-10-24 16:56:20 +0200 By: Igor Stasenko <siguctua(a)gmail.com> Jenkins build #131
>> Image: Pharo1.4 [Latest update: #14457]
>>
>> NBFFICallout class>>signalError:
>> Receiver: NBFFICallout
>> Arguments and temporary variables:
>> errorCode: 1
>> Receiver's instance variables:
>> superclass: NBNativeCodeGen
>> methodDict: a MethodDictionary(#aliasForType:->(NBFFICallout>>#aliasForType: "a...etc...
>> format: 148
>> instanceVariables: #('fnSpec' 'requestor' 'methodArgs' 'coercionMayFail' 'callI...etc...
>> organization: ('type aliases' aliasForType:)
>> ('accessing' anonSpec: callType: c...etc...
>> subclasses: {NBNativeFunctionGen}
>> name: #NBFFICallout
>> classPool: a Dictionary(#CustomErrorCodes->a Dictionary(600->'An instance of NB...etc...
>> sharedPools: nil
>> environment: a SystemDictionary(lots of globals)
>> category: #'NativeBoost-Core-FFI'
>> traitComposition: {}
>> localSelectors: nil
>>
>> NBFFICallout class(NBNativeCodeGen class)>>handleFailureIn:nativeCode:
>> Receiver: NBFFICallout
>> Arguments and temporary variables:
>> aContext: NativeBoostMac32(NativeBoost)>>bootstrapLoadSymbol:ofLength:fromModul...etc...
>> aBlock: [:gen | gen useEmitCall; sender: sender; parseOptions: anOptions; cdecl...etc...
>> method: (NativeBoost>>#bootstrapLoadSymbol:ofLength:fromModule:into: "a Compile...etc...
>> lastError: 1
>> Receiver's instance variables:
>> superclass: NBNativeCodeGen
>> methodDict: a MethodDictionary(#aliasForType:->(NBFFICallout>>#aliasForType: "a...etc...
>> format: 148
>> instanceVariables: #('fnSpec' 'requestor' 'methodArgs' 'coercionMayFail' 'callI...etc...
>> organization: ('type aliases' aliasForType:)
>> ('accessing' anonSpec: callType: c...etc...
>> subclasses: {NBNativeFunctionGen}
>> name: #NBFFICallout
>> classPool: a Dictionary(#CustomErrorCodes->a Dictionary(600->'An instance of NB...etc...
>> sharedPools: nil
>> environment: a SystemDictionary(lots of globals)
>> category: #'NativeBoost-Core-FFI'
>> traitComposition: {}
>> localSelectors: nil
>>
>> NBFFICallout class>>cdecl:emitCall:options:
>> Receiver: NBFFICallout
>> Arguments and temporary variables:
>> functionSpec: #(#NBBootstrapUlong #(#byte #* #symbolName #, #long #symbolLen #,...etc...
>> aCallEmittingBlock: [:gen | gen proxy callFn: #ioLoadSymbol:OfLength:FromModule...etc...
>> anOptions: #(#- #optDirectProxyFnAddress #optAllowExternalAddressPtr)
>> sender: NativeBoostMac32(NativeBoost)>>bootstrapLoadSymbol:ofLength:fromModule:...etc...
>> Receiver's instance variables:
>> superclass: NBNativeCodeGen
>> methodDict: a MethodDictionary(#aliasForType:->(NBFFICallout>>#aliasForType: "a...etc...
>> format: 148
>> instanceVariables: #('fnSpec' 'requestor' 'methodArgs' 'coercionMayFail' 'callI...etc...
>> organization: ('type aliases' aliasForType:)
>> ('accessing' anonSpec: callType: c...etc...
>> subclasses: {NBNativeFunctionGen}
>> name: #NBFFICallout
>> classPool: a Dictionary(#CustomErrorCodes->a Dictionary(600->'An instance of NB...etc...
>> sharedPools: nil
>> environment: a SystemDictionary(lots of globals)
>> category: #'NativeBoost-Core-FFI'
>> traitComposition: {}
>> localSelectors: nil
>>
>> NativeBoostMac32(NativeBoost)>>bootstrapLoadSymbol:ofLength:fromModule:into:
>> Receiver: a NativeBoostMac32
>> Arguments and temporary variables:
>> symbolName: 'munmap'
>> symbolLen: 6
>> moduleHandle: -2
>> returnValueBuffer: #[0 0 0 0 0 0 0 0]
>> Receiver's instance variables:
>> bootstrapping: false
>> insideCallback: nil
>> callbackCounterAddr: @ 16r5F74000
>> extraRootsRegistry: a NBExtraRootsRegistry
>> rootsCell: @ 16r5F7402A
>> gateFunction: @ 16r5F74004
>> heap: a NBMacExternalHeapManager
>>
>> NativeBoostMac32(NativeBoost)>>loadSymbol:fromModule:
>> Receiver: a NativeBoostMac32
>> Arguments and temporary variables:
>> aSymbolName: 'munmap'
>> moduleName: -2
>> bytes: #[0 0 0 0 0 0 0 0]
>> module: -2
>> handle: nil
>> Receiver's instance variables:
>> bootstrapping: false
>> insideCallback: nil
>> callbackCounterAddr: @ 16r5F74000
>> extraRootsRegistry: a NBExtraRootsRegistry
>> rootsCell: @ 16r5F7402A
>> gateFunction: @ 16r5F74004
>> heap: a NBMacExternalHeapManager
>>
>> NativeBoostMac32(NativeBoostLinux32)>>loadSymbol:fromModule:
>> Receiver: a NativeBoostMac32
>> Arguments and temporary variables:
>> aSymbolName: 'munmap'
>> moduleName: -2
>> Receiver's instance variables:
>> bootstrapping: false
>> insideCallback: nil
>> callbackCounterAddr: @ 16r5F74000
>> extraRootsRegistry: a NBExtraRootsRegistry
>> rootsCell: @ 16r5F7402A
>> gateFunction: @ 16r5F74004
>> heap: a NBMacExternalHeapManager
>>
>> NativeBoost class>>loadSymbol:fromModule:
>> Receiver: NativeBoost
>> Arguments and temporary variables:
>> aSymbolName: 'munmap'
>> moduleName: -2
>> Receiver's instance variables:
>> superclass: Object
>> methodDict: a MethodDictionary(#CLibrary->(NativeBoost>>#CLibrary "a CompiledMe...etc...
>> format: 142
>> instanceVariables: #('bootstrapping' 'insideCallback' 'callbackCounterAddr' 'ex...etc...
>> organization: ('retrieving symbols' CLibrary VMModule ioLoadFunction:from: ioLo...etc...
>> subclasses: {NativeBoostLinux32. NativeBoostWin32}
>> name: #NativeBoost
>> classPool: a Dictionary(#Current->a NativeBoostMac32 #NBAnnouncer->an Announcer...etc...
>> sharedPools: an OrderedCollection(AJx86Registers NativeBoostConstants)
>> environment: a SystemDictionary(lots of globals)
>> category: #'NativeBoost-Core'
>> traitComposition: {}
>> localSelectors: nil
>>
>> NBMacExternalHeapManager class(Object)>>nbGetSymbolAddress:module:
>> Receiver: NBMacExternalHeapManager
>> Arguments and temporary variables:
>> aName: 'munmap'
>> aModuleNameOrHandle: -2
>> addr: nil
>> Receiver's instance variables:
>> superclass: NBExternalHeapManager
>> methodDict: a MethodDictionary(#mapFlags->(NBMacExternalHeapManager>>#mapFlags ...etc...
>> format: 138
>> instanceVariables: nil
>> organization: ('as yet unclassified' mapFlags mmapLength:prot:flags:into: primA...etc...
>> subclasses: nil
>> name: #NBMacExternalHeapManager
>> classPool: nil
>> sharedPools: an OrderedCollection(NBMacConstants)
>> environment: a SystemDictionary(lots of globals)
>> category: #'NativeBoost-Mac'
>> traitComposition: {}
>> localSelectors: nil
>>
>> [:gen |
>> fnAddress := requestor nbGetSymbolAddress: fnSpec functionName module: aModuleNameOrHandle.
>> fnAddress
>> ifNil: [self error: 'function unavailable'].
>> self optMayGC
>> ifTrue: [asm push: fnAddress asUImm32;
>> mov: NativeBoost callgateFunctionAddress asUImm32 to: EAX;
>> call: EAX]
>> ifFalse: [asm mov: fnAddress asUImm32 to: EAX;
>> call: EAX]] in NBFFICallout>>generateCall:module:
>> Receiver: a NBFFICallout
>> Arguments and temporary variables:
>> aModuleNameOrHandle: a NBFFICallout
>> fnAddress: -2
>> gen: #(nil)
>> Receiver's instance variables:
>> asm: an AJx86Assembler
>> proxy: a NBInterpreterProxy
>> options: a Set(#optCdecl #optAllowByteArraysPtr #optUseStackPointer #optReturnP...etc...
>> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
>> fnSpec: a NBFnSpec
>> requestor: NBMacExternalHeapManager
>> methodArgs: an OrderedCollection('addr' 'len')
>> coercionMayFail: true
>> callInfo: an AJCdeclCallInfo
>>
>> BlockClosure>>valueWithPossibleArgs:
>> Receiver: [:gen |
>> fnAddress := requestor nbGetSymbolAddress: fnSpec functionName module: aModuleNam...etc...
>> Arguments and temporary variables:
>> anArray: an Array(a NBFFICallout a NBInterpreterProxy an AJx86Assembler)
>> Receiver's instance variables:
>> outerContext: NBFFICallout>>generateCall:module:
>> startpc: 91
>> numArgs: 1
>>
>> [aFunctionBodyBlock valueWithPossibleArgs: {self. proxy. asm}.
>> (self optEmitCall
>> or: [self optNoCleanup])
>> ifTrue: [call disableCleanup]] in [:call |
>> self optNoAlignment
>> ifTrue: [call alignment: 1].
>> self pushArguments.
>> coercionMayFail
>> ifTrue: [proxy ifFailedJumpTo: self failedLabel].
>> asm
>> decorateWith: 'FFI: performing a call'
>> during: [aFunctionBodyBlock valueWithPossibleArgs: {self. proxy. asm}.
>> (self optEmitCall
>> or: [self optNoCleanup])
>> ifTrue: [call disableCleanup]]] in NBFFICallout>>generateInstructions:
>> Receiver: a NBFFICallout
>> Arguments and temporary variables:
>> aFunctionBodyBlock: an AJCdeclCallInfo
>> call: [:gen |
>> fnAddress := requestor nbGetSymbolAddress: fnSpec functionName m...etc...
>> Receiver's instance variables:
>> asm: an AJx86Assembler
>> proxy: a NBInterpreterProxy
>> options: a Set(#optCdecl #optAllowByteArraysPtr #optUseStackPointer #optReturnP...etc...
>> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
>> fnSpec: a NBFnSpec
>> requestor: NBMacExternalHeapManager
>> methodArgs: an OrderedCollection('addr' 'len')
>> coercionMayFail: true
>> callInfo: an AJCdeclCallInfo
>>
>> BlockClosure>>ensure:
>> Receiver: [aFunctionBodyBlock valueWithPossibleArgs: {self. proxy. asm}.
>> (self optEmitCall
>> or: [...etc...
>> Arguments and temporary variables:
>> aBlock: [level := level - 1.
>> self
>> addInstruction: (AJInstructionDecoration n...etc...
>> complete: nil
>> returnValue: nil
>> Receiver's instance variables:
>> outerContext: [:call |
>> self optNoAlignment
>> ifTrue: [call alignment: 1].
>> sel...etc...
>> startpc: 155
>> numArgs: 0
>>
>> AJx86Assembler>>decorateWith:during:
>> Receiver: an AJx86Assembler
>> Arguments and temporary variables:
>> annotation: 'FFI: performing a call'
>> aBlock: [aFunctionBodyBlock valueWithPossibleArgs: {self. proxy. asm}.
>> (self o...etc...
>> Receiver's instance variables:
>> instructions: <<error during printing>>
>>
>> [:call |
>> self optNoAlignment
>> ifTrue: [call alignment: 1].
>> self pushArguments.
>> coercionMayFail
>> ifTrue: [proxy ifFailedJumpTo: self failedLabel].
>> asm
>> decorateWith: 'FFI: performing a call'
>> during: [aFunctionBodyBlock valueWithPossibleArgs: {self. proxy. asm}.
>> (self optEmitCall
>> or: [self optNoCleanup])
>> ifTrue: [call disableCleanup]]] in NBFFICallout>>generateInstructions:
>> Receiver: a NBFFICallout
>> Arguments and temporary variables:
>> aFunctionBodyBlock: an AJCdeclCallInfo
>> call: [:gen |
>> fnAddress := requestor nbGetSymbolAddress: fnSpec functionName m...etc...
>> Receiver's instance variables:
>> asm: an AJx86Assembler
>> proxy: a NBInterpreterProxy
>> options: a Set(#optCdecl #optAllowByteArraysPtr #optUseStackPointer #optReturnP...etc...
>> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
>> fnSpec: a NBFnSpec
>> requestor: NBMacExternalHeapManager
>> methodArgs: an OrderedCollection('addr' 'len')
>> coercionMayFail: true
>> callInfo: an AJCdeclCallInfo
>>
>> AJx86Assembler>>performingCall:in:
>> Receiver: an AJx86Assembler
>> Arguments and temporary variables:
>> ci: an AJCdeclCallInfo
>> aBlock: [:call |
>> self optNoAlignment
>> ifTrue: [call alignment: 1].
>> self push...etc...
>> Receiver's instance variables:
>> instructions: <<error during printing>>
>>
>> NBFFICallout>>foreignCall:
>> Receiver: a NBFFICallout
>> Arguments and temporary variables:
>> aBlock: [:call |
>> self optNoAlignment
>> ifTrue: [call alignment: 1].
>> self push...etc...
>> Receiver's instance variables:
>> asm: an AJx86Assembler
>> proxy: a NBInterpreterProxy
>> options: a Set(#optCdecl #optAllowByteArraysPtr #optUseStackPointer #optReturnP...etc...
>> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
>> fnSpec: a NBFnSpec
>> requestor: NBMacExternalHeapManager
>> methodArgs: an OrderedCollection('addr' 'len')
>> coercionMayFail: true
>> callInfo: an AJCdeclCallInfo
>>
>> NBFFICallout>>generateInstructions:
>> Receiver: a NBFFICallout
>> Arguments and temporary variables:
>> aFunctionBodyBlock: [:gen |
>> fnAddress := requestor nbGetSymbolAddress: fnSpec ...etc...
>> instructions: nil
>> Receiver's instance variables:
>> asm: an AJx86Assembler
>> proxy: a NBInterpreterProxy
>> options: a Set(#optCdecl #optAllowByteArraysPtr #optUseStackPointer #optReturnP...etc...
>> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
>> fnSpec: a NBFnSpec
>> requestor: NBMacExternalHeapManager
>> methodArgs: an OrderedCollection('addr' 'len')
>> coercionMayFail: true
>> callInfo: an AJCdeclCallInfo
>>
>> NBFFICallout>>generate:
>> Receiver: a NBFFICallout
>> Arguments and temporary variables:
>> aFunctionBodyBlock: [:gen |
>> fnAddress := requestor nbGetSymbolAddress: fnSpec ...etc...
>> generatedCode: nil
>> Receiver's instance variables:
>> asm: an AJx86Assembler
>> proxy: a NBInterpreterProxy
>> options: a Set(#optCdecl #optAllowByteArraysPtr #optUseStackPointer #optReturnP...etc...
>> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
>> fnSpec: a NBFnSpec
>> requestor: NBMacExternalHeapManager
>> methodArgs: an OrderedCollection('addr' 'len')
>> coercionMayFail: true
>> callInfo: an AJCdeclCallInfo
>>
>> NBFFICallout>>generateCall:module:
>> Receiver: a NBFFICallout
>> Arguments and temporary variables:
>> functionSpec: #(#int #munmap #(#uint #addr #, #ulong #len))
>> aModuleNameOrHandle: -2
>> fnAddress: #(nil)
>> Receiver's instance variables:
>> asm: an AJx86Assembler
>> proxy: a NBInterpreterProxy
>> options: a Set(#optCdecl #optAllowByteArraysPtr #optUseStackPointer #optReturnP...etc...
>> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
>> fnSpec: a NBFnSpec
>> requestor: NBMacExternalHeapManager
>> methodArgs: an OrderedCollection('addr' 'len')
>> coercionMayFail: true
>> callInfo: an AJCdeclCallInfo
>>
>> [:gen | gen sender: sender;
>> cdecl;
>> generateCall: functionSpec module: aModuleName] in NBFFICallout class>>cdecl:module:
>> Receiver: NBFFICallout
>> Arguments and temporary variables:
>> functionSpec: a NBFFICallout
>> aModuleName: #(#int #munmap #(#uint #addr #, #ulong #len))
>> sender: -2
>> gen: NBMacExternalHeapManager>>unmap:length:
>> Receiver's instance variables:
>> superclass: NBNativeCodeGen
>> methodDict: a MethodDictionary(#aliasForType:->(NBFFICallout>>#aliasForType: "a...etc...
>> format: 148
>> instanceVariables: #('fnSpec' 'requestor' 'methodArgs' 'coercionMayFail' 'callI...etc...
>> organization: ('type aliases' aliasForType:)
>> ('accessing' anonSpec: callType: c...etc...
>> subclasses: {NBNativeFunctionGen}
>> name: #NBFFICallout
>> classPool: a Dictionary(#CustomErrorCodes->a Dictionary(600->'An instance of NB...etc...
>> sharedPools: nil
>> environment: a SystemDictionary(lots of globals)
>> category: #'NativeBoost-Core-FFI'
>> traitComposition: {}
>> localSelectors: nil
>>
>> [bytes := aBlock
>> value: (self newForMethod: method)] in NBFFICallout class(NBNativeCodeGen class)>>generateCode:andRetry:
>> Receiver: NBFFICallout
>> Arguments and temporary variables:
>> aBlock: [:gen | gen sender: sender;
>> cdecl;
>> generateCall: functionSpec mod...etc...
>> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
>> bytes: #(nil)
>> Receiver's instance variables:
>> superclass: NBNativeCodeGen
>> methodDict: a MethodDictionary(#aliasForType:->(NBFFICallout>>#aliasForType: "a...etc...
>> format: 148
>> instanceVariables: #('fnSpec' 'requestor' 'methodArgs' 'coercionMayFail' 'callI...etc...
>> organization: ('type aliases' aliasForType:)
>> ('accessing' anonSpec: callType: c...etc...
>> subclasses: {NBNativeFunctionGen}
>> name: #NBFFICallout
>> classPool: a Dictionary(#CustomErrorCodes->a Dictionary(600->'An instance of NB...etc...
>> sharedPools: nil
>> environment: a SystemDictionary(lots of globals)
>> category: #'NativeBoost-Core-FFI'
>> traitComposition: {}
>> localSelectors: nil
>>
>> BlockClosure>>on:do:
>> Receiver: [bytes := aBlock
>> value: (self newForMethod: method)]
>> Arguments and temporary variables:
>> exception: NBRecursionDetect
>> handlerAction: [:ex | ex check: aMethod]
>> handlerActive: true
>> Receiver's instance variables:
>> outerContext: NBFFICallout class(NBNativeCodeGen class)>>generateCode:andRetry:...etc...
>> startpc: 96
>> numArgs: 0
>>
>> NBRecursionDetect class>>in:during:
>> Receiver: NBRecursionDetect
>> Arguments and temporary variables:
>> aMethod: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)...etc...
>> aBlock: [bytes := aBlock
>> value: (self newForMethod: method)]
>> Receiver's instance variables:
>> superclass: Notification
>> methodDict: a MethodDictionary(#check:->(NBRecursionDetect>>#check: "a Compiled...etc...
>> format: 144
>> instanceVariables: #('method')
>> organization: ('as yet unclassified' check: defaultAction method signalForMetho...etc...
>> subclasses: nil
>> name: #NBRecursionDetect
>> classPool: nil
>> sharedPools: nil
>> environment: a SystemDictionary(lots of globals)
>> category: #'NativeBoost-Core-Errors'
>> traitComposition: {}
>> localSelectors: nil
>>
>> NBFFICallout class(NBNativeCodeGen class)>>generateCode:andRetry:
>> Receiver: NBFFICallout
>> Arguments and temporary variables:
>> aBlock: [:gen | gen sender: sender;
>> cdecl;
>> generateCall: functionSpec mod...etc...
>> retryCtx: NBMacExternalHeapManager>>unmap:length:
>> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
>> newMethod: nil
>> args: nil
>> bytes: #(nil)
>> Receiver's instance variables:
>> superclass: NBNativeCodeGen
>> methodDict: a MethodDictionary(#aliasForType:->(NBFFICallout>>#aliasForType: "a...etc...
>> format: 148
>> instanceVariables: #('fnSpec' 'requestor' 'methodArgs' 'coercionMayFail' 'callI...etc...
>> organization: ('type aliases' aliasForType:)
>> ('accessing' anonSpec: callType: c...etc...
>> subclasses: {NBNativeFunctionGen}
>> name: #NBFFICallout
>> classPool: a Dictionary(#CustomErrorCodes->a Dictionary(600->'An instance of NB...etc...
>> sharedPools: nil
>> environment: a SystemDictionary(lots of globals)
>> category: #'NativeBoost-Core-FFI'
>> traitComposition: {}
>> localSelectors: nil
>>
>> NBFFICallout class(NBNativeCodeGen class)>>handleFailureIn:nativeCode:
>> Receiver: NBFFICallout
>> Arguments and temporary variables:
>> aContext: NBMacExternalHeapManager>>unmap:length:
>> aBlock: [:gen | gen sender: sender;
>> cdecl;
>> generateCall: functionSpec mod...etc...
>> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
>> lastError: 502
>> Receiver's instance variables:
>> superclass: NBNativeCodeGen
>> methodDict: a MethodDictionary(#aliasForType:->(NBFFICallout>>#aliasForType: "a...etc...
>> format: 148
>> instanceVariables: #('fnSpec' 'requestor' 'methodArgs' 'coercionMayFail' 'callI...etc...
>> organization: ('type aliases' aliasForType:)
>> ('accessing' anonSpec: callType: c...etc...
>> subclasses: {NBNativeFunctionGen}
>> name: #NBFFICallout
>> classPool: a Dictionary(#CustomErrorCodes->a Dictionary(600->'An instance of NB...etc...
>> sharedPools: nil
>> environment: a SystemDictionary(lots of globals)
>> category: #'NativeBoost-Core-FFI'
>> traitComposition: {}
>> localSelectors: nil
>>
>> NBFFICallout class>>cdecl:module:
>> Receiver: NBFFICallout
>> Arguments and temporary variables:
>> functionSpec: #(#int #munmap #(#uint #addr #, #ulong #len))
>> aModuleName: -2
>> sender: NBMacExternalHeapManager>>unmap:length:
>> Receiver's instance variables:
>> superclass: NBNativeCodeGen
>> methodDict: a MethodDictionary(#aliasForType:->(NBFFICallout>>#aliasForType: "a...etc...
>> format: 148
>> instanceVariables: #('fnSpec' 'requestor' 'methodArgs' 'coercionMayFail' 'callI...etc...
>> organization: ('type aliases' aliasForType:)
>> ('accessing' anonSpec: callType: c...etc...
>> subclasses: {NBNativeFunctionGen}
>> name: #NBFFICallout
>> classPool: a Dictionary(#CustomErrorCodes->a Dictionary(600->'An instance of NB...etc...
>> sharedPools: nil
>> environment: a SystemDictionary(lots of globals)
>> category: #'NativeBoost-Core-FFI'
>> traitComposition: {}
>> localSelectors: nil
>>
>> NBMacExternalHeapManager>>unmap:length:
>> Receiver: a NBMacExternalHeapManager
>> Arguments and temporary variables:
>> addr: 7380992
>> len: 32768
>> errorCode: 502
>> Receiver's instance variables:
>> pages: a Dictionary(24981504->a NBMemoryPage 100089856->a NBMemoryPage )
>> freeBlocks: an IdentitySet(a NBMemoryBlock( @ 16r17D302E, 17, free) a NBMemoryB...etc...
>> reservedBlocks: a Dictionary(24981504->a NBMemoryBlock( @ 16r17D3000, 38) 24981...etc...
>> sema: a Semaphore()
>>
>> NBMacExternalHeapManager>>primFreePage:
>> Receiver: a NBMacExternalHeapManager
>> Arguments and temporary variables:
>> aMemoryPage: a NBMemoryPage
>> res: nil
>> Receiver's instance variables:
>> pages: a Dictionary(24981504->a NBMemoryPage 100089856->a NBMemoryPage )
>> freeBlocks: an IdentitySet(a NBMemoryBlock( @ 16r17D302E, 17, free) a NBMemoryB...etc...
>> reservedBlocks: a Dictionary(24981504->a NBMemoryBlock( @ 16r17D3000, 38) 24981...etc...
>> sema: a Semaphore()
>>
>> NBMacExternalHeapManager(NBExternalHeapManager)>>freePage:
>> Receiver: a NBMacExternalHeapManager
>> Arguments and temporary variables:
>> aMemoryPage: a NBMemoryPage
>> Receiver's instance variables:
>> pages: a Dictionary(24981504->a NBMemoryPage 100089856->a NBMemoryPage )
>> freeBlocks: an IdentitySet(a NBMemoryBlock( @ 16r17D302E, 17, free) a NBMemoryB...etc...
>> reservedBlocks: a Dictionary(24981504->a NBMemoryBlock( @ 16r17D3000, 38) 24981...etc...
>> sema: a Semaphore()
>>
>> [:page |
>> page length = aMemoryBlock length
>> ifTrue: [self freePage: page.
>> ^ true].
>> nil] in NBMacExternalHeapManager(NBExternalHeapManager)>>checkForFreePage:
>> Receiver: a NBMacExternalHeapManager
>> Arguments and temporary variables:
>> aMemoryBlock: a NBMemoryPage
>> page: a NBMemoryBlock( @ 16r70A000, 32768, free)
>> Receiver's instance variables:
>> pages: a Dictionary(24981504->a NBMemoryPage 100089856->a NBMemoryPage )
>> freeBlocks: an IdentitySet(a NBMemoryBlock( @ 16r17D302E, 17, free) a NBMemoryB...etc...
>> reservedBlocks: a Dictionary(24981504->a NBMemoryBlock( @ 16r17D3000, 38) 24981...etc...
>> sema: a Semaphore()
>>
>> BlockClosure>>cull:
>> Receiver: [:page |
>> page length = aMemoryBlock length
>> ifTrue: [self freePage: page.
>> ^ true].
>> n...etc...
>> Arguments and temporary variables:
>> anArg: a NBMemoryPage
>> Receiver's instance variables:
>> outerContext: NBMacExternalHeapManager(NBExternalHeapManager)>>checkForFreePage...etc...
>> startpc: 41
>> numArgs: 1
>>
>> Dictionary>>at:ifPresent:
>> Receiver: a Dictionary(24981504->a NBMemoryPage 100089856->a NBMemoryPage )
>> Arguments and temporary variables:
>> key: 7380992
>> aBlock: [:page |
>> page length = aMemoryBlock length
>> ifTrue: [self freePage: p...etc...
>> assoc: 7380992->a NBMemoryPage
>> Receiver's instance variables:
>> tally: 2
>> array: an Array(nil 100089856->a NBMemoryPage nil nil 24981504->a NBMemoryPage)...etc...
>>
>> NBMacExternalHeapManager(NBExternalHeapManager)>>checkForFreePage:
>> Receiver: a NBMacExternalHeapManager
>> Arguments and temporary variables:
>> aMemoryBlock: a NBMemoryBlock( @ 16r70A000, 32768, free)
>> Receiver's instance variables:
>> pages: a Dictionary(24981504->a NBMemoryPage 100089856->a NBMemoryPage )
>> freeBlocks: an IdentitySet(a NBMemoryBlock( @ 16r17D302E, 17, free) a NBMemoryB...etc...
>> reservedBlocks: a Dictionary(24981504->a NBMemoryBlock( @ 16r17D3000, 38) 24981...etc...
>> sema: a Semaphore()
>>
>> NBMemoryBlock>>makeFreeFor:
>> Receiver: a NBMemoryBlock( @ 16r70A030, 32720, free)
>> Arguments and temporary variables:
>> heapManager: a NBMacExternalHeapManager
>> Receiver's instance variables:
>> left: a NBMemoryBlock( @ 16r70A000, 32768, free)
>> right: nil
>> address: 7381040
>> length: 32720
>> free: true
>>
>> [| block |
>> block := reservedBlocks
>> removeKey: address
>> ifAbsent: [self error: 'Unable to find a memory block with given address'].
>> block makeFreeFor: self] in NBMacExternalHeapManager(NBExternalHeapManager)>>free:
>> Receiver: a NBMacExternalHeapManager
>> Arguments and temporary variables:
>> address: 7381040
>> block: a NBMemoryBlock( @ 16r70A030, 32720, free)
>> Receiver's instance variables:
>> pages: a Dictionary(24981504->a NBMemoryPage 100089856->a NBMemoryPage )
>> freeBlocks: an IdentitySet(a NBMemoryBlock( @ 16r17D302E, 17, free) a NBMemoryB...etc...
>> reservedBlocks: a Dictionary(24981504->a NBMemoryBlock( @ 16r17D3000, 38) 24981...etc...
>> sema: a Semaphore()
>>
>> [caught := true.
>> self wait.
>> blockValue := mutuallyExcludedBlock value] in Semaphore>>critical:
>> Receiver: a Semaphore()
>> Arguments and temporary variables:
>> <<error during printing>
>> Receiver's instance variables:
>> firstLink: nil
>> lastLink: nil
>> excessSignals: 0
>>
>> BlockClosure>>ensure:
>> Receiver: [caught := true.
>> self wait.
>> blockValue := mutuallyExcludedBlock value]
>> Arguments and temporary variables:
>> aBlock: [caught
>> ifTrue: [self signal]]
>> complete: nil
>> returnValue: nil
>> Receiver's instance variables:
>> outerContext: Semaphore>>critical:
>> startpc: 42
>> numArgs: 0
>>
>> Semaphore>>critical:
>> Receiver: a Semaphore()
>> Arguments and temporary variables:
>> <<error during printing>
>> Receiver's instance variables:
>> firstLink: nil
>> lastLink: nil
>> excessSignals: 0
>>
>> NBMacExternalHeapManager(NBExternalHeapManager)>>free:
>> Receiver: a NBMacExternalHeapManager
>> Arguments and temporary variables:
>> address: 7381040
>> Receiver's instance variables:
>> pages: a Dictionary(24981504->a NBMemoryPage 100089856->a NBMemoryPage )
>> freeBlocks: an IdentitySet(a NBMemoryBlock( @ 16r17D302E, 17, free) a NBMemoryB...etc...
>> reservedBlocks: a Dictionary(24981504->a NBMemoryBlock( @ 16r17D3000, 38) 24981...etc...
>> sema: a Semaphore()
>>
>>
>> --- The full stack ---
>> NBFFICallout class>>signalError:
>> NBFFICallout class(NBNativeCodeGen class)>>handleFailureIn:nativeCode:
>> NBFFICallout class>>cdecl:emitCall:options:
>> NativeBoostMac32(NativeBoost)>>bootstrapLoadSymbol:ofLength:fromModule:into:
>> NativeBoostMac32(NativeBoost)>>loadSymbol:fromModule:
>> NativeBoostMac32(NativeBoostLinux32)>>loadSymbol:fromModule:
>> NativeBoost class>>loadSymbol:fromModule:
>> NBMacExternalHeapManager class(Object)>>nbGetSymbolAddress:module:
>> [:gen |
>> fnAddress := requestor nbGetSymbolAddress: fnSpec functionName module: aModuleNameOrHandle.
>> fnAddress
>> ifNil: [self error: 'function unavailable'].
>> self optMayGC
>> ifTrue: [asm push: fnAddress asUImm32;
>> mov: NativeBoost callgateFunctionAddress asUImm32 to: EAX;
>> call: EAX]
>> ifFalse: [asm mov: fnAddress asUImm32 to: EAX;
>> call: EAX]] in NBFFICallout>>generateCall:module:
>> BlockClosure>>valueWithPossibleArgs:
>> [aFunctionBodyBlock valueWithPossibleArgs: {self. proxy. asm}.
>> (self optEmitCall
>> or: [self optNoCleanup])
>> ifTrue: [call disableCleanup]] in [:call |
>> self optNoAlignment
>> ifTrue: [call alignment: 1].
>> self pushArguments.
>> coercionMayFail
>> ifTrue: [proxy ifFailedJumpTo: self failedLabel].
>> asm
>> decorateWith: 'FFI: performing a call'
>> during: [aFunctionBodyBlock valueWithPossibleArgs: {self. proxy. asm}.
>> (self optEmitCall
>> or: [self optNoCleanup])
>> ifTrue: [call disableCleanup]]] in NBFFICallout>>generateInstructions:
>> BlockClosure>>ensure:
>> AJx86Assembler>>decorateWith:during:
>> [:call |
>> self optNoAlignment
>> ifTrue: [call alignment: 1].
>> self pushArguments.
>> coercionMayFail
>> ifTrue: [proxy ifFailedJumpTo: self failedLabel].
>> asm
>> decorateWith: 'FFI: performing a call'
>> during: [aFunctionBodyBlock valueWithPossibleArgs: {self. proxy. asm}.
>> (self optEmitCall
>> or: [self optNoCleanup])
>> ifTrue: [call disableCleanup]]] in NBFFICallout>>generateInstructions:
>> AJx86Assembler>>performingCall:in:
>> NBFFICallout>>foreignCall:
>> NBFFICallout>>generateInstructions:
>> NBFFICallout>>generate:
>> NBFFICallout>>generateCall:module:
>> [:gen | gen sender: sender;
>> cdecl;
>> generateCall: functionSpec module: aModuleName] in NBFFICallout class>>cdecl:module:
>> [bytes := aBlock
>> value: (self newForMethod: method)] in NBFFICallout class(NBNativeCodeGen class)>>generateCode:andRetry:
>> BlockClosure>>on:do:
>> NBRecursionDetect class>>in:during:
>> NBFFICallout class(NBNativeCodeGen class)>>generateCode:andRetry:
>> NBFFICallout class(NBNativeCodeGen class)>>handleFailureIn:nativeCode:
>> NBFFICallout class>>cdecl:module:
>> NBMacExternalHeapManager>>unmap:length:
>> NBMacExternalHeapManager>>primFreePage:
>> NBMacExternalHeapManager(NBExternalHeapManager)>>freePage:
>> [:page |
>> page length = aMemoryBlock length
>> ifTrue: [self freePage: page.
>> ^ true].
>> nil] in NBMacExternalHeapManager(NBExternalHeapManager)>>checkForFreePage:
>> BlockClosure>>cull:
>> Dictionary>>at:ifPresent:
>> NBMacExternalHeapManager(NBExternalHeapManager)>>checkForFreePage:
>> NBMemoryBlock>>makeFreeFor:
>> [| block |
>> block := reservedBlocks
>> removeKey: address
>> ifAbsent: [self error: 'Unable to find a memory block with given address'].
>> block makeFreeFor: self] in NBMacExternalHeapManager(NBExternalHeapManager)>>free:
>> [caught := true.
>> self wait.
>> blockValue := mutuallyExcludedBlock value] in Semaphore>>critical:
>> BlockClosure>>ensure:
>> Semaphore>>critical:
>> NBMacExternalHeapManager(NBExternalHeapManager)>>free:
>> - - - - - - - - - - - - - - -
>> - - - - - - - - - - - - - - - - - -
>> NativeBoostMac32(NativeBoostLinux32)>>free:
>> NativeBoost class>>free:
>> NBExternalAddress>>free
>> [:pointer | pointer value free] in LimboCommand>>freePointers
>> Set>>do:
>> LimboCommand>>freePointers
>> [self freePointers] in LimboCommand>>run
>> BlockClosure>>ensure:
>> LimboCommand>>run
>> Limbo>>run:arguments:
>> Limbo>>runSh:
>> Limbo class>>runSh:
>> [limbo := Limbo runSh: '/bin/echo ' , arg] in LimboTest>>testShellCommandWithNewLines
>> [aBlock value.
>> false] in LimboTest(TestCase)>>executeShould:inScopeOf:
>> BlockClosure>>on:do:
>> LimboTest(TestCase)>>executeShould:inScopeOf:
>> LimboTest(TestCase)>>shouldnt:raise:
>> LimboTest>>testShellCommandWithNewLines
>> LimboTest(TestCase)>>performTest
>> [self setUp.
>> self performTest] in LimboTest(TestCase)>>runCase
>> BlockClosure>>ensure:
>> LimboTest(TestCase)>>runCase
>> [(self class selector: testSelector) runCase] in LimboTest(TestCase)>>debug
>> BlockClosure>>ensure:
>> LimboTest(TestCase)>>debug
>> OBCmdRunTests>>execute
>> [:each |
>> (each isActive
>> and: [each isEnabled])
>> ifTrue: [each execute.
>> ^ true].
>> nil] in OBNodeCommandScan(OBCommandScan)>>processKeystroke:withNode:for:
>> OrderedCollection>>do:
>> OBNodeCommandScan(OBCommandScan)>>processKeystroke:withNode:for:
>> [:each |
>> (scan
>> processKeystroke: aCharacter asKeystroke
>> withNode: each
>> for: self)
>> ifTrue: [^ self].
>> nil] in OBColumn>>keystroke:from:
>> OrderedCollection>>reverseDo:
>> OBColumn>>keystroke:from:
>> OBPluggableListMorph(PluggableListMorph)>>modifierKeyPressed:
>> OBPluggableListMorph(PluggableListMorph)>>keyStroke:
>> OBPluggableListMorph(Morph)>>handleKeystroke:
>> KeyboardEvent>>sentTo:
>> OBPluggableListMorph(Morph)>>handleEvent:
>> MorphicEventDispatcher>>dispatchDefault:with:
>> MorphicEventDispatcher>>dispatchEvent:with:
>> OBPluggableListMorph(Morph)>>processEvent:using:
>> OBPluggableListMorph(Morph)>>processEvent:
>> OBPluggableListMorph(PluggableListMorph)>>handleFocusEvent:
>> [ActiveHand := self.
>> ActiveEvent := anEvent.
>> result := focusHolder
>> handleFocusEvent: (anEvent
>> transformedBy: (focusHolder transformedFrom: self))] in HandMorph>>sendFocusEvent:to:clear:
>> [aBlock value] in PasteUpMorph>>becomeActiveDuring:
>> BlockClosure>>on:do:
>> PasteUpMorph>>becomeActiveDuring:
>> HandMorph>>sendFocusEvent:to:clear:
>> HandMorph>>sendEvent:focus:clear:
>> HandMorph>>sendKeyboardEvent:
>> HandMorph>>handleEvent:
>> HandMorph>>processEvents
>> [:h |
>> ActiveHand := h.
>> h processEvents.
>> ActiveHand := nil] in WorldState>>doOneCycleNowFor:
>> Array(SequenceableCollection)>>do:
>> WorldState>>handsDo:
>> WorldState>>doOneCycleNowFor:
>> WorldState>>doOneCycleFor:
>> PasteUpMorph>>doOneCycle
>> [[World doOneCycle.
>> Processor yield.
>> false] whileFalse.
>> nil] in MorphicUIManager>>spawnNewProcess
>> [self value.
>> Processor terminateActive] in BlockClosure>>newProcess
>>
>
Nov. 16, 2012
Re: [Pharo-project] [NativeBoost] calls to munmap always fail on OS X 10.8.2
by Max Leske
A followup on the munmap issue:
I think it has something to do with how NativeBoost does the lookup. I looked at the way that "mmap" is called and noticed that the selector #getGlobalSymbolPointer: is being used. Resolving "munmap" with this selector succeeds while doing
NativeBoost loadSymbol: 'munmap' aName fromModule: -2
(which is what happens when the heap manager tries to call "munmap") results the stack trace shown below.
I'll keep digging...
On 15.11.2012, at 17:20, Max Leske <maxleske(a)gmail.com> wrote:
> Hi
>
> When NativeBoost tries to call munmap to free a page (happens because a pointer I freed was the last reserved one in that page) it will throw a NBFFICalloutError (every time) because (I think) it can't find the symbol. I have absolutely no clue how to fix this so I'm in need of help.
>
> System: OS X 10.8.2
> Image: 1.4
> NativeBoost-Core: CamilloBruni.80 (Installed by using the latest NBInstaller)
>
> Cheers,
> Max
>
> Here's the stack:
>
> 15 November 2012 5:04:23.895 pm
>
> VM: Mac OS - intel - 1082 - NBCoInterpreter NativeBoost-CogPlugin-IgorStasenko.14 uuid: da3a649c-e2b2-bd4c-aa2f-9c2ebdb2658a Oct 26 2012, StackToRegisterMappingCogit VMMaker-oscog-EstebanLorenzano.164 uuid: d77dee73-00f5-4d00-847b-00646b08329d Oct 26 2012, git://gitorious.org/cogvm/blessed.git Commit: 48af8595004fd0ec3a3ac6d44c3d7516a87981ca Date: 2012-10-24 16:56:20 +0200 By: Igor Stasenko <siguctua(a)gmail.com> Jenkins build #131
> Image: Pharo1.4 [Latest update: #14457]
>
> NBFFICallout class>>signalError:
> Receiver: NBFFICallout
> Arguments and temporary variables:
> errorCode: 1
> Receiver's instance variables:
> superclass: NBNativeCodeGen
> methodDict: a MethodDictionary(#aliasForType:->(NBFFICallout>>#aliasForType: "a...etc...
> format: 148
> instanceVariables: #('fnSpec' 'requestor' 'methodArgs' 'coercionMayFail' 'callI...etc...
> organization: ('type aliases' aliasForType:)
> ('accessing' anonSpec: callType: c...etc...
> subclasses: {NBNativeFunctionGen}
> name: #NBFFICallout
> classPool: a Dictionary(#CustomErrorCodes->a Dictionary(600->'An instance of NB...etc...
> sharedPools: nil
> environment: a SystemDictionary(lots of globals)
> category: #'NativeBoost-Core-FFI'
> traitComposition: {}
> localSelectors: nil
>
> NBFFICallout class(NBNativeCodeGen class)>>handleFailureIn:nativeCode:
> Receiver: NBFFICallout
> Arguments and temporary variables:
> aContext: NativeBoostMac32(NativeBoost)>>bootstrapLoadSymbol:ofLength:fromModul...etc...
> aBlock: [:gen | gen useEmitCall; sender: sender; parseOptions: anOptions; cdecl...etc...
> method: (NativeBoost>>#bootstrapLoadSymbol:ofLength:fromModule:into: "a Compile...etc...
> lastError: 1
> Receiver's instance variables:
> superclass: NBNativeCodeGen
> methodDict: a MethodDictionary(#aliasForType:->(NBFFICallout>>#aliasForType: "a...etc...
> format: 148
> instanceVariables: #('fnSpec' 'requestor' 'methodArgs' 'coercionMayFail' 'callI...etc...
> organization: ('type aliases' aliasForType:)
> ('accessing' anonSpec: callType: c...etc...
> subclasses: {NBNativeFunctionGen}
> name: #NBFFICallout
> classPool: a Dictionary(#CustomErrorCodes->a Dictionary(600->'An instance of NB...etc...
> sharedPools: nil
> environment: a SystemDictionary(lots of globals)
> category: #'NativeBoost-Core-FFI'
> traitComposition: {}
> localSelectors: nil
>
> NBFFICallout class>>cdecl:emitCall:options:
> Receiver: NBFFICallout
> Arguments and temporary variables:
> functionSpec: #(#NBBootstrapUlong #(#byte #* #symbolName #, #long #symbolLen #,...etc...
> aCallEmittingBlock: [:gen | gen proxy callFn: #ioLoadSymbol:OfLength:FromModule...etc...
> anOptions: #(#- #optDirectProxyFnAddress #optAllowExternalAddressPtr)
> sender: NativeBoostMac32(NativeBoost)>>bootstrapLoadSymbol:ofLength:fromModule:...etc...
> Receiver's instance variables:
> superclass: NBNativeCodeGen
> methodDict: a MethodDictionary(#aliasForType:->(NBFFICallout>>#aliasForType: "a...etc...
> format: 148
> instanceVariables: #('fnSpec' 'requestor' 'methodArgs' 'coercionMayFail' 'callI...etc...
> organization: ('type aliases' aliasForType:)
> ('accessing' anonSpec: callType: c...etc...
> subclasses: {NBNativeFunctionGen}
> name: #NBFFICallout
> classPool: a Dictionary(#CustomErrorCodes->a Dictionary(600->'An instance of NB...etc...
> sharedPools: nil
> environment: a SystemDictionary(lots of globals)
> category: #'NativeBoost-Core-FFI'
> traitComposition: {}
> localSelectors: nil
>
> NativeBoostMac32(NativeBoost)>>bootstrapLoadSymbol:ofLength:fromModule:into:
> Receiver: a NativeBoostMac32
> Arguments and temporary variables:
> symbolName: 'munmap'
> symbolLen: 6
> moduleHandle: -2
> returnValueBuffer: #[0 0 0 0 0 0 0 0]
> Receiver's instance variables:
> bootstrapping: false
> insideCallback: nil
> callbackCounterAddr: @ 16r5F74000
> extraRootsRegistry: a NBExtraRootsRegistry
> rootsCell: @ 16r5F7402A
> gateFunction: @ 16r5F74004
> heap: a NBMacExternalHeapManager
>
> NativeBoostMac32(NativeBoost)>>loadSymbol:fromModule:
> Receiver: a NativeBoostMac32
> Arguments and temporary variables:
> aSymbolName: 'munmap'
> moduleName: -2
> bytes: #[0 0 0 0 0 0 0 0]
> module: -2
> handle: nil
> Receiver's instance variables:
> bootstrapping: false
> insideCallback: nil
> callbackCounterAddr: @ 16r5F74000
> extraRootsRegistry: a NBExtraRootsRegistry
> rootsCell: @ 16r5F7402A
> gateFunction: @ 16r5F74004
> heap: a NBMacExternalHeapManager
>
> NativeBoostMac32(NativeBoostLinux32)>>loadSymbol:fromModule:
> Receiver: a NativeBoostMac32
> Arguments and temporary variables:
> aSymbolName: 'munmap'
> moduleName: -2
> Receiver's instance variables:
> bootstrapping: false
> insideCallback: nil
> callbackCounterAddr: @ 16r5F74000
> extraRootsRegistry: a NBExtraRootsRegistry
> rootsCell: @ 16r5F7402A
> gateFunction: @ 16r5F74004
> heap: a NBMacExternalHeapManager
>
> NativeBoost class>>loadSymbol:fromModule:
> Receiver: NativeBoost
> Arguments and temporary variables:
> aSymbolName: 'munmap'
> moduleName: -2
> Receiver's instance variables:
> superclass: Object
> methodDict: a MethodDictionary(#CLibrary->(NativeBoost>>#CLibrary "a CompiledMe...etc...
> format: 142
> instanceVariables: #('bootstrapping' 'insideCallback' 'callbackCounterAddr' 'ex...etc...
> organization: ('retrieving symbols' CLibrary VMModule ioLoadFunction:from: ioLo...etc...
> subclasses: {NativeBoostLinux32. NativeBoostWin32}
> name: #NativeBoost
> classPool: a Dictionary(#Current->a NativeBoostMac32 #NBAnnouncer->an Announcer...etc...
> sharedPools: an OrderedCollection(AJx86Registers NativeBoostConstants)
> environment: a SystemDictionary(lots of globals)
> category: #'NativeBoost-Core'
> traitComposition: {}
> localSelectors: nil
>
> NBMacExternalHeapManager class(Object)>>nbGetSymbolAddress:module:
> Receiver: NBMacExternalHeapManager
> Arguments and temporary variables:
> aName: 'munmap'
> aModuleNameOrHandle: -2
> addr: nil
> Receiver's instance variables:
> superclass: NBExternalHeapManager
> methodDict: a MethodDictionary(#mapFlags->(NBMacExternalHeapManager>>#mapFlags ...etc...
> format: 138
> instanceVariables: nil
> organization: ('as yet unclassified' mapFlags mmapLength:prot:flags:into: primA...etc...
> subclasses: nil
> name: #NBMacExternalHeapManager
> classPool: nil
> sharedPools: an OrderedCollection(NBMacConstants)
> environment: a SystemDictionary(lots of globals)
> category: #'NativeBoost-Mac'
> traitComposition: {}
> localSelectors: nil
>
> [:gen |
> fnAddress := requestor nbGetSymbolAddress: fnSpec functionName module: aModuleNameOrHandle.
> fnAddress
> ifNil: [self error: 'function unavailable'].
> self optMayGC
> ifTrue: [asm push: fnAddress asUImm32;
> mov: NativeBoost callgateFunctionAddress asUImm32 to: EAX;
> call: EAX]
> ifFalse: [asm mov: fnAddress asUImm32 to: EAX;
> call: EAX]] in NBFFICallout>>generateCall:module:
> Receiver: a NBFFICallout
> Arguments and temporary variables:
> aModuleNameOrHandle: a NBFFICallout
> fnAddress: -2
> gen: #(nil)
> Receiver's instance variables:
> asm: an AJx86Assembler
> proxy: a NBInterpreterProxy
> options: a Set(#optCdecl #optAllowByteArraysPtr #optUseStackPointer #optReturnP...etc...
> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
> fnSpec: a NBFnSpec
> requestor: NBMacExternalHeapManager
> methodArgs: an OrderedCollection('addr' 'len')
> coercionMayFail: true
> callInfo: an AJCdeclCallInfo
>
> BlockClosure>>valueWithPossibleArgs:
> Receiver: [:gen |
> fnAddress := requestor nbGetSymbolAddress: fnSpec functionName module: aModuleNam...etc...
> Arguments and temporary variables:
> anArray: an Array(a NBFFICallout a NBInterpreterProxy an AJx86Assembler)
> Receiver's instance variables:
> outerContext: NBFFICallout>>generateCall:module:
> startpc: 91
> numArgs: 1
>
> [aFunctionBodyBlock valueWithPossibleArgs: {self. proxy. asm}.
> (self optEmitCall
> or: [self optNoCleanup])
> ifTrue: [call disableCleanup]] in [:call |
> self optNoAlignment
> ifTrue: [call alignment: 1].
> self pushArguments.
> coercionMayFail
> ifTrue: [proxy ifFailedJumpTo: self failedLabel].
> asm
> decorateWith: 'FFI: performing a call'
> during: [aFunctionBodyBlock valueWithPossibleArgs: {self. proxy. asm}.
> (self optEmitCall
> or: [self optNoCleanup])
> ifTrue: [call disableCleanup]]] in NBFFICallout>>generateInstructions:
> Receiver: a NBFFICallout
> Arguments and temporary variables:
> aFunctionBodyBlock: an AJCdeclCallInfo
> call: [:gen |
> fnAddress := requestor nbGetSymbolAddress: fnSpec functionName m...etc...
> Receiver's instance variables:
> asm: an AJx86Assembler
> proxy: a NBInterpreterProxy
> options: a Set(#optCdecl #optAllowByteArraysPtr #optUseStackPointer #optReturnP...etc...
> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
> fnSpec: a NBFnSpec
> requestor: NBMacExternalHeapManager
> methodArgs: an OrderedCollection('addr' 'len')
> coercionMayFail: true
> callInfo: an AJCdeclCallInfo
>
> BlockClosure>>ensure:
> Receiver: [aFunctionBodyBlock valueWithPossibleArgs: {self. proxy. asm}.
> (self optEmitCall
> or: [...etc...
> Arguments and temporary variables:
> aBlock: [level := level - 1.
> self
> addInstruction: (AJInstructionDecoration n...etc...
> complete: nil
> returnValue: nil
> Receiver's instance variables:
> outerContext: [:call |
> self optNoAlignment
> ifTrue: [call alignment: 1].
> sel...etc...
> startpc: 155
> numArgs: 0
>
> AJx86Assembler>>decorateWith:during:
> Receiver: an AJx86Assembler
> Arguments and temporary variables:
> annotation: 'FFI: performing a call'
> aBlock: [aFunctionBodyBlock valueWithPossibleArgs: {self. proxy. asm}.
> (self o...etc...
> Receiver's instance variables:
> instructions: <<error during printing>>
>
> [:call |
> self optNoAlignment
> ifTrue: [call alignment: 1].
> self pushArguments.
> coercionMayFail
> ifTrue: [proxy ifFailedJumpTo: self failedLabel].
> asm
> decorateWith: 'FFI: performing a call'
> during: [aFunctionBodyBlock valueWithPossibleArgs: {self. proxy. asm}.
> (self optEmitCall
> or: [self optNoCleanup])
> ifTrue: [call disableCleanup]]] in NBFFICallout>>generateInstructions:
> Receiver: a NBFFICallout
> Arguments and temporary variables:
> aFunctionBodyBlock: an AJCdeclCallInfo
> call: [:gen |
> fnAddress := requestor nbGetSymbolAddress: fnSpec functionName m...etc...
> Receiver's instance variables:
> asm: an AJx86Assembler
> proxy: a NBInterpreterProxy
> options: a Set(#optCdecl #optAllowByteArraysPtr #optUseStackPointer #optReturnP...etc...
> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
> fnSpec: a NBFnSpec
> requestor: NBMacExternalHeapManager
> methodArgs: an OrderedCollection('addr' 'len')
> coercionMayFail: true
> callInfo: an AJCdeclCallInfo
>
> AJx86Assembler>>performingCall:in:
> Receiver: an AJx86Assembler
> Arguments and temporary variables:
> ci: an AJCdeclCallInfo
> aBlock: [:call |
> self optNoAlignment
> ifTrue: [call alignment: 1].
> self push...etc...
> Receiver's instance variables:
> instructions: <<error during printing>>
>
> NBFFICallout>>foreignCall:
> Receiver: a NBFFICallout
> Arguments and temporary variables:
> aBlock: [:call |
> self optNoAlignment
> ifTrue: [call alignment: 1].
> self push...etc...
> Receiver's instance variables:
> asm: an AJx86Assembler
> proxy: a NBInterpreterProxy
> options: a Set(#optCdecl #optAllowByteArraysPtr #optUseStackPointer #optReturnP...etc...
> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
> fnSpec: a NBFnSpec
> requestor: NBMacExternalHeapManager
> methodArgs: an OrderedCollection('addr' 'len')
> coercionMayFail: true
> callInfo: an AJCdeclCallInfo
>
> NBFFICallout>>generateInstructions:
> Receiver: a NBFFICallout
> Arguments and temporary variables:
> aFunctionBodyBlock: [:gen |
> fnAddress := requestor nbGetSymbolAddress: fnSpec ...etc...
> instructions: nil
> Receiver's instance variables:
> asm: an AJx86Assembler
> proxy: a NBInterpreterProxy
> options: a Set(#optCdecl #optAllowByteArraysPtr #optUseStackPointer #optReturnP...etc...
> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
> fnSpec: a NBFnSpec
> requestor: NBMacExternalHeapManager
> methodArgs: an OrderedCollection('addr' 'len')
> coercionMayFail: true
> callInfo: an AJCdeclCallInfo
>
> NBFFICallout>>generate:
> Receiver: a NBFFICallout
> Arguments and temporary variables:
> aFunctionBodyBlock: [:gen |
> fnAddress := requestor nbGetSymbolAddress: fnSpec ...etc...
> generatedCode: nil
> Receiver's instance variables:
> asm: an AJx86Assembler
> proxy: a NBInterpreterProxy
> options: a Set(#optCdecl #optAllowByteArraysPtr #optUseStackPointer #optReturnP...etc...
> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
> fnSpec: a NBFnSpec
> requestor: NBMacExternalHeapManager
> methodArgs: an OrderedCollection('addr' 'len')
> coercionMayFail: true
> callInfo: an AJCdeclCallInfo
>
> NBFFICallout>>generateCall:module:
> Receiver: a NBFFICallout
> Arguments and temporary variables:
> functionSpec: #(#int #munmap #(#uint #addr #, #ulong #len))
> aModuleNameOrHandle: -2
> fnAddress: #(nil)
> Receiver's instance variables:
> asm: an AJx86Assembler
> proxy: a NBInterpreterProxy
> options: a Set(#optCdecl #optAllowByteArraysPtr #optUseStackPointer #optReturnP...etc...
> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
> fnSpec: a NBFnSpec
> requestor: NBMacExternalHeapManager
> methodArgs: an OrderedCollection('addr' 'len')
> coercionMayFail: true
> callInfo: an AJCdeclCallInfo
>
> [:gen | gen sender: sender;
> cdecl;
> generateCall: functionSpec module: aModuleName] in NBFFICallout class>>cdecl:module:
> Receiver: NBFFICallout
> Arguments and temporary variables:
> functionSpec: a NBFFICallout
> aModuleName: #(#int #munmap #(#uint #addr #, #ulong #len))
> sender: -2
> gen: NBMacExternalHeapManager>>unmap:length:
> Receiver's instance variables:
> superclass: NBNativeCodeGen
> methodDict: a MethodDictionary(#aliasForType:->(NBFFICallout>>#aliasForType: "a...etc...
> format: 148
> instanceVariables: #('fnSpec' 'requestor' 'methodArgs' 'coercionMayFail' 'callI...etc...
> organization: ('type aliases' aliasForType:)
> ('accessing' anonSpec: callType: c...etc...
> subclasses: {NBNativeFunctionGen}
> name: #NBFFICallout
> classPool: a Dictionary(#CustomErrorCodes->a Dictionary(600->'An instance of NB...etc...
> sharedPools: nil
> environment: a SystemDictionary(lots of globals)
> category: #'NativeBoost-Core-FFI'
> traitComposition: {}
> localSelectors: nil
>
> [bytes := aBlock
> value: (self newForMethod: method)] in NBFFICallout class(NBNativeCodeGen class)>>generateCode:andRetry:
> Receiver: NBFFICallout
> Arguments and temporary variables:
> aBlock: [:gen | gen sender: sender;
> cdecl;
> generateCall: functionSpec mod...etc...
> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
> bytes: #(nil)
> Receiver's instance variables:
> superclass: NBNativeCodeGen
> methodDict: a MethodDictionary(#aliasForType:->(NBFFICallout>>#aliasForType: "a...etc...
> format: 148
> instanceVariables: #('fnSpec' 'requestor' 'methodArgs' 'coercionMayFail' 'callI...etc...
> organization: ('type aliases' aliasForType:)
> ('accessing' anonSpec: callType: c...etc...
> subclasses: {NBNativeFunctionGen}
> name: #NBFFICallout
> classPool: a Dictionary(#CustomErrorCodes->a Dictionary(600->'An instance of NB...etc...
> sharedPools: nil
> environment: a SystemDictionary(lots of globals)
> category: #'NativeBoost-Core-FFI'
> traitComposition: {}
> localSelectors: nil
>
> BlockClosure>>on:do:
> Receiver: [bytes := aBlock
> value: (self newForMethod: method)]
> Arguments and temporary variables:
> exception: NBRecursionDetect
> handlerAction: [:ex | ex check: aMethod]
> handlerActive: true
> Receiver's instance variables:
> outerContext: NBFFICallout class(NBNativeCodeGen class)>>generateCode:andRetry:...etc...
> startpc: 96
> numArgs: 0
>
> NBRecursionDetect class>>in:during:
> Receiver: NBRecursionDetect
> Arguments and temporary variables:
> aMethod: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)...etc...
> aBlock: [bytes := aBlock
> value: (self newForMethod: method)]
> Receiver's instance variables:
> superclass: Notification
> methodDict: a MethodDictionary(#check:->(NBRecursionDetect>>#check: "a Compiled...etc...
> format: 144
> instanceVariables: #('method')
> organization: ('as yet unclassified' check: defaultAction method signalForMetho...etc...
> subclasses: nil
> name: #NBRecursionDetect
> classPool: nil
> sharedPools: nil
> environment: a SystemDictionary(lots of globals)
> category: #'NativeBoost-Core-Errors'
> traitComposition: {}
> localSelectors: nil
>
> NBFFICallout class(NBNativeCodeGen class)>>generateCode:andRetry:
> Receiver: NBFFICallout
> Arguments and temporary variables:
> aBlock: [:gen | gen sender: sender;
> cdecl;
> generateCall: functionSpec mod...etc...
> retryCtx: NBMacExternalHeapManager>>unmap:length:
> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
> newMethod: nil
> args: nil
> bytes: #(nil)
> Receiver's instance variables:
> superclass: NBNativeCodeGen
> methodDict: a MethodDictionary(#aliasForType:->(NBFFICallout>>#aliasForType: "a...etc...
> format: 148
> instanceVariables: #('fnSpec' 'requestor' 'methodArgs' 'coercionMayFail' 'callI...etc...
> organization: ('type aliases' aliasForType:)
> ('accessing' anonSpec: callType: c...etc...
> subclasses: {NBNativeFunctionGen}
> name: #NBFFICallout
> classPool: a Dictionary(#CustomErrorCodes->a Dictionary(600->'An instance of NB...etc...
> sharedPools: nil
> environment: a SystemDictionary(lots of globals)
> category: #'NativeBoost-Core-FFI'
> traitComposition: {}
> localSelectors: nil
>
> NBFFICallout class(NBNativeCodeGen class)>>handleFailureIn:nativeCode:
> Receiver: NBFFICallout
> Arguments and temporary variables:
> aContext: NBMacExternalHeapManager>>unmap:length:
> aBlock: [:gen | gen sender: sender;
> cdecl;
> generateCall: functionSpec mod...etc...
> method: (NBMacExternalHeapManager>>#unmap:length: "a CompiledMethod(355205120)"...etc...
> lastError: 502
> Receiver's instance variables:
> superclass: NBNativeCodeGen
> methodDict: a MethodDictionary(#aliasForType:->(NBFFICallout>>#aliasForType: "a...etc...
> format: 148
> instanceVariables: #('fnSpec' 'requestor' 'methodArgs' 'coercionMayFail' 'callI...etc...
> organization: ('type aliases' aliasForType:)
> ('accessing' anonSpec: callType: c...etc...
> subclasses: {NBNativeFunctionGen}
> name: #NBFFICallout
> classPool: a Dictionary(#CustomErrorCodes->a Dictionary(600->'An instance of NB...etc...
> sharedPools: nil
> environment: a SystemDictionary(lots of globals)
> category: #'NativeBoost-Core-FFI'
> traitComposition: {}
> localSelectors: nil
>
> NBFFICallout class>>cdecl:module:
> Receiver: NBFFICallout
> Arguments and temporary variables:
> functionSpec: #(#int #munmap #(#uint #addr #, #ulong #len))
> aModuleName: -2
> sender: NBMacExternalHeapManager>>unmap:length:
> Receiver's instance variables:
> superclass: NBNativeCodeGen
> methodDict: a MethodDictionary(#aliasForType:->(NBFFICallout>>#aliasForType: "a...etc...
> format: 148
> instanceVariables: #('fnSpec' 'requestor' 'methodArgs' 'coercionMayFail' 'callI...etc...
> organization: ('type aliases' aliasForType:)
> ('accessing' anonSpec: callType: c...etc...
> subclasses: {NBNativeFunctionGen}
> name: #NBFFICallout
> classPool: a Dictionary(#CustomErrorCodes->a Dictionary(600->'An instance of NB...etc...
> sharedPools: nil
> environment: a SystemDictionary(lots of globals)
> category: #'NativeBoost-Core-FFI'
> traitComposition: {}
> localSelectors: nil
>
> NBMacExternalHeapManager>>unmap:length:
> Receiver: a NBMacExternalHeapManager
> Arguments and temporary variables:
> addr: 7380992
> len: 32768
> errorCode: 502
> Receiver's instance variables:
> pages: a Dictionary(24981504->a NBMemoryPage 100089856->a NBMemoryPage )
> freeBlocks: an IdentitySet(a NBMemoryBlock( @ 16r17D302E, 17, free) a NBMemoryB...etc...
> reservedBlocks: a Dictionary(24981504->a NBMemoryBlock( @ 16r17D3000, 38) 24981...etc...
> sema: a Semaphore()
>
> NBMacExternalHeapManager>>primFreePage:
> Receiver: a NBMacExternalHeapManager
> Arguments and temporary variables:
> aMemoryPage: a NBMemoryPage
> res: nil
> Receiver's instance variables:
> pages: a Dictionary(24981504->a NBMemoryPage 100089856->a NBMemoryPage )
> freeBlocks: an IdentitySet(a NBMemoryBlock( @ 16r17D302E, 17, free) a NBMemoryB...etc...
> reservedBlocks: a Dictionary(24981504->a NBMemoryBlock( @ 16r17D3000, 38) 24981...etc...
> sema: a Semaphore()
>
> NBMacExternalHeapManager(NBExternalHeapManager)>>freePage:
> Receiver: a NBMacExternalHeapManager
> Arguments and temporary variables:
> aMemoryPage: a NBMemoryPage
> Receiver's instance variables:
> pages: a Dictionary(24981504->a NBMemoryPage 100089856->a NBMemoryPage )
> freeBlocks: an IdentitySet(a NBMemoryBlock( @ 16r17D302E, 17, free) a NBMemoryB...etc...
> reservedBlocks: a Dictionary(24981504->a NBMemoryBlock( @ 16r17D3000, 38) 24981...etc...
> sema: a Semaphore()
>
> [:page |
> page length = aMemoryBlock length
> ifTrue: [self freePage: page.
> ^ true].
> nil] in NBMacExternalHeapManager(NBExternalHeapManager)>>checkForFreePage:
> Receiver: a NBMacExternalHeapManager
> Arguments and temporary variables:
> aMemoryBlock: a NBMemoryPage
> page: a NBMemoryBlock( @ 16r70A000, 32768, free)
> Receiver's instance variables:
> pages: a Dictionary(24981504->a NBMemoryPage 100089856->a NBMemoryPage )
> freeBlocks: an IdentitySet(a NBMemoryBlock( @ 16r17D302E, 17, free) a NBMemoryB...etc...
> reservedBlocks: a Dictionary(24981504->a NBMemoryBlock( @ 16r17D3000, 38) 24981...etc...
> sema: a Semaphore()
>
> BlockClosure>>cull:
> Receiver: [:page |
> page length = aMemoryBlock length
> ifTrue: [self freePage: page.
> ^ true].
> n...etc...
> Arguments and temporary variables:
> anArg: a NBMemoryPage
> Receiver's instance variables:
> outerContext: NBMacExternalHeapManager(NBExternalHeapManager)>>checkForFreePage...etc...
> startpc: 41
> numArgs: 1
>
> Dictionary>>at:ifPresent:
> Receiver: a Dictionary(24981504->a NBMemoryPage 100089856->a NBMemoryPage )
> Arguments and temporary variables:
> key: 7380992
> aBlock: [:page |
> page length = aMemoryBlock length
> ifTrue: [self freePage: p...etc...
> assoc: 7380992->a NBMemoryPage
> Receiver's instance variables:
> tally: 2
> array: an Array(nil 100089856->a NBMemoryPage nil nil 24981504->a NBMemoryPage)...etc...
>
> NBMacExternalHeapManager(NBExternalHeapManager)>>checkForFreePage:
> Receiver: a NBMacExternalHeapManager
> Arguments and temporary variables:
> aMemoryBlock: a NBMemoryBlock( @ 16r70A000, 32768, free)
> Receiver's instance variables:
> pages: a Dictionary(24981504->a NBMemoryPage 100089856->a NBMemoryPage )
> freeBlocks: an IdentitySet(a NBMemoryBlock( @ 16r17D302E, 17, free) a NBMemoryB...etc...
> reservedBlocks: a Dictionary(24981504->a NBMemoryBlock( @ 16r17D3000, 38) 24981...etc...
> sema: a Semaphore()
>
> NBMemoryBlock>>makeFreeFor:
> Receiver: a NBMemoryBlock( @ 16r70A030, 32720, free)
> Arguments and temporary variables:
> heapManager: a NBMacExternalHeapManager
> Receiver's instance variables:
> left: a NBMemoryBlock( @ 16r70A000, 32768, free)
> right: nil
> address: 7381040
> length: 32720
> free: true
>
> [| block |
> block := reservedBlocks
> removeKey: address
> ifAbsent: [self error: 'Unable to find a memory block with given address'].
> block makeFreeFor: self] in NBMacExternalHeapManager(NBExternalHeapManager)>>free:
> Receiver: a NBMacExternalHeapManager
> Arguments and temporary variables:
> address: 7381040
> block: a NBMemoryBlock( @ 16r70A030, 32720, free)
> Receiver's instance variables:
> pages: a Dictionary(24981504->a NBMemoryPage 100089856->a NBMemoryPage )
> freeBlocks: an IdentitySet(a NBMemoryBlock( @ 16r17D302E, 17, free) a NBMemoryB...etc...
> reservedBlocks: a Dictionary(24981504->a NBMemoryBlock( @ 16r17D3000, 38) 24981...etc...
> sema: a Semaphore()
>
> [caught := true.
> self wait.
> blockValue := mutuallyExcludedBlock value] in Semaphore>>critical:
> Receiver: a Semaphore()
> Arguments and temporary variables:
> <<error during printing>
> Receiver's instance variables:
> firstLink: nil
> lastLink: nil
> excessSignals: 0
>
> BlockClosure>>ensure:
> Receiver: [caught := true.
> self wait.
> blockValue := mutuallyExcludedBlock value]
> Arguments and temporary variables:
> aBlock: [caught
> ifTrue: [self signal]]
> complete: nil
> returnValue: nil
> Receiver's instance variables:
> outerContext: Semaphore>>critical:
> startpc: 42
> numArgs: 0
>
> Semaphore>>critical:
> Receiver: a Semaphore()
> Arguments and temporary variables:
> <<error during printing>
> Receiver's instance variables:
> firstLink: nil
> lastLink: nil
> excessSignals: 0
>
> NBMacExternalHeapManager(NBExternalHeapManager)>>free:
> Receiver: a NBMacExternalHeapManager
> Arguments and temporary variables:
> address: 7381040
> Receiver's instance variables:
> pages: a Dictionary(24981504->a NBMemoryPage 100089856->a NBMemoryPage )
> freeBlocks: an IdentitySet(a NBMemoryBlock( @ 16r17D302E, 17, free) a NBMemoryB...etc...
> reservedBlocks: a Dictionary(24981504->a NBMemoryBlock( @ 16r17D3000, 38) 24981...etc...
> sema: a Semaphore()
>
>
> --- The full stack ---
> NBFFICallout class>>signalError:
> NBFFICallout class(NBNativeCodeGen class)>>handleFailureIn:nativeCode:
> NBFFICallout class>>cdecl:emitCall:options:
> NativeBoostMac32(NativeBoost)>>bootstrapLoadSymbol:ofLength:fromModule:into:
> NativeBoostMac32(NativeBoost)>>loadSymbol:fromModule:
> NativeBoostMac32(NativeBoostLinux32)>>loadSymbol:fromModule:
> NativeBoost class>>loadSymbol:fromModule:
> NBMacExternalHeapManager class(Object)>>nbGetSymbolAddress:module:
> [:gen |
> fnAddress := requestor nbGetSymbolAddress: fnSpec functionName module: aModuleNameOrHandle.
> fnAddress
> ifNil: [self error: 'function unavailable'].
> self optMayGC
> ifTrue: [asm push: fnAddress asUImm32;
> mov: NativeBoost callgateFunctionAddress asUImm32 to: EAX;
> call: EAX]
> ifFalse: [asm mov: fnAddress asUImm32 to: EAX;
> call: EAX]] in NBFFICallout>>generateCall:module:
> BlockClosure>>valueWithPossibleArgs:
> [aFunctionBodyBlock valueWithPossibleArgs: {self. proxy. asm}.
> (self optEmitCall
> or: [self optNoCleanup])
> ifTrue: [call disableCleanup]] in [:call |
> self optNoAlignment
> ifTrue: [call alignment: 1].
> self pushArguments.
> coercionMayFail
> ifTrue: [proxy ifFailedJumpTo: self failedLabel].
> asm
> decorateWith: 'FFI: performing a call'
> during: [aFunctionBodyBlock valueWithPossibleArgs: {self. proxy. asm}.
> (self optEmitCall
> or: [self optNoCleanup])
> ifTrue: [call disableCleanup]]] in NBFFICallout>>generateInstructions:
> BlockClosure>>ensure:
> AJx86Assembler>>decorateWith:during:
> [:call |
> self optNoAlignment
> ifTrue: [call alignment: 1].
> self pushArguments.
> coercionMayFail
> ifTrue: [proxy ifFailedJumpTo: self failedLabel].
> asm
> decorateWith: 'FFI: performing a call'
> during: [aFunctionBodyBlock valueWithPossibleArgs: {self. proxy. asm}.
> (self optEmitCall
> or: [self optNoCleanup])
> ifTrue: [call disableCleanup]]] in NBFFICallout>>generateInstructions:
> AJx86Assembler>>performingCall:in:
> NBFFICallout>>foreignCall:
> NBFFICallout>>generateInstructions:
> NBFFICallout>>generate:
> NBFFICallout>>generateCall:module:
> [:gen | gen sender: sender;
> cdecl;
> generateCall: functionSpec module: aModuleName] in NBFFICallout class>>cdecl:module:
> [bytes := aBlock
> value: (self newForMethod: method)] in NBFFICallout class(NBNativeCodeGen class)>>generateCode:andRetry:
> BlockClosure>>on:do:
> NBRecursionDetect class>>in:during:
> NBFFICallout class(NBNativeCodeGen class)>>generateCode:andRetry:
> NBFFICallout class(NBNativeCodeGen class)>>handleFailureIn:nativeCode:
> NBFFICallout class>>cdecl:module:
> NBMacExternalHeapManager>>unmap:length:
> NBMacExternalHeapManager>>primFreePage:
> NBMacExternalHeapManager(NBExternalHeapManager)>>freePage:
> [:page |
> page length = aMemoryBlock length
> ifTrue: [self freePage: page.
> ^ true].
> nil] in NBMacExternalHeapManager(NBExternalHeapManager)>>checkForFreePage:
> BlockClosure>>cull:
> Dictionary>>at:ifPresent:
> NBMacExternalHeapManager(NBExternalHeapManager)>>checkForFreePage:
> NBMemoryBlock>>makeFreeFor:
> [| block |
> block := reservedBlocks
> removeKey: address
> ifAbsent: [self error: 'Unable to find a memory block with given address'].
> block makeFreeFor: self] in NBMacExternalHeapManager(NBExternalHeapManager)>>free:
> [caught := true.
> self wait.
> blockValue := mutuallyExcludedBlock value] in Semaphore>>critical:
> BlockClosure>>ensure:
> Semaphore>>critical:
> NBMacExternalHeapManager(NBExternalHeapManager)>>free:
> - - - - - - - - - - - - - - -
> - - - - - - - - - - - - - - - - - -
> NativeBoostMac32(NativeBoostLinux32)>>free:
> NativeBoost class>>free:
> NBExternalAddress>>free
> [:pointer | pointer value free] in LimboCommand>>freePointers
> Set>>do:
> LimboCommand>>freePointers
> [self freePointers] in LimboCommand>>run
> BlockClosure>>ensure:
> LimboCommand>>run
> Limbo>>run:arguments:
> Limbo>>runSh:
> Limbo class>>runSh:
> [limbo := Limbo runSh: '/bin/echo ' , arg] in LimboTest>>testShellCommandWithNewLines
> [aBlock value.
> false] in LimboTest(TestCase)>>executeShould:inScopeOf:
> BlockClosure>>on:do:
> LimboTest(TestCase)>>executeShould:inScopeOf:
> LimboTest(TestCase)>>shouldnt:raise:
> LimboTest>>testShellCommandWithNewLines
> LimboTest(TestCase)>>performTest
> [self setUp.
> self performTest] in LimboTest(TestCase)>>runCase
> BlockClosure>>ensure:
> LimboTest(TestCase)>>runCase
> [(self class selector: testSelector) runCase] in LimboTest(TestCase)>>debug
> BlockClosure>>ensure:
> LimboTest(TestCase)>>debug
> OBCmdRunTests>>execute
> [:each |
> (each isActive
> and: [each isEnabled])
> ifTrue: [each execute.
> ^ true].
> nil] in OBNodeCommandScan(OBCommandScan)>>processKeystroke:withNode:for:
> OrderedCollection>>do:
> OBNodeCommandScan(OBCommandScan)>>processKeystroke:withNode:for:
> [:each |
> (scan
> processKeystroke: aCharacter asKeystroke
> withNode: each
> for: self)
> ifTrue: [^ self].
> nil] in OBColumn>>keystroke:from:
> OrderedCollection>>reverseDo:
> OBColumn>>keystroke:from:
> OBPluggableListMorph(PluggableListMorph)>>modifierKeyPressed:
> OBPluggableListMorph(PluggableListMorph)>>keyStroke:
> OBPluggableListMorph(Morph)>>handleKeystroke:
> KeyboardEvent>>sentTo:
> OBPluggableListMorph(Morph)>>handleEvent:
> MorphicEventDispatcher>>dispatchDefault:with:
> MorphicEventDispatcher>>dispatchEvent:with:
> OBPluggableListMorph(Morph)>>processEvent:using:
> OBPluggableListMorph(Morph)>>processEvent:
> OBPluggableListMorph(PluggableListMorph)>>handleFocusEvent:
> [ActiveHand := self.
> ActiveEvent := anEvent.
> result := focusHolder
> handleFocusEvent: (anEvent
> transformedBy: (focusHolder transformedFrom: self))] in HandMorph>>sendFocusEvent:to:clear:
> [aBlock value] in PasteUpMorph>>becomeActiveDuring:
> BlockClosure>>on:do:
> PasteUpMorph>>becomeActiveDuring:
> HandMorph>>sendFocusEvent:to:clear:
> HandMorph>>sendEvent:focus:clear:
> HandMorph>>sendKeyboardEvent:
> HandMorph>>handleEvent:
> HandMorph>>processEvents
> [:h |
> ActiveHand := h.
> h processEvents.
> ActiveHand := nil] in WorldState>>doOneCycleNowFor:
> Array(SequenceableCollection)>>do:
> WorldState>>handsDo:
> WorldState>>doOneCycleNowFor:
> WorldState>>doOneCycleFor:
> PasteUpMorph>>doOneCycle
> [[World doOneCycle.
> Processor yield.
> false] whileFalse.
> nil] in MorphicUIManager>>spawnNewProcess
> [self value.
> Processor terminateActive] in BlockClosure>>newProcess
>
Nov. 16, 2012
Re: [Pharo-project] Package-pane (or 6-paned) browser for Pharo?
by Goubier Thierry
Hi Travis,
there is also an experimental tree-based system browser here :
http://ss3.gemstone.com/ss/Alt-Browser.html
It goes all the way towards removing all the panes, starting with
regrouping packages in groups based on prefix or categories, all the way
to system categories.
It's usable on Pharo 2.0; I'm planning to tie it completely with RB so
that everything you do with it appear as a RB undoable change
Thierry
Le 16/11/2012 13:45, Stéphane Ducasse a écrit :
> Hi Travis
>
> Welcome :)
>
> Have a look at Nautilus in Pharo20. It supports groups, packages, categories, refactoringsâ¦.
> Multiple selection, multiple method browsing. Nautilus has a plugin architecture. Pavel wrote periscope to suport fast navigation.
>
> Since we changed a lot the package structure + announcements, currently packages are not displayed with trees but this was the plan.
> Ben was waiting that we stop changing everything and we are getting there.
> Esteban will probably rewrite using spec.
>
> Stef
>
>
>> I'm just moving to pharo, and wanted to port the "package-pane browser" that I originally wrote for Smalltalk-80 and then ported to Squeak. The squeak code obviously doesn't run in pharo, and I wanted to ask whether anyone had already ported it (or something like it).
>>
>> Basically, the tool is just like the standard system browser, except that it parses the class category names into a 2-level hierarchy, making the top-level list much smaller and more manageable (see the screen shot below).
>>
>> Does this already exist?
>>
>> ...any reply appreciated...
>>
>> stp
>>
>>
>> <6-paned-browser.jpg>
>>
>> --
>>
>> Stephen Travis Pope Santa Barbara, California, USA http://HeavenEverywhere.com
>> <pastedGraphic.tiff>
>>
>
>
>
>
--
Thierry Goubier
CEA list
Laboratoire des Fondations des Systèmes Temps Réel Embarqués
91191 Gif sur Yvette Cedex
France
Phone/Fax: +33 (0) 1 69 08 32 92 / 83 95
Nov. 16, 2012
Re: [Pharo-project] Pharo Association
by Stéphane Ducasse
On Nov 16, 2012, at 8:49 AM, Ben Coman wrote:
>
> Well done getting all this up an running. Some minor feedback on the web siteâ¦
Thanks for the feedback.
Yes you are right :)
This is why it is a beta :)
>
> 1. I would guess that one of the more important purposes of the site is that people sign up. So don't hide the signup and login buttons away from the the front page. There is room on the right hand side of the title bar.
> Once logged in these could change to the membername and logout button.
>
> 2. Paypal says the payment transaction will appear on my bank statement as "PayPal*ASSOCIATION". I guess that because the payment goes to "Association Pharo".
> It would be nicer if the payment when to "Pharo Association" so that my bank statement said "PayPal*PHARO" - but I don't expect you could change that.
>
> 3. When choosing subscription type, the term "_simple_ member" to distinguish from "premium member" feels a bit condescending and unnecessary. Just "member" on its own is enough to distinguish from "premium member".
>
> simple = *2. *A fool; a simpleton.[1] /b //(1)/ *:* stupid <http://www.merriam-webster.com/dictionary/stupid> /(2)/ *:* mentally retarded [2]
> [1] http://www.thefreedictionary.com/simple
> [2] http://www.merriam-webster.com/dictionary/simple
Thanks indeed this is not the point.
> 4. Perhaps when members add contribution for display on the slide show, these could be added to the "What's new" sidebar. This might help increase the show of activity.
Yes.
In fact for version 2 (not 1.0) we want to offer a blog to each member and aggregating.
> As an aside, I love the name "Pharo" for the project but it is unfortunate that "Pharo" is such a widely used name with 3,000,000 unrealated results on google search, and "pharo.com" domain being used for other purposes. A tip for others making up new project names is to choose one with a small number of results on Google. A service like http://wordoid.com/ can help.
We checked google before when we decided and we love that name.
>
> Marcus Denker wrote:
>> Hello,
>>
>> We are happy to announce the Pharo User Association:
>>
>> http://association.pharo.org
>>
>> The goal of the Pharo User Association is to support Pharo development and
>> promotion.
>> There are two individual memberships
>>
>> - Individual Pharo Association Member: Yearly fee 40 Euros
>> - Golden Individual Pharo Association Member: Yearly fee 99 Euros
>>
>> You will get
>> - reduction access to pharo conferences,
>> - reduction for training and access to teaching material,
>> - be part of the pharoAssociation-individual-members mailing-list,
>> - an account at the pharo association web site.
>>
>> This Association is complementary to the Pharo consortium managed by INRIA. The Consortium is for entities such as companies, research teams, or institutes.
>> For more information, see: http://www.pharo-project.org/community/consortium
>>
>> The funds collected by the Association will be used in coordination with the Consortium to support the development of Pharo.
>>
>> The Pharo Board and Pharo Core Team.
>>
>>
>>
>>
>
>
Nov. 16, 2012
Re: [Pharo-project] Package-pane (or 6-paned) browser for Pharo?
by Stéphane Ducasse
Hi Travis
Welcome :)
Have a look at Nautilus in Pharo20. It supports groups, packages, categories, refactoringsâ¦.
Multiple selection, multiple method browsing. Nautilus has a plugin architecture. Pavel wrote periscope to suport fast navigation.
Since we changed a lot the package structure + announcements, currently packages are not displayed with trees but this was the plan.
Ben was waiting that we stop changing everything and we are getting there.
Esteban will probably rewrite using spec.
Stef
> I'm just moving to pharo, and wanted to port the "package-pane browser" that I originally wrote for Smalltalk-80 and then ported to Squeak. The squeak code obviously doesn't run in pharo, and I wanted to ask whether anyone had already ported it (or something like it).
>
> Basically, the tool is just like the standard system browser, except that it parses the class category names into a 2-level hierarchy, making the top-level list much smaller and more manageable (see the screen shot below).
>
> Does this already exist?
>
> ...any reply appreciated...
>
> stp
>
>
> <6-paned-browser.jpg>
>
> --
>
> Stephen Travis Pope Santa Barbara, California, USA http://HeavenEverywhere.com
> <pastedGraphic.tiff>
>
Nov. 16, 2012
[Pharo-project] [update 2.0] #20399
by Marcus Denker
20399
-----
Issue 6929: Undeclared ManifestManifestResourcesTests
http://code.google.com/p/pharo/issues/detail?id=6929
Issue 6982: debugging an empty method raises an error
http://code.google.com/p/pharo/issues/detail?id=6982
Issue 6979: LoggingSystemProgressItemMorph and Job>>#loggingProgress shuld be deprecate
http://code.google.com/p/pharo/issues/detail?id=6979
Issue 6980: direct use of RecentMessageList
http://code.google.com/p/pharo/issues/detail?id=6980
Issue 6976: move asUrl to Network-Url package
http://code.google.com/p/pharo/issues/detail?id=6976
Diff information:
http://ss3.gemstone.com/ss/Pharo20/System-Changes-MarcusDenker.190.diff
http://ss3.gemstone.com/ss/Pharo20/Network-Url-MarcusDenker.78.diff
http://ss3.gemstone.com/ss/Pharo20/Morphic-MarcusDenker.1280.diff
http://ss3.gemstone.com/ss/Pharo20/Manifest-Tests-MarcusDenker.23.diff
http://ss3.gemstone.com/ss/Pharo20/Kernel-MarcusDenker.1247.diff
http://ss3.gemstone.com/ss/Pharo20/FileSystem-Core-MarcusDenker.58.diff
http://ss3.gemstone.com/ss/Pharo20/Deprecated20-MarcusDenker.25.diff
--
Marcus Denker -- http://marcusdenker.de
Nov. 16, 2012