Commit f004e6fc authored by Lukáš Marek's avatar Lukáš Marek

Fixed bad java buffering worker thread exit cond.

parent ddac3ef8
......@@ -27,7 +27,7 @@ LINK_SHARED=$(LINK.c) -shared -o $@
# GNU Compiler options needed to build it
COMMON_FLAGS=-fPIC
# Options that help find errors
COMMON_FLAGS+= -W -Wall -Wextra -O3 -Wno-unused-parameter -lpthread
COMMON_FLAGS+= -W -Wall -Wextra -O3 -Wno-unused-parameter -lpthread -lrt
CFLAGS += $(COMMON_FLAGS)
......
......@@ -1676,7 +1676,7 @@ static void * jb_worker_loop(void * obj) {
(*java_vm)->AttachCurrentThreadAsDaemon(java_vm, (void **)&jni_env, NULL);
// exit when requested
while(no_jb_work) {
while(! no_jb_work) {
// ** buff acquire **
......
package ch.usi.dag.disl.test.dispatch2;
import ch.usi.dag.dislre.REDispatch;
import ch.usi.dag.dislre.jb.REDispatchJ;
// Optimally, this class is automatically created on analysis machine
// and redefines during loading the CodeExecuted class on the client vm
......@@ -9,27 +9,27 @@ import ch.usi.dag.dislre.REDispatch;
// functionality
public class CodeExecutedRE {
private static short ieId = REDispatch.registerMethod(
private static short ieId = REDispatchJ.registerMethod(
"ch.usi.dag.disl.test.dispatch2.CodeExecuted.intEvent");
private static short oeId = REDispatch.registerMethod(
private static short oeId = REDispatchJ.registerMethod(
"ch.usi.dag.disl.test.dispatch2.CodeExecuted.objectEvent");
public static void intEvent(int num) {
REDispatch.analysisStart(ieId);
REDispatchJ.analysisStart(ieId);
REDispatch.sendInt(num);
REDispatchJ.sendInt(num);
REDispatch.analysisEnd();
REDispatchJ.analysisEnd();
}
public static void objectEvent(Object o) {
REDispatch.analysisStart(oeId);
REDispatchJ.analysisStart(oeId);
REDispatch.sendObject(o);
REDispatchJ.sendObject(o);
REDispatch.analysisEnd();
REDispatchJ.analysisEnd();
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment