John Darrington <[email protected]> writes: > I've noticed that it's very easy to cause PSPP to crash with > "memory exhausted" by trying to run a procedure such as MEANS > or EXAMINE with a categorical variable which contains many distinct > values. > > Clearly running such a procedure is stupid thing to do, and probably > means the user doesn't know what he's doing. However it could also > be an innocent mistake (like a wrong click in the gui). But whatever, > .. I think it's bad when a wrong input causes a crash.
Yes, I agree (of course). > I think it might improve matters if we made the function > settings_get_workspace_cases a little more intelligent. This function > returns a recommendation on how much memory a procedure can malloc. > At very least, it shouldn't recommend mallocing more memory than is > currently available in core. Maybe it should also be somewhat adaptive in > the sense that it doesn't return more than 50% of the available memory. The current default of 64 MB is fairly conservative for modern systems. I'd be happy to adjust that downward on (presumably older) systems that have little memory. Perhaps we could use the gnulib "physmem" module to find that out. But: Are you sure that the problem is that the default setting is too high? I would have guessed that the problem is actually one of two things: either the setting is being raised manually to a value that is too high for the system, or the categorical code does not honor the setting regardless of its value. (Without looking at code, I'd guess that the latter is the case.) -- Ben Pfaff http://benpfaff.org _______________________________________________ pspp-dev mailing list [email protected] https://lists.gnu.org/mailman/listinfo/pspp-dev
