Foreign Function Interface for Managed Runtime Systems with Lightweight Threading

An essential class of computer software, such as network servers, achieves concurrency through multiple loosely coupled and possibly long-lasting sessions. In recent years, some programming languages have introduced support for lightweight threading in such applications as an alternative to event-driven frameworks. The lightweight threading model provides an M:n mapping from lightweight to system threads, which provides an ability to write sequential code similar to system threads, but with a much less memory footprint. This model achieves its performance by allowing full control over the scheduling policy in user space without kernel intervention. The problem is that user-space implementations lose the ability to implicitly preempt such threads, which can lead to thread starvation. While the issue with preemption could be addressed in code managed by the runtime, foreign code should be handled differently. This paper examines the aspect of support of the foreign function interface for managed runtime systems that implement lightweight threading. We explore ways to address issues with foreign functions while avoiding performance overhead for foreign function invocations.

Institutions

Publication Details

Published
2025-06-27
DOI
https://doi.org/10.1109/edm65517.2025.11096859
Primary Topic
Geochemistry and Geologic Mapping
Type
article
Field-Weighted Citation Impact
0.00
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

Foreign Function Interface for Managed Runtime Systems with Lightweight Threading

Geochemistry and Geologic Mapping
article

Foreign Function Interface for Managed Runtime Systems with Lightweight Threading

article en

Abstract

An essential class of computer software, such as network servers, achieves concurrency through multiple loosely coupled and possibly long-lasting sessions. In recent years, some programming languages have introduced support for lightweight threading in such applications as an alternative to event-driven frameworks. The lightweight threading model provides an M:n mapping from lightweight to system threads, which provides an ability to write sequential code similar to system threads, but with a much less memory footprint. This model achieves its performance by allowing full control over the scheduling policy in user space without kernel intervention. The problem is that user-space implementations lose the ability to implicitly preempt such threads, which can lead to thread starvation. While the issue with preemption could be addressed in code managed by the runtime, foreign code should be handled differently. This paper examines the aspect of support of the foreign function interface for managed runtime systems that implement lightweight threading. We explore ways to address issues with foreign functions while avoiding performance overhead for foreign function invocations.

Institute of Economics and Industrial Engineering (RU)
Openalex Percentile: Top 25%
Geochemistry and Geologic Mapping
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

Foreign Function Interface for Managed Runtime Systems with Lightweight Threading · (2025) | TGRS Research Map | TGRS