On 04/09/2011 01:37 PM, Paolo Bonzini wrote:
> On Sat, Apr 9, 2011 at 12:14, Holger Hans Peter Freyther
> <[email protected]> wrote:
>> Okay with ObjectMemory globalGarbageCollect; compact. all these objects will
>> be removed. But without these the VM looks like it will go OOM as it is
>> finalizing these objects but not removing them from memory.
>
> That's strange but possible. Do you do anything except "run a lot of queries"?
I just execute the script below. In the case where I found this I was using
the result to determine how many rows where affected (to see if the update was
successful or failed).
Do you have a hint of where I could look in oop.c? In your mental model what
should happen?
Eval [
| top |
PackageLoader fileInPackage: 'DBD-PostgreSQL'.
top := DBI.Connection
connect: 'dbi:PostgreSQL:dbname=DB;hostname=localhost'
user: 'USER' password: 'PW'.
[
[
top select: 'SELECT * FROM version()'.
] repeat.
] ensure: [
| ops o |
ObjectMemory globalGarbageCollect.
ObjectMemory compact.
ops := DBI.PostgreSQL.PGResultSet someInstance.
[ops isNil] whileFalse: [
[o := ops allOwners.
o isEmpty printNl. o size < 2] whileTrue: [
ops := ops nextInstance ].
[ o printNl. ] on: Error do: ['Already finalized?' printNl].
ops := ops nextInstance. ops isNil].
].
]
_______________________________________________
help-smalltalk mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-smalltalk