Skip to content

Dynamic link and concurrent execution #10

Description

@the-felis-leo

In order to allow concurrent execution of a C program into a unique JVM,
Instead of using static fields and methods, use instance.

Said actual generated code look like :

class MyModule {
    public static void myMethod() {
        ExternModule.externMethod();
    }
}

Change it into:

class MyModule {
    ExternModule externModule;
    public MyModule(ProcessContext ctx) {
        externModule = ctx.get(ExternModule.class);
    }
    public void myMethod() {
        externModule.externMethod();
    }
}

With ProcessContext.get() which lazy instantiate module.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions