> >I wouldn't worry about the memory so much because the process running 
> >the compiler is short-lived.
> 
> May be that's where my problem is. Often times I do not see memory to be
> short-lived, at least not in my windows task manager as I see page file
> usage history to go up and up (there are times when it come back
> though), ultimately exhausting the virtual memory. I made all the
> variables to be local as much as possible in order them to be garbage
> collected -- but it appears it does not do that always.

Do you see this extensive memory use in the ozc (compiler) process or in your 
own Oz program?
1.If it is in the ozc process:
Maybe it is possible to send the data in smaller chunks from the Java program? 
Then you could compile these smaller chunks on the Oz side and assemble them 
again afterwards. 

2. If it is in your own Oz program:
Some things to look out for:
- Streams with too large scope
- record arities are not garbage-collected by Mozart. So if you dynamically 
create lots of different record types (with different field names) this might 
be a problem
- the same for atoms: if you create a lot of different atoms dynamically, this 
might be a problem, too


> >Using an XML parser is only interesting if your data actually is XML, I
> 
> >think.
> 
> Yes, of course, I have to change my input data formatting to XML. That's
> why I want to know if the reward will be great before taking this big
> undertaking.

I don't have much experience with with XML parsing in Oz.
But XML is a lot easier to parse than most programing languages, so it should 
be faster.
Maybe you can create a large dummy XML document first and do some tests before 
you decide to go that way.


> >It looks like you want to share a large value between different Oz 
> > processes.
> >Did you try the "obvious" method:
> >- On the sender site:
> >    Ticket = {Connection.offer LargeValue}
> >    send Ticket through socket
> >- On the receiver site:
> >    receive Ticket from socket
> >    LargeValue = {Connection.take Ticket}
> 
> What do you mean by two different Oz process. I read the input data
> string from a socket, which is sent through by a Java process. I read
> that through Open.socket read(list: size: len:). Then I call method from
> another functor where this string data is compiled to Oz records and
> such. So I don't think I am sharing data between two Oz processes?

Sorry, I misunderstood. I thought the data was coming from another Oz program 
because of the format.

Cheers,
  Wolfgang

-- 
Neu: GMX FreeDSL Komplettanschluss mit DSL 6.000 Flatrate + Telefonanschluss 
für nur 17,95 Euro/mtl.!* 
http://dslspecial.gmx.de/freedsl-surfflat/?ac=OM.AD.PD003K11308T4569a
_________________________________________________________________________________
mozart-users mailing list                               
[email protected]
http://www.mozart-oz.org/mailman/listinfo/mozart-users

Reply via email to