Skip to content

Commit

Permalink
Document VM.request-garbage-collection
Browse files Browse the repository at this point in the history
  • Loading branch information
lizmat committed Mar 10, 2023
1 parent 23dca28 commit 4143d9f
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions doc/Type/VM.rakudoc
Expand Up @@ -36,4 +36,18 @@ that should be used when precompiling source-files with the VM object.
Instance method returning a string of the path in which the virtual machine
of the VM object is installed.

=head2 method request-garbage-collection

Available as of the 2020.05 release of the Rakudo compiler.

Class method that tells the virtual machine on which Raku is running, to
perform a garbage collect run when possible. Issues a warning if such a
request is not supported by the virtual machine.

Provides no guarantee that the process will actually use less memory after
a garbage collect. In fact, calling this method repeatedly, may actually
cause more memory to be used due to memory fragmentation.

Mainly intended as a debugging aid for module / core developers.

=end pod

0 comments on commit 4143d9f

Please sign in to comment.