What can I provide any other information?
$ make check
...(The other VALGRIND tests succeeded so far)...
VALGRIND=1 valgrind -q --error-exitcode=7 --track-origins=yes --leak-check=full --show-reachable=yes --errors-for-leak-kinds=all connectd/test/run-initiator-success > /dev/null
==27974== Source and destination overlap in memcpy(0xbda56664, 0xbda56664, 84)
==27974== at 0x4844ECC: memcpy (vg_replace_strmem.c:1023)
==27974== by 0x1410E5: secp256k1_ge_neg (in /home/satoshi/lightning/connectd/test/run-initiator-success)
==27974==
Makefile:586: recipe for target 'unittest/connectd/test/run-initiator-success' failed
make: *** [unittest/connectd/test/run-initiator-success] Error 7
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 18.04.5 LTS
Release: 18.04
Codename: bionic
$ uname -a
Linux odroid 4.14.111-158 #1 SMP PREEMPT Tue Apr 16 12:26:31 -03 2019 armv7l armv7l armv7l GNU/Linux
$ cat /proc/cpuinfo
processor : 0
model name : ARMv7 Processor rev 3 (v7l)
BogoMIPS : 90.00
Features : half thumb fastmult vfp edsp neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae
CPU implementer : 0x41
CPU architecture: 7
CPU variant : 0x0
CPU part : 0xc07
CPU revision : 3
processor : 1
model name : ARMv7 Processor rev 3 (v7l)
BogoMIPS : 90.00
Features : half thumb fastmult vfp edsp neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae
CPU implementer : 0x41
CPU architecture: 7
CPU variant : 0x0
CPU part : 0xc07
CPU revision : 3
processor : 2
model name : ARMv7 Processor rev 3 (v7l)
BogoMIPS : 90.00
Features : half thumb fastmult vfp edsp neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae
CPU implementer : 0x41
CPU architecture: 7
CPU variant : 0x0
CPU part : 0xc07
CPU revision : 3
processor : 3
model name : ARMv7 Processor rev 3 (v7l)
BogoMIPS : 90.00
Features : half thumb fastmult vfp edsp neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae
CPU implementer : 0x41
CPU architecture: 7
CPU variant : 0x0
CPU part : 0xc07
CPU revision : 3
processor : 4
model name : ARMv7 Processor rev 3 (v7l)
BogoMIPS : 120.00
Features : half thumb fastmult vfp edsp neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae
CPU implementer : 0x41
CPU architecture: 7
CPU variant : 0x2
CPU part : 0xc0f
CPU revision : 3
processor : 5
model name : ARMv7 Processor rev 3 (v7l)
BogoMIPS : 120.00
Features : half thumb fastmult vfp edsp neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae
CPU implementer : 0x41
CPU architecture: 7
CPU variant : 0x2
CPU part : 0xc0f
CPU revision : 3
processor : 6
model name : ARMv7 Processor rev 3 (v7l)
BogoMIPS : 120.00
Features : half thumb fastmult vfp edsp neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae
CPU implementer : 0x41
CPU architecture: 7
CPU variant : 0x2
CPU part : 0xc0f
CPU revision : 3
processor : 7
model name : ARMv7 Processor rev 3 (v7l)
BogoMIPS : 120.00
Features : half thumb fastmult vfp edsp neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae
CPU implementer : 0x41
CPU architecture: 7
CPU variant : 0x2
CPU part : 0xc0f
CPU revision : 3
Hardware : ODROID-XU4
Revision : 0100
Serial : 0000000000000000
$
getinfo output{
"id": "036c518bbbf7afd2dd00ec145b501b782f1ec4112928e650db78319c52ee05b7fb",
"alias": "ChirimenJako",
"color": "00fed9",
"num_peers": 1,
"num_pending_channels": 0,
"num_active_channels": 1,
"num_inactive_channels": 0,
"address": [],
"binding": [
{
"type": "ipv4",
"address": "0.0.0.0",
"port": 9735
}
],
"version": "v0.9.2rc1-6-gcd7d5cd",
"blockheight": 651263,
"network": "bitcoin",
"msatoshi_fees_collected": 4001,
"fees_collected_msat": "4001msat",
"lightning-dir": "/home/bitcoin/.lightning/bitcoin",
"warning_bitcoind_sync": "Bitcoind is not up-to-date with network."
}
Trying to reproduce now on my arm box.
Reproduced very easily (./configure; make; make check) also on Ubuntu 20.04 ARMv7 on current master (i.e. v0.9.2rc2, ce0888d7d6756d8ccb862e43d918fa3128e4f0dc)
VALGRIND=1 valgrind -q --error-exitcode=7 --track-origins=yes --leak-check=full --show-reachable=yes --errors-for-leak-kinds=all connectd/test/run-initiator-success > /dev/null
==14367== Source and destination overlap in memcpy(0xbdc4289c, 0xbdc4289c, 84)
==14367== at 0x48464BC: memcpy (vg_replace_strmem.c:1036)
==14367== by 0x141839: secp256k1_ge_neg (in /root/src/lightning/connectd/test/run-initiator-success)
==14367==
make: *** [Makefile:586: unittest/connectd/test/run-initiator-success] Error 7
Thank you @Chirimen-Jako for reporting this!
Ha, this can actually be safely ignored, though I'm not sure whether gcc is allowed to take this liberty.
Tested on arm64 and the error is not reproducible there. This is some info:
$ cat /etc/os-release
PRETTY_NAME="Debian GNU/Linux bullseye/sid"
NAME="Debian GNU/Linux"
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"
$ uname -rms
Linux 5.4.0-qcomlt-arm64 aarch64
$ gcc --version
gcc (Debian 10.2.0-16) 10.2.0
Copyright (C) 2020 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
$ valgrind --version
valgrind-3.16.1
$ cat /proc/cpuinfo
processor : 0
BogoMIPS : 38.40
Features : fp asimd evtstrm crc32 cpuid
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x0
CPU part : 0xd03
CPU revision : 0
processor : 1
BogoMIPS : 38.40
Features : fp asimd evtstrm crc32 cpuid
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x0
CPU part : 0xd03
CPU revision : 0
processor : 2
BogoMIPS : 38.40
Features : fp asimd evtstrm crc32 cpuid
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x0
CPU part : 0xd03
CPU revision : 0
processor : 3
BogoMIPS : 38.40
Features : fp asimd evtstrm crc32 cpuid
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x0
CPU part : 0xd03
CPU revision : 0
Ha, this can actually be safely ignored, though I'm not sure whether gcc is allowed to take this liberty.
Maybe just call memmove and call it a day? The extra test and branch isn't going to make much of a difference. Plus, it's even possible that memmove might have logic to avoid moving any bytes at all when source and destination pointers are equal.
Most helpful comment
Ha, this can actually be safely ignored, though I'm not sure whether gcc is allowed to take this liberty.