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

Store values for initializer nodes? #783

Open
ehaas opened this issue Oct 5, 2024 · 1 comment
Open

Store values for initializer nodes? #783

ehaas opened this issue Oct 5, 2024 · 1 comment
Labels
question Further information is requested

Comments

@ehaas
Copy link
Collaborator

ehaas commented Oct 5, 2024

I started working on an assembly backend and one thing I ran into is needing the value of initializer nodes that are the result of an expression. For example given the following (x is global):

int x = 2 + 2;

I want to be able to get the initializer value of 4 without having to recompute it in the backend. As things currently work I think I'd have to recompute it, unless I'm missing something.

@ehaas ehaas added the question Further information is requested label Oct 5, 2024
@Vexu
Copy link
Owner

Vexu commented Oct 6, 2024

I don't remember any reason not to store the value and would have expected it to already be done. At least changing it is easy.

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

No branches or pull requests

2 participants