{"id":20315242,"url":"https://github.com/sysread/ipc-pleather","last_synced_at":"2026-04-22T03:31:29.536Z","repository":{"id":56831236,"uuid":"110384595","full_name":"sysread/IPC-Pleather","owner":"sysread","description":"Easy to use concurrency primitives for Perl, inspired by Cilk","archived":false,"fork":false,"pushed_at":"2017-11-14T12:32:16.000Z","size":10,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-24T05:58:44.860Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Perl","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sysread.png","metadata":{"files":{"readme":"README.pod","changelog":"Changes","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-11-11T22:13:51.000Z","updated_at":"2018-10-29T20:20:01.000Z","dependencies_parsed_at":"2022-09-09T16:24:04.329Z","dependency_job_id":null,"html_url":"https://github.com/sysread/IPC-Pleather","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sysread%2FIPC-Pleather","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sysread%2FIPC-Pleather/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sysread%2FIPC-Pleather/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sysread%2FIPC-Pleather/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sysread","download_url":"https://codeload.github.com/sysread/IPC-Pleather/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241818872,"owners_count":20025210,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-14T18:18:28.600Z","updated_at":"2025-12-04T09:03:11.196Z","avatar_url":"https://github.com/sysread.png","language":"Perl","funding_links":[],"categories":[],"sub_categories":[],"readme":"=pod\n\n=encoding UTF-8\n\n=head1 NAME\n\nIPC::Pleather - Easy to use concurrency primitives inspired by Cilk\n\n=head1 VERSION\n\nversion 0.02\n\n=head1 SYNOPSIS\n\n  use IPC::Pleather;\n\n  sub fib {\n    my $n = shift;\n    return $n if $n \u003c 2;\n\n    spawn my $x = fib($n - 1);\n    spawn my $y = fib($n - 2);\n\n    sync $x;\n    sync $y;\n\n    return $x + $y;\n  }\n\n=head1 DESCRIPTION\n\nC has L\u003cCilk|http://supertech.csail.mit.edu/cilk/\u003e, Perl has Pleather.\n\nIPC::Pleather adopts two keywords from Cilk, C\u003cspawn\u003e and C\u003csync\u003e. C\u003cspawn\u003e\nsignals that the block or expression I\u003cmay\u003e be executed concurrently. C\u003csync\u003e\ndenotes a merge point, waiting until the spawned expression is completely\nresolved.\n\n=head1 KEYWORDS\n\n=head2 spawn\n\nDeclares a variable whose value may or may not be executed in a forked process.\nSome care is taken to guarantee a fixed cap on the total number of forks.\nRecursive calls to spawn via the spawned expression (as in the Fibonacci\nexample in the L\u003c/SYNOPSIS\u003e) are bound by the same maximum.\n\nThe forking mechanism is implemented using L\u003cAnyEvent::Util/fork_call\u003e,\nallowing the maximum number of processes to be controlled either by setting\nC\u003c$AnyEvent::Util::MAX_FORKS\u003e or with the C\u003cPERL_ANYEVENT_MAX_FORKS\u003e\nenvironmental variable.\n\nC\u003cspawn\u003e accepts several different expression syntaxes.\n\n  # Block with optional arguments\n  spawn my $var = {...} $arg1, $arg2, $arg3;\n\n  # Subroutine call\n  spawn my $var = do_stuff($arg1, $arg1 + $arg2, ...);\n\nThe latter syntax expands to the former, and all expressions in the argument\nlist are evaluated in the subprocess (or not, as the case may be), rather than\nin the process from which they were spawned.\n\n=head2 sync\n\nCauses the process to block until the specified variable is fully resolved.\nFor spawned variables which executed in a forked process, a L\u003ccondition\nvariable|AnyEvent/CONDITION VARIABLES\u003e is used to synchronize the result. When\nexecuted locally, the result is immediately assigned to the variable and the\ncall to C\u003csync\u003e is essentially a no-op.\n\n=head1 SEE ALSO\n\n=over\n\n=item L\u003cThe Cilk Project|http://supertech.csail.mit.edu/cilk/\u003e\n\n=back\n\n=head1 AUTHOR\n\nJeff Ober \u003csysread@fastmail.fm\u003e\n\n=head1 COPYRIGHT AND LICENSE\n\nThis software is copyright (c) 2017 by Jeff Ober.\n\nThis is free software; you can redistribute it and/or modify it under\nthe same terms as the Perl 5 programming language system itself.\n\n=cut\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsysread%2Fipc-pleather","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsysread%2Fipc-pleather","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsysread%2Fipc-pleather/lists"}