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

[Feat] Configure global state at compile-time #13

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

mohamed
Copy link

@mohamed mohamed commented May 23, 2019

This patch adds preprocessor facilities to enable choosing between
global state (SoftFloatv3 default) and adding a "state" parameter
to all functions. This has been discussed already by John Hauser
at: #5

This patch takes the position of enabling both options using a
preprocessor macro named "SOFTFLOAT_USE_GLOBAL_STATE". If the macro
is defined, then it uses global state as it does already. If the
macro is undefined, then it adds a state parameter which is a struct
defined in softfloat_types.h

This patch adds preprocessor facilities to enable choosing between
global state (SoftFloatv3 default) and adding a "state" parameter
to all functions. This has been discussed already by John Hauser
at: ucb-bar#5

This patch takes the position of enabling both options using a
preprocessor macro named "SOFTFLOAT_USE_GLOBAL_STATE". If the macro
is defined, then it uses global state as it does already. If the
macro is undefined, then it adds a state parameter which is a struct
defined in softfloat_types.h
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

Successfully merging this pull request may close these issues.

1 participant