MCPcopy Create free account
hub / github.com/emscripten-core/emscripten / test_order2

Function test_order2

test/core/pthread/test_pthread_dlsym.c:34–51  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

32}
33
34static void test_order2() {
35 void* handle = open_lib();
36
37 func_t three = dlsym(handle, "three");
38 func_t two = dlsym(handle, "two");
39 func_t one = dlsym(handle, "one");
40
41 printf("one: %p -> %d\n", one, one());
42 printf("two: %p -> %d\n", two, two());
43 printf("three: %p -> %d\n", three, three());
44 assert(one() == 1);
45 assert(two() == 2);
46 assert(three() == 3);
47
48 assert(one == g_one);
49 assert(two == g_two);
50 assert(three == g_three);
51}
52
53static void* thread_main(void* arg) {
54 printf("in thread_main\n");

Callers 1

thread_mainFunction · 0.85

Calls 7

open_libFunction · 0.85
dlsymFunction · 0.85
printfFunction · 0.85
oneFunction · 0.70
twoFunction · 0.70
threeFunction · 0.70
assertFunction · 0.50

Tested by

no test coverage detected