[llvm-dev] LLVMSymbolizer: error reading file: No such file or directory

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[llvm-dev] LLVMSymbolizer: error reading file: No such file or directory

Sudhindra kulkarni via llvm-dev
Hi all,
I'm trying to use klee-uclibc and lli ( I want to use --force-interpreter ) together but I have a small problem. In the present case I'm trying to execute the following program:

#include<stdio.h>
#include<stdlib.h>

int main () {
   FILE *fp;
   char buffer[1];

   fp = fopen("/bin/ls", "rb");

   fread(buffer, 1, 1, fp);
   fclose(fp);

   printf("Read %d\n", buffer[0]);
  
   return(0);
}
I compile it using the following bash script:

#!/bin/bash

clang -emit-llvm -c fread.c
llvm-link fread.bc ../lib/fread.os ../lib/fread_unlocked.os ../lib/_stdio.os ../lib/errno.os -o fread-new.bc

Of course the os files were generated compiling klee-uclibc as described on their web page.

Unfrotunately the output is the following:

✗ lli --force-interpreter examples/fread-new.bc
Unknown constant pointer type!
UNREACHABLE executed at /home/alb/Desktop/code/llvm-6.0.1.src/lib/ExecutionEngine/ExecutionEngine.cpp:914!
LLVMSymbolizer: error reading file: No such file or directory
#0 0x0000000001765ee9 (lli+0x1765ee9)
#1 0x0000000001766099 (lli+0x1766099)
#2 0x0000000001764643 (lli+0x1764643)
#3 0x0000000001766424 (lli+0x1766424)
#4 0x00007f8c6200a890 __restore_rt (/lib/x86_64-linux-gnu/libpthread.so.0+0x12890)
#5 0x00007f8c60ac8e97 gsignal (/lib/x86_64-linux-gnu/libc.so.6+0x3ee97)
#6 0x00007f8c60aca801 abort (/lib/x86_64-linux-gnu/libc.so.6+0x40801)
#7 0x00000000016d7150 (lli+0x16d7150)
#8 0x0000000001138d14 (lli+0x1138d14)
#9 0x00000000011500b8 (lli+0x11500b8)
#10 0x000000000115f1ef (lli+0x115f1ef)
#11 0x0000000001161e28 (lli+0x1161e28)
#12 0x0000000001150087 (lli+0x1150087)
#13 0x000000000115c74b (lli+0x115c74b)
#14 0x000000000114e957 (lli+0x114e957)
#15 0x00000000011689f2 (lli+0x11689f2)
#16 0x000000000116827d (lli+0x116827d)
#17 0x0000000001164535 (lli+0x1164535)
#18 0x0000000001163580 (lli+0x1163580)
#19 0x000000000114e197 (lli+0x114e197)
#20 0x0000000001135ba0 (lli+0x1135ba0)
#21 0x00000000008c729d (lli+0x8c729d)
#22 0x00007f8c60aabb97 __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x21b97)
#23 0x00000000008c4f1a (lli+0x8c4f1a)
Stack dump:
0.    Program arguments: lli --force-interpreter examples/fread-new.bc
[1]    18381 abort (core dumped)  lli --force-interpreter examples/fread-new.bc

Any idea on how to fix it please?

Thanks

_______________________________________________
LLVM Developers mailing list
[hidden email]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev