Stack size

FlexibleLearning admin at FlexibleLearning.com
Wed Nov 24 03:27:54 EST 2010


FlexibleLearning wrote:

> Thank you Jacque... Forgot about that one. Had half-remembered it as a
> compatibility-only function, but we'll give it a try. We were getting a
> 'cannot find stack' error which actually meant 'cannot fully load this
> stack', as well as no graceful result that memory is running low; just a
> suddenly non-responsive stack. I think a bit of work is needed at the
upper
> end of memory limits.

Richard Gaskin wrote:
> True, but it's not trivial.  IFAIK OS X provides no API for an app to
> know the amount of available memory; instead it's recommended that an
> app keep track of its allocations, which isn't possible in a tool like
> Rev since externals can come into play.
>
> Personally, as much as I love storing data in stack files, with nearly a
> GB of data I'd look into another storage format.
>
> Even just a plain text file can be traversed with reasonable efficiency
> if you can afford the up-front cost of indexing it, which allows you to
> use seek to read only what you need.
>
> But SQLite may be an even better option, certainly less work than
> writing your own indexing scheme.

Agreed, Richard. However, the multi-tier data for this puppy is not entirely
straightforward and we opted for native LC-data storage for simplicity and
sanity. Most users will never get to a point where it becomes an issue, but
if they do I think the app should include a graceful way of handling it...
hence the query and the trials of hasMemory() today.

Hugh Senior
FLCo





More information about the use-livecode mailing list