[Bug 1826811] Re: Valgrind unhandled instruction 0xD5380000 on Aarch64

Eric Desrochers eric.desrochers at canonical.com
Wed Dec 11 19:59:01 UTC 2019


[Pre-SRU testing]

** With valgrind 3.13.0-2ubuntu2.1 **

# lsb_release -cs
bionic

# lscpu 
Architecture:        aarch64
Byte Order:          Little Endian

# valgrind ./hello
=7287== Memcheck, a memory error detector
==7287== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al.
==7287== Using Valgrind-3.13.0 and LibVEX; rerun with -h for copyright info
==7287== Command: ./hello
==7287== 
ARM64 front end: branch_etc
disInstr(arm64): unhandled instruction 0xD5380000
disInstr(arm64): 1101'0101 0011'1000 0000'0000 0000'0000
==7287== valgrind: Unrecognised instruction at address 0x4014c90.
==7287==    at 0x4014C90: init_cpu_features (cpu-features.c:72)
==7287==    by 0x4014C90: dl_platform_init (dl-machine.h:208)
==7287==    by 0x4014C90: _dl_sysdep_start (dl-sysdep.c:231)
==7287==    by 0x40018C3: _dl_start_final (rtld.c:414)
==7287==    by 0x4001B47: _dl_start (rtld.c:523)
==7287==    by 0x40011C7: ??? (in /lib/aarch64-linux-gnu/ld-2.27.so)
==7287== Your program just tried to execute an instruction that Valgrind
==7287== did not recognise.  There are two possible reasons for this.
==7287== 1. Your program has a bug and erroneously jumped to a non-code
==7287==    location.  If you are running Memcheck and you just saw a
==7287==    warning about a bad jump, it's probably your program's fault.
==7287== 2. The instruction is legitimate but Valgrind doesn't handle it,
==7287==    i.e. it's Valgrind's fault.  If you think this is the case or
==7287==    you are not sure, please let us know and we'll try to fix it.
==7287== Either way, Valgrind will now raise a SIGILL signal which will
==7287== probably kill your program.
==7287== 
==7287== Process terminating with default action of signal 4 (SIGILL)
==7287==  Illegal opcode at address 0x4014C90
==7287==    at 0x4014C90: init_cpu_features (cpu-features.c:72)
==7287==    by 0x4014C90: dl_platform_init (dl-machine.h:208)
==7287==    by 0x4014C90: _dl_sysdep_start (dl-sysdep.c:231)
==7287==    by 0x40018C3: _dl_start_final (rtld.c:414)
==7287==    by 0x4001B47: _dl_start (rtld.c:523)
==7287==    by 0x40011C7: ??? (in /lib/aarch64-linux-gnu/ld-2.27.so)
==7287== 
==7287== HEAP SUMMARY:
==7287==     in use at exit: 0 bytes in 0 blocks
==7287==   total heap usage: 0 allocs, 0 frees, 0 bytes allocated
==7287== 
==7287== All heap blocks were freed -- no leaks are possible
==7287== 
==7287== For counts of detected and suppressed errors, rerun with: -v
==7287== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)
==> Illegal instruction (core dumped)


** With valgrind 3.13.0-2ubuntu2.1 + commit fbbb696 on top of it ** [0]

# lsb_release -cs
bionic

# lscpu 
Architecture:        aarch64
Byte Order:          Little Endian

# valgrind ./hello
==8918== Memcheck, a memory error detector
==8918== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al.
==8918== Using Valgrind-3.13.0 and LibVEX; rerun with -h for copyright info
==8918== Command: ./hello
==8918== 
Hello World!
==8918== 
==8918== HEAP SUMMARY:
==8918==     in use at exit: 0 bytes in 0 blocks
==8918==   total heap usage: 1 allocs, 1 frees, 1,024 bytes allocated
==8918== 
==8918== All heap blocks were freed -- no leaks are possible
==8918== 
==8918== For counts of detected and suppressed errors, rerun with: -v
==8918== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)


[0] Test package:
sudo add-apt-repository ppa:slashd/lp1826811
sudo apt-get update


** Changed in: valgrind (Ubuntu Bionic)
       Status: Confirmed => In Progress

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to valgrind in Ubuntu.
https://bugs.launchpad.net/bugs/1826811

Title:
  Valgrind unhandled instruction 0xD5380000 on Aarch64

Status in valgrind package in Ubuntu:
  Fix Released
Status in valgrind source package in Bionic:
  In Progress
Status in valgrind package in Fedora:
  Fix Released

Bug description:
  I'm performing Valgrind testing on an ElPotato running Ubuntu Bionic
  Aarch64 image. My program is dying like in
  https://bugs.kde.org/show_bug.cgi?id=381556 :

  
  ```
  $ valgrind --track-origins=yes --suppressions=cryptopp.supp ./cryptest.exe v
  ==12969== Memcheck, a memory error detector
  ==12969== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al.
  ==12969== Using Valgrind-3.13.0 and LibVEX; rerun with -h for copyright info
  ==12969== Command: ./cryptest.exe v
  ==12969==
  ARM64 front end: branch_etc
  disInstr(arm64): unhandled instruction 0xD5380000
  disInstr(arm64): 1101'0101 0011'1000 0000'0000 0000'0000
  ==12969== valgrind: Unrecognised instruction at address 0x4014c90.
  ==12969==    at 0x4014C90: init_cpu_features (cpu-features.c:72)
  ==12969==    by 0x4014C90: dl_platform_init (dl-machine.h:208)
  ==12969==    by 0x4014C90: _dl_sysdep_start (dl-sysdep.c:231)
  ==12969==    by 0x40018C3: _dl_start_final (rtld.c:414)
  ==12969==    by 0x4001B47: _dl_start (rtld.c:523)
  ==12969==    by 0x40011C7: ??? (in /lib/aarch64-linux-gnu/ld-2.27.so)
  ...
  ```

  Here's a similar Red Hat issue report:
  https://bugzilla.redhat.com/show_bug.cgi?id=1467952 .

  Please pickup the patch in the 381556 bug report.

  -----

  $ lsb_release -rd
  Description:    Ubuntu 18.04.2 LTS
  Release:        18.04

  $ apt-cache policy valgrind
  valgrind:
    Installed: 1:3.13.0-2ubuntu2.1
    Candidate: 1:3.13.0-2ubuntu2.1
    Version table:
   *** 1:3.13.0-2ubuntu2.1 500
          500 http://ports.ubuntu.com bionic-updates/main arm64 Packages
          100 /var/lib/dpkg/status
       1:3.13.0-2ubuntu2 500
          500 http://ports.ubuntu.com bionic/main arm64 Packages

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/valgrind/+bug/1826811/+subscriptions



More information about the foundations-bugs mailing list