3 ms·
> For the C “FFI” he used standard dynamic linking, not dlopen(). This distinction is important, since it really makes a difference in the benchmark. There’s a
by eatonphil 4y ago
> For the C “FFI” he used standard dynamic linking, not dlopen(). This distinction is important, since it really makes a difference in the benchmark. There’s a potential argument about whether or not this is a fair comparison to an actual FFI, but, regardless, it’s still interesting to measure
- arinlen 4y ago> There’s a potential argument about whether or not this is a fair comparison to an actual FFI, but, regardless, it’s still interesting to measure (...) If there's interest in measuring dynamic linking then wouldn't there be an interest in measuring it on all languages that support dynamic linking?
- jcelerier 4y agoWith clang, just compiling with -fno-plt gives me: jit: 1.003483 ns/call plt: 1.254158 ns/call ind: 1.254616 ns/call GCC does not seem to support it though, even if it accepts the flag and gives me: jit: 1.003483 ns/call plt: 1.502089 ns/call ind: 1.254616 ns/call (tried everything I could think of that would have a chance to make the PLT disappear: cc -fno-plt -Bsymbolic -fno-semantic-interposition -flto -std=c99 -Wall -Wextra -O3 -g3 -Wl,-z,relro,-z,now -o benchmark benchmark.c ./empty.so -ldl without any change on GCC)