Dynamorio failing with dmesg error "vsyscall read attempt denied"

59 views
Skip to first unread message

Jay Shah

unread,
Aug 1, 2022, 4:45:19 PM8/1/22
to DynamoRIO Users
Hello:

I am trying to compile and run dynamorio drcachesim on x86 linux. I was able to succesfully compile it and when I test try the command below - it looks like it goes through but when I read the dmesg buffer - this is what is printed out:

root@iclgpa:/home/lab/jashah/dynamorio/build# dmesg
root@iclgpa:/home/lab/jashah/dynamorio/build# bin64/drrun echo "hello world"
hello world
root@iclgpa:/home/lab/jashah/dynamorio/build# dmesg
[1734480.827598] echo[510897] vsyscall read attempt denied -- look up the vsyscall kernel parameter if you need a workaround ip:7fa19a3e1dc3 cs:33 sp:7ffd776fb948 ax:ffffffffff600000 si:ffffffffff600000 di:7ffd776fb970
root@iclgpa:/home/lab/jashah/dynamorio/build#

Has anyone seen this error before and does anyone know how to fix this?

Thaks,
Jay

Derek Bruening

unread,
Aug 1, 2022, 7:42:39 PM8/1/22
to Jay Shah, DynamoRIO Users
I believe that is just a warning and nothing actually failed: I assume the exit code is 0 and everything worked just fine.  Xref https://github.com/DynamoRIO/dynamorio/issues/5570#issuecomment-1190699147.  If you'd like to help eliminate the attempt to read vsyscall as a cleanup that would be great: maybe start by filing an issue and then submit a pull request.

--
You received this message because you are subscribed to the Google Groups "DynamoRIO Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dynamorio-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/dynamorio-users/1cb59215-761c-4ae0-b753-d797c626822dn%40googlegroups.com.

Jay Shah

unread,
Aug 2, 2022, 1:40:34 PM8/2/22
to Derek Bruening, DynamoRIO Users
Hi Derek:

I'm not very sure why it doesn't seem to work because I have another ARM system and the build works just fine on there.

This is from my ARM system output:
$ bin64/drrun -t drcachesim -- ls
api      cmake             CMakeDoxygenDefaults.cmake  configure_defines.h  core                     decode_gen.h        drcpusim.drrun64  ext      libutil   opcode_api.h
bin64    CMakeCache.txt    CMakeFiles                  configure.h          CPackConfig.cmake        drcachesim.drrun64  encode_gen.h      include  logs      opcode_names.h
clients  CMakeDoxyfile.in  cmake_install.cmake         configure_temp.h     CPackSourceConfig.cmake  drcov.drrun64       event_strings.h   lib64    Makefile  tools
---- <application exited with code 0> ----
Cache simulation results:
Core #0 (1 thread(s))
  L1I stats:
    Hits:                          528,602
    Misses:                          1,788
    Invalidations:                       0
    Miss rate:                        0.34%
  L1D stats:
    Hits:                          157,389
    Misses:                          4,123
    Invalidations:                       0
    Prefetch hits:                     981
    Prefetch misses:                 3,425
    Miss rate:                        2.55%
Core #1 (0 thread(s))
Core #2 (0 thread(s))
Core #3 (0 thread(s))
LL stats:
    Hits:                            1,887
    Misses:                          4,024
    Invalidations:                       0
    Prefetch hits:                   1,174
    Prefetch misses:                 2,251
    Local miss rate:                 68.08%
    Child hits:                    686,972
    Total miss rate:                  0.58%

But when I run the same command on my x86 system, my executable just hangs.

I tried running drrun.debug and this is the error I get:
$ bin64/drrun.debug -t drcachesim -- ls
-bash: bin64/drrun.debug: cannot execute binary file: Exec format error

Do you know what this error is? I tried searching for what the error may be but nothing helpful seems to come up.

Both the version of dynamorio were installed by following instructions on the page here: https://dynamorio.org/page_building.html

Any help would be really appreciated. :)

Thanks,
Jay

Derek Bruening

unread,
Aug 3, 2022, 11:39:33 PM8/3/22
to Jay Shah, DynamoRIO Users
Does plain drrun without any tool work?
Do other tools than online drcachesim work?
Online drcachesim makes a pipe and waits on it and errors in the pipe can cause hangs: is it waiting on a stale pipe?
Running or attaching in the debugger to see where it is would generally be the first step to diagnose a hang.
 
I tried running drrun.debug and this is the error I get:
$ bin64/drrun.debug -t drcachesim -- ls
-bash: bin64/drrun.debug: cannot execute binary file: Exec format error

A .debug file is not for execution: it contains debug info.  As the documentation https://dynamorio.org/page_debugging.html says pass "-debug" to drrun to use the debug build.
 
Reply all
Reply to author
Forward
0 new messages