On Thu, Apr 28, 2011 at 5:12 PM, Wan Mohd Fairuz Wan Ismail <
[email protected]> wrote:

> Hi,
> I'm conducting some test today using Valgrind on Android (can be referred
> here https://bugs.kde.org/show_bug.cgi?id=266035#c28). The test program
> runs well alone but when tested on valgrind, it gave me this error.
>
>
> /data # valgrind ./hello-arm-bionic
> valgrind: mmap(0x0, 2952865436) failed in UME with error 22 (Invalid 
> argument).
>
>
Last time we saw this particular error message it was caused by doing
exec("/proc/self/exe"), which is currently not supported by valgrind. I also
think we had the same problem somewhere in Android.

--kcc


> valgrind: this can be caused by executables with very large text, data or bss
> segments.
>
>
>
> strace valgrind ./hello-arm-bionic gives me:
>
>
>
> /data # strace valgrind --tool=none ./hello-arm-bionic
> execve("/data/psi_omap_builds_users/x0152532/valgrind/bin/valgrind", 
> ["valgrind", "--tool=none", "./hello-arm-bionic"], [/* 13 vars */]) = 0
> uname({sys="Linux", node="localhost", ...}) = 0
> brk(0)                                  = 0x95000
> brk(0x95d00)                            = 0x95d00
> syscall_983045(0x954c0, 0x91b40, 0xffffffe0, 0x10, 0x932e8, 0x8, 0x10, 
> 0xf0005, 0x91bfc, 0x4, 0x28, 0x954c0, 0, 0xbe8d7a90, 0xc88c, 0xc89c, 
> 0x40000110, 0x954c0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0) = 0
> brk(0xb6d00)                            = 0xb6d00
> brk(0xb7000)                            = 0xb7000
> open("./hello-arm-bionic", O_RDONLY)    = 3
> read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\2\0(\0\1\0\0\0 \204\0\000"..., 4096) 
> = 4096
> close(3)                                = 0
> readlink("/proc/self/exe", 
> "/data/psi_omap_builds_users/x0152532/valgrind/bin/valgrind", 4096) = 58
> execve("/data/psi_omap_builds_users/x0152532/valgrind/lib/valgrind/none-arm-linux",
>  ["valgrind", "--tool=none", "./hello-arm-bionic"], [/* 14 vars */]) = 0
> open("/proc/self/maps", O_RDONLY)       = 3
> read(3, "38000000-38204000 r-xp 00008000 "..., 100000) = 359
> read(3, "", 99641)                      = 0
> close(3)                                = 0
> mmap2(0x61723000, 4194304, PROT_READ|PROT_WRITE|PROT_EXEC, 
> MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, 0, 0) = 0x61723000
> getrlimit(0x2, 0x38cb0d84, 0, 0, 0)     = 0
> setrlimit(RLIMIT_DATA, {rlim_cur=0, rlim_max=RLIM_INFINITY}) = 0
> getrlimit(0x3, 0x38cb0d8c, 0, 0, 0)     = 0
> rt_sigprocmask(SIG_UNBLOCK, [ILL FPE], [], 8) = 0
> rt_sigaction(SIGILL, NULL, {SIG_DFL}, 8) = 0
> rt_sigaction(SIGFPE, NULL, {SIG_DFL}, 8) = 0
> rt_sigaction(SIGILL, {0x38077cd0, [], SA_NOMASK}, NULL, 8) = 0
> rt_sigaction(SIGFPE, {0x38077cd0, [], SA_NOMASK}, NULL, 8) = 0
> rt_sigaction(SIGILL, {SIG_DFL}, NULL, 8) = 0
> rt_sigaction(SIGFPE, {SIG_DFL}, NULL, 8) = 0
> rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
> getcwd("/data", 4095)                   = 6
> open("./hello-arm-bionic", O_RDONLY)    = 3
> stat64("./hello-arm-bionic", {st_mode=S_IFREG|0777, st_size=6788, ...}) = 0
> geteuid32()                             = 0
> fstat64(3, {st_mode=S_IFREG|0777, st_size=6788, ...}) = 0
> lseek(3, 0, SEEK_SET)                   = 0
> read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\2\0(\0\1\0\0\0 \204\0\000"..., 4096) 
> = 4096
> lseek(3, 0, SEEK_SET)                   = 0
> read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\2\0(\0\1\0\0\0 \204\0\000"..., 52) = 
> 52
> lseek(3, 52, SEEK_SET)                  = 52
> read(3, "\1\0\0p�\4\0\0�\204\0\0�\204\0\0\10\0\0\0\10\0\0\0\4\0"..., 192) = 
> 192
> lseek(3, 244, SEEK_SET)                 = 244
> read(3, "/system/bin/linker\0", 19)     = 19
> open("/system/bin/linker", O_RDONLY)    = 4
> lseek(4, 0, SEEK_SET)                   = 0
> read(4, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\2\0(\0\1\0\0\0\0\20\0�"..., 52) = 52
> lseek(4, 52, SEEK_SET)                  = 52
> read(4, "\1\0\0\0�\0\0\0\0\0\0\0\0\0\0�\0\0\0\0\0\0\0\0\4\0\0\0"..., 160) = 
> 160
> mmap2(0x8000, 4096, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_FIXED, 3, 0) = 0x8000
> fstat64(3, {st_mode=S_IFREG|0777, st_size=6788, ...}) = 0
> readlink("/proc/self/fd/3", "/data/hello-arm-bionic", 4096) = 22
> mmap2(0x9000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED, 3, 0x1) = 
> 0x9000
> fstat64(3, {st_mode=S_IFREG|0777, st_size=6788, ...}) = 0
> readlink("/proc/self/fd/3", "/data/hello-arm-bionic", 4096) = 22
> write(2, "valgrind: mmap(0x0, 2952865436) "..., 80valgrind: mmap(0x0, 
> 2952865436) failed in UME with error 22 (Invalid argument).
> ) = 80
> write(2, "valgrind: this can be caused by "..., 88valgrind: this can be 
> caused by executables with very large text, data or bss segments.
> ) = 88
> SYS_248(0x1, 0, 0, 0, 0 <unfinished ... exit status 1>
>
>
>
> Any idea on this error? I appreciate any idea to debug this problem. Thanks.
>
>
>
> Regards,
>
>
> --
> Wan Mohd Fairuz WAN ISMAIL
>
> 15 Le Palais des Fleurs,
> 74 Boulevard Raymond Poincare,
> 06160 Juan les Pins, FRANCE.
> http://www.watt.com.my
> +6 017 2071591
>
>
>
> ------------------------------------------------------------------------------
> WhatsUp Gold - Download Free Network Management Software
> The most intuitive, comprehensive, and cost-effective network
> management toolset available today.  Delivers lowest initial
> acquisition cost and overall TCO of any competing solution.
> http://p.sf.net/sfu/whatsupgold-sd
> _______________________________________________
> Valgrind-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/valgrind-users
>
>
------------------------------------------------------------------------------
WhatsUp Gold - Download Free Network Management Software
The most intuitive, comprehensive, and cost-effective network 
management toolset available today.  Delivers lowest initial 
acquisition cost and overall TCO of any competing solution.
http://p.sf.net/sfu/whatsupgold-sd
_______________________________________________
Valgrind-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/valgrind-users

Reply via email to