Projects tagged ‘continuations’


[15 total ]

900 Users
   

Apache Tomcat is the servlet container that is used in the official Reference Implementation for the Java Servlet and JavaServer Pages technologies.
Created over 3 years ago.

18 Users
 

Jifty is a way to build web applications.
Created over 3 years ago.

16 Users
   

PLT Scheme is an innovative programming language that builds on a rich academic and practical tradition. It is suitable for implementation tasks ranging from scripting to application development ... [More] , including GUIs, web services, etc. It includes the DrScheme programming environment, a virtual machine with a just-in-time compiler, tools for creating stand-alone executables, the PLT Scheme web server, extensive libraries, documentation for both beginners and experts, and more. It supports the creation of new programming languages through a rich, expressive syntax system. Example languages include Typed Scheme, ACL2, FrTime, Lazy Scheme, and ProfessorJ (which is a pedagogical dialect of Java). [Less]
Created about 1 year ago.

3 Users
 

Weblocks is an advanced web framework written in Common Lisp. It is designed to make Agile web application development as effective and simple as possible. This is not your ordinary ... [More] run-of-the-mill web framework in PHP, Python or Ruby. Weblocks uses powerful Lisp features like multiple dispatch, the metaobject protocol, lexical closures, keyword arguments, and macros to build abstractions that make web development easy, intuitive, and free of boilerplate. In addition, control flow is easily expressed using continuations. Things that are hard or mundane in other frameworks become easy and fun in Weblocks. [Less]
Created about 1 year ago.

2 Users
 

Nagare is an Open-Source Python framework dedicated to web applications development. Its set of advanced features as continuation, direct callbacks registration, programmatic HTML generation ... [More] , combined with its strong components model allow to quickly and easily build highly complex and reusable applications. [Less]
Created about 1 year ago.

2 Users
 

Sefirs provides a Java Thread-like class that executes over simulated time. Time units are user-definable, there is no time quanta, and neither changes to the VM nor pre-processing (like bytecode ... [More] re-writers) are required. Sefirs accomplishes this by providing a framework for native thread-based continuations in Java. [Less]
Created over 3 years ago.

2 Users
 

Higher-order functional programming for PHP 5. More power, less brain damage, and only half the suck.
Created over 2 years ago.

1 Users
 

Sometimes it is usefull if we can capture the state of the application, its stack of function calls, which includes local variables, the global variables and the program counter, and save them into an ... [More] object. If this object would give us the ability to restart the processing from the point stored in it. A continuation is exactly the type of object that we need. Think of a continuation as an object that, for a given point in your program, contains a snapshot of the stack trace, including all the local variables, and the program counter. You can not only store these things in the continuation object, but also restore the execution of the program from a continuation object. This means that the stack trace and the program counter of the running program become the ones stored in a continuation [Less]
Created over 2 years ago.

1 Users

Continuity uses a programming concept called continuations to make HTTP seem like a statefull protocol instead of stateless protocol. This technique is increasingly called creating a Continuation ... [More] Server. Continuity is a suite of Perl libraries (not a framework) for building a highly structured web-based interface for your application, without using ad-hoc state management. Continuity is Free Software, distributed under the same terms as Perl itself. [Less]
Created about 1 year ago.

0 Users

Concurrency in CA lightweight concurrency library for C, featuring symmetric coroutines as the main control flow abstraction. The library is similar to State Threads, but using coroutines instead of ... [More] green threads. This simplifies inter-procedural calls and largely eliminates the need for mutexes and semaphores for signaling. Eventually, coroutine calls will also be able to safely migrate between kernel threads, so the achievable scalability is consequently much higher than State Threads, which is purposely single-threaded. This library was inspired by Douglas W. Jones' "minimal user-level thread package". The pseudo-platform-neutral probing algorithm on the svn trunk is derived from his code. There is also a safer, more portable coroutine implementation based on stack copying, which was inspired by sigfpe's page on portable continuations in C. Copying is more portable and flexible than stack switching, and making copying competitive with switching is being researched. CoroutinesCoroutine calls consist of only one operation: coro_call. This operation suspends the currently executing coroutine, and resumes the target coroutine passing it a given value. Passing a value in the other direction is exactly the same. Coroutines which use only one operation like this are called symmetric coroutines. Asymmetric coroutines use two different operations, like call and yield, implying that one caller is subordinate to another. Lua supports asymmetric coroutines. In many ways, such coroutines closely resemble the Inter-Process Communication (IPC) facilities of microkernel operating systems like EROS, and they are also closely related to actors. Revisiting Coroutines is a detailed paper explaining the advantages of coroutines as a control flow abstraction. While the authors prefer asymmetric coroutines, and use a coroutine label to avoid capture problems, I think it's simpler to simply use the coroutine reference itself in place of a label. Comparison to Existing AlternativesFeatures libconcurrency provides that are not found in libcoro, libCoroutine, libpcl, coro: Cloning a coroutine: this enables a straightforward implementation of multishot continuations. Without the ability to clone, only one-shot continuations can be implemented in terms of coroutines. Note, cloning is not available on Windows since Windows uses the Fibers API. This was necessary to handle some unfortunate problems. The more portable stack copying implementation does support cloning. Portable Speed: libconcurrency is based on a portable technique that modifies jmp_buf and uses setjmp/longjmp to save and restore contexts. This is fast because setjmp/longjmp do not save and restore signals, whereas most other libraries are based on ucontext, which is very portable but inefficient, or assembler which is efficient but not portable. The library consists of entirely C99 compliant C and no exotic platform or OS features are used. Actual coroutine API: most of the listed libraries implement green threads, not coroutines. You'll note that no values are passed between coroutines in these libraries. Passing values between coroutines is one of the primary reasons why they are more general than threads. Simpler API: the API consists of only 6 orthogonal functions: coro_init, coro_call, coro_clone, coro_poll, coro_free. Works on Windows: libconcurrency is primarily developed on Windows, and uses Windows Fibers for coroutines. Resources are managed: the coro_poll function must be called periodically to ensure a coroutine has enough resources to continue executing. This function can shrink or grow the stack using a hysteresis algorithm inspired by the description of one-shot continuations in Representing Control in the Presence of One-Shot Continuations. ExampleHere's a basic reader/writer that simply echoes characters read to the screen: #include #include coro cr; coro cw; void reader(cvalue r) { while (1) { printf("> "); r.c = getchar(); if (r.c != '\n') { coro_call(cw, r); } } } void writer(cvalue w) { while(1) { printf(" echo: %c\n", w.c); w = coro_call(cr, cnone); } } int main(int argc, char **argv) { coro _main = coro_init(); printf("Simple reader/writer echo...\n"); cr = coro_new(reader); cw = coro_new(writer); coro_call(cw, cnone); return 0; } [Less]
Created about 1 year ago.