Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add basic InstSimplify folds for CGetHigh and CSetFlags #697

Open
wants to merge 4 commits into
base: dev
Choose a base branch
from

Commits on Feb 12, 2024

  1. Configuration menu
    Copy the full SHA
    85efaa0 View commit details
    Browse the repository at this point in the history

Commits on Feb 13, 2024

  1. [InstSimplify] Simplify getoffset/getaddr folding code. NFC

    Now that we depend on C++14, we can use switches in constexpr functions
    and no longer need to pass two template parameters.
    arichardson committed Feb 13, 2024
    Configuration menu
    Copy the full SHA
    61a3130 View commit details
    Browse the repository at this point in the history
  2. [InstSimplify] Add folds for @llvm.cheri.cap.high.get

    As part of this refactor some of the CHERI get intrinsics folding code.
    This refactoring introduces a minor change to getoffset folding as well:
    we no longer fold arbitrary getoffset(setoffset(A, B)) -> B since the
    setoffset could have changed the bounds interpretation and therefore
    also the result. This optimization is unlikely to make a difference in
    practise and is somewhat incorrect so I believe dropping it makes sense.
    arichardson committed Feb 13, 2024
    Configuration menu
    Copy the full SHA
    fcc87ce View commit details
    Browse the repository at this point in the history
  3. [InstSimplify] Add basic fold for @llvm.cheri.cap.flags.set

    If we are setting the same value we just read we can simplify the
    sequence to just the original argument.
    arichardson committed Feb 13, 2024
    Configuration menu
    Copy the full SHA
    d9bf74f View commit details
    Browse the repository at this point in the history