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

Create specification for fixed-point semantics #1

Open
KFAFSP opened this issue Jan 24, 2023 · 0 comments
Open

Create specification for fixed-point semantics #1

KFAFSP opened this issue Jan 24, 2023 · 0 comments

Comments

@KFAFSP
Copy link
Owner

KFAFSP commented Jan 24, 2023

We need to create a document that defines the behavior of all fixed-point operations we implement, i.e., the precise ones. We should also specify the expected behavior that lowering to a back-end produces for the closed operations.

In general:

  • Closed operations only use the data type of the operands, even for intermediaries, and therefore rely on microarchitectural details (e.g., overflow & carry).
  • Closed operations can always be lowered to precise ones, but that may not be useful in all cases.
  • Precise operations always return the smallest static supertype that can exactly encode the result value for the given operands. This must be unambiguous and deterministic.

Refer to FixedPointInterpreter for current assumptions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant