百科.dev
全部条目在线工具AI 编程趋势榜开源项目技术资讯提交条目
登录
< 返回工具列表
L

libcircle

> 编程语言
开源

一个 API,用于在集群上提供高效的分布式队列。目前,Libcircle 正在生产环境中用于快速遍历文件树并对其执行操作。

100 stars0 点赞0 次浏览
访问官网GitHub

工具介绍

一个 API,用于在集群上提供高效的分布式队列。目前,Libcircle 正在生产环境中用于快速遍历文件树并对其执行操作。

libcircle

libcircle is an API for distributing embarrassingly parallel workloads using self-stabilization. Details on the algorithms used may be found at .

Dependencies

  • MPI
  • e.g., Open MPI

Compile and install

The current build status is:

bash
./configure
make all check
sudo make install

To enable output from libcircle (including fatal errors), run configure with "--enable-loglevel=number" where "number" is one of the following options:

  • "1" fatal errors only.
  • "2" errors and lower log levels.
  • "3" warnings and lower log levels.
  • "4" info messages on internal operations and lower log levels.
  • "5" fine grained debug messages and lower log levels.

RPM Build and Install

To build an RPM, use the following instructions:

  1. rpmbuild -ta libcircle-.tar.gz
  2. rpm --install

Developer API Information

The basic program flow when using libcircle is the following:

  1. Define callbacks which enqueue or dequeue strings from the queue.
  2. Execute the program.
…

Options

The following bit flags can be OR'ed together and passed as the third parameter to CIRCLE_init or at anytime through CIRCLE_set_options before calling CIRCLE_begin:

  • CIRCLE_SPLIT_RANDOM - randomly divide items among processes requesting work
  • CIRCLE_SPLIT_EQUAL - equally divide items among processes requesting work
  • CIRCLE_CREATE_GLOBAL - invoke create callback on all processes, instead of just the rank 0 process
  • CIRCLE_TERM_TREE - use tree-based termination detection, instead of ring-based token passing

Reductions

When enabled, libcircle periodically executes a global, user-defined reduction operation based on a time specified by the user. A final reduction executes after the work loop terminates. To use the optional reduction:

  1. Define and register three callback functions with libcircle:
  • CIRCLE_cb_reduce_init - This function is called once on each process for each reduction invocation to capture the initial contribution from that process to the reduction.
  • CIRCLE_cb_reduce_op - This function is called each time libcircle needs to combine two reduction values. It defines the reduction operation.
  • CIRCLE_cb_reduce_fini - This function is called once on the root process to output the final reduction result.
  1. Update the value of reduction variable(s) within the CIRCLE_cb_process callback as work items are dequeued and processed by libcircle.
  2. Specify the time period between consecutive reductions with a call to CIRCLE_set_reduce_period to enable them.

The example below shows how to use reductions to periodically print the number of items processed. Each process counts the number of items it has processed locally. The reducton computes the global sum across processes, and it prints the global sum along with the average rate.

…

Issues· 0 开放

查看全部 Issues在 GitHub 打开

暂无开放 Issues,或尚未同步最近议题。

> 标签

C

暂无评论,来聊聊你的看法吧

> 工具信息

发布日期2026年8月1日
最后更新2026年9月18日
分类编程语言
定价开源

> 相关工具

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言