Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • D dynamorio
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 1,467
    • Issues 1,467
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 44
    • Merge requests 44
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • DynamoRIO
  • dynamorio
  • Issues
  • #5447
Closed
Open
Issue created Apr 05, 2022 by Administrator@rootContributor

TZCNT is incorrectly decoded

Created by: dvyukov

Decoding this byte sequence: f3 f2 0f bc f2 DynamoRIO: tzcnt %edx -> %esi Capstone: bsf esi, edx llvm-mc: invalid instruction encoding objdump:

   0:	f3 f2 0f bc          	repz (bad) 
   4:	f2                   	repnz

Intel manual says TZCNT encodings are:

  F3 0F BC /r
  F3 REX.W 0F BC /r

Executing this instruction with different values of RDX always yields 0 in RSI, so effectively it seems to work as some kind of non-trapping nop (?).

If it's an invalid instruction for my use case it would be more useful if DynamoRIO would reject to decode it (or decode to something that would agree with CPU behavior, e.g. OP_nop).

On commit 6e887383.

Assignee
Assign to
Time tracking