Bug 253436 - vex amd64->IR: unhandled instruction bytes: 0xF2 0xA6 (repne cmps)
Summary: vex amd64->IR: unhandled instruction bytes: 0xF2 0xA6 (repne cmps)
Status: RESOLVED FIXED
Alias: None
Product: valgrind
Classification: Developer tools
Component: vex (other bugs)
Version First Reported In: 3.6 SVN
Platform: Unlisted Binaries Linux
: NOR normal
Target Milestone: ---
Assignee: Paul Floyd
URL:
Keywords:
Depends on:
Blocks: 253451
  Show dependency treegraph
 
Reported: 2010-10-06 23:26 UTC by Vince Weaver
Modified: 2026-01-24 10:01 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments
Added missing cmps variants to VEX amd64. (1.81 KB, patch)
2020-01-10 17:53 UTC, jacobly.alt
Details
Uncomment tests for cmps variants for VEX amd64. (502 bytes, patch)
2026-01-20 19:07 UTC, Lukas Dullinger
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Vince Weaver 2010-10-06 23:26:23 UTC
Version:           3.6 SVN
OS:                Linux

The "repne cmps" string instruction is not supported on amd64

Reproducible: Didn't try
Comment 1 jacobly.alt 2020-01-10 17:53:37 UTC
Created attachment 125021 [details]
Added missing cmps variants to VEX amd64.

I was trying to run valgrind on some assembly code and it also chokes on a plain old cmps.  I implemented both in the attached patch.
Comment 2 Paul Floyd 2021-11-22 11:12:12 UTC
Do you have a testcase for this?
Comment 3 researchlover44 2026-01-19 21:48:22 UTC
(In reply to Paul Floyd from comment #2)
> Do you have a testcase for this?

Hi!
Can you point me to where I could provide this testcase?
BR
Comment 4 Paul Floyd 2026-01-20 09:37:47 UTC
Ideally just attach a small testcase here.
Comment 5 Lukas Dullinger 2026-01-20 19:07:44 UTC
Created attachment 188721 [details]
Uncomment tests for cmps variants for VEX amd64.

The test cases already existed, they were just commented out.
When applying this patch, valgrind reports illegal instructions when running the compiled test-amd64.c.
With the patch from attachment 125021 [details] applied, it does not report any issues anymore.
Comment 6 Paul Floyd 2026-01-22 06:03:11 UTC
!

I should have done a git rep before asking.
Comment 7 Paul Floyd 2026-01-24 10:01:57 UTC
Thanks for the contributions!

commit 1f5118fffdfbfb40405b8493ad6e8fee343c5759 (HEAD -> master, origin/users/paulf/try-bug253436, origin/master, origin/HEAD, bug253436)
Author: Paul Floyd <pjfloyd@wanadoo.fr>
Date:   Sat Jan 24 08:20:29 2026 +0100

    Bug 253436 - vex amd64->IR: unhandled instruction bytes: 0xF2 0xA6 (repne cmps)
    
    Patch submitted by jacobly.alt@gmail.com
    Regtest update submitted by Lukas Dullinger <itislu.git@gmail.com>