paulfloyd / freebsd_valgrind

Git repo used to Upstream the FreeBSD Port of Valgrind
GNU General Public License v2.0
15 stars 4 forks source link

insn-pmovmsk fails #185

Closed paulfloyd closed 2 years ago

paulfloyd commented 2 years ago

`` / Create a conditional branch on which our output depends, so that memcheck cannot possibly optimize it away, either. / fprintf(stderr, "%d: Invalid value is %s\n", index, invalid ? "true" : "false");


Looks like a classic clang cmov vs GCC compare-and-jump-conditional.

2022ff: 49 b8 c8 05 20 00 00 movabs $0x2005c8,%r8 202306: 00 00 00 202309: 4c 0f 45 c1 cmovne %rcx,%r8 <<<<<======== there it is 20230d: 48 be ce 05 20 00 00 movabs $0x2005ce,%rsi 202314: 00 00 00 202317: 4c 89 c1 mov %r8,%rcx 20231a: b0 00 mov $0x0,%al 20231c: e8 bf 00 00 00 call 2023e0 fprintf@plt

paulfloyd commented 2 years ago

commit 54ee45d20808e02fcb162b29ef5f4d708c491884 (HEAD -> master, origin/master, origin/HEAD) Author: Paul Floyd pjfloyd@wanadoo.fr Date: Mon May 9 08:15:06 2022 +0200

Update clang version of insn-pmovmskb expected.

I'm not sure when this output changed.

This expected differs from the main GCC expected due to clang emitting
a cmovne for the ternary expression in 'use':
fprintf(stderr, "%d: Invalid value is %s\n", index, invalid ? "true" : "false");

Done.