Git Product home page Git Product logo

Comments (4)

CensoredUsername avatar CensoredUsername commented on May 19, 2024

add xzr, x1, #0x1 is indeed unencodable, as can be seen in the instruction reference where the relevant format (two regs and an immediate) specifies:

add Xn|SP, Xm|SP, #uimm {, LSL #uimm1 }                         (#uimm < 4096, #uimm1 = [0, 12])

You're right that using an X dynamic register instead of an XSP dynamic register shouldn't allow this instruction to match at all, so something is going wrong here. I'll investigate.

from dynasm-rs.

CensoredUsername avatar CensoredUsername commented on May 19, 2024

Found the bug, that part of the code also allows non-XSP family registers through so normal registers that aren't the zero reg can be used. This exemption is needed for static registers (what family is X1, X or XSP), but it doesn't actually check that they're static so dynamic regs get a pass as well.

Easy fix, but will break working user code so probably have to cut a new release for this.

from dynasm-rs.

CensoredUsername avatar CensoredUsername commented on May 19, 2024

In the meantime you can try this fix at 83743bf.

from dynasm-rs.

CensoredUsername avatar CensoredUsername commented on May 19, 2024

This has been merged into master with v2.0.0.

from dynasm-rs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.