Thread-Agile Dynamic Programming Language Execution Engine
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Dynamic programming language (DPL) programs typically execute on a single thread, leading to inefficient use of resources when idle or waiting, resulting in poor system performance, resource utilization, and event processing throughput.
Innovation Solution
Implementing thread-agile execution by using a host application to retrieve a stored state object and prepare a thread from a thread pool for DPL programs, allowing for efficient reuse of threads and improved resource management through an execution engine.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Device complexity
If DPL programs execute on a single thread, then thread management is simple, but resource utilization is poor and system performance is low
Solution Approach 1:
The patent implements dynamic thread management where the execution engine can allocate and deallocate threads based on runtime conditions. Threads are not statically bound to DPL programs but are dynamically assigned from a pool, allowing the system to adapt thread usage to actual workload demands, thereby improving resource utilization without requiring complex manual thread management.
Solution Approach 2:
The execution engine serves multiple functions: it manages the thread pool, allocates threads to DPL programs, executes the programs, and handles program lifecycle events. This multi-functional approach consolidates thread management responsibilities, improving system performance without proportionally increasing complexity.
2Stability of the object's composition
If DPL programs are thread-affinitized throughout lifetime, then execution context is stable, but resource utilization is inefficient during idle periods
Solution Approach 1:
The system pre-creates a pool of threads that are ready for execution but not currently assigned to any DPL program. When a DPL program needs to execute, it is quickly assigned an available thread from the pool. This preliminary preparation eliminates idle thread creation overhead while maintaining execution stability through consistent thread assignment during program lifetime.
Solution Approach 2:
When a DPL program completes execution or pauses, its associated thread is not discarded but recovered back to the thread pool for reuse. This allows the same physical thread to serve multiple DPL programs over time, improving resource utilization efficiency while maintaining execution context stability through proper state management.
3Reliability
If threads are allocated for each DPL program instance, then execution is reliable, but resource utilization is poor when programs are waiting or idle
Solution Approach 1:
The execution engine implements self-service thread management by automatically allocating threads from the pool when DPL programs need to execute and recovering threads when programs complete or pause. This automated management ensures execution reliability through consistent thread assignment while improving productivity by preventing idle thread wastage and enabling faster event processing through efficient thread reuse.
Data Source
AI summary
Methods, systems, and products are provided for thread-agile dynamic programming language (‘DPL’) program execution. Thread-agile DPL program execution may be carried out by receiving, in a message queue, a message for an instance of a DPL program and determining whether the host application has a stored state object for the instance of the DPL program identified by the message. If the host application has a stored state object for the DPL program, thread-agile DPL program execution may also carried out by retrieving the state object; preparing a thread available from a thread pool for execution of the instance of the DPL program in dependence upon the state object and an execution context for the instance of the DPL program; providing, to an execution engine for executing the DPL program, the state object and the prepared thread; and passing the message to the execution engine.


