Skip to content

What would I measure, Prolog with or without garbage collection? #331

Description

@Jean-Luc-Picard-2021

Lets say this feature request would be realized:

feature request time/1 and/or statistics/2 predicate
#327

What would I measure a Prolog system with or without
garbage collection? Is this documented somewhere?

For example Scryer Prolog has no garbage collection,
and it still fails with this test case:

$ ulimit -m 2000000
$ ulimit -v 2000000
$ target/release/scryer-prolog -v
v0.9.4-135-g7cfe8ee5

$ target/release/scryer-prolog
?- [user].
app([], X, X).
app([X|Y], Z, [X|T]) :- app(Y, Z, T).
garbage(0, [0]) :- !.
garbage(N, L) :- M is N-1, garbage(M, R), app(R, R, L).
foo :- garbage(12,_), foo.

?- foo.
memory allocation of 2147483648 bytes failed
Aborted

The above preferably runs indefinitely. For
example SWI-Prolog can run it indefinitely.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions