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

Update native config to support more configuration options #104

Merged
merged 3 commits into from
Jan 13, 2025

Conversation

KristianAN
Copy link
Contributor

@KristianAN KristianAN commented Jan 10, 2025

still missing linktimeProperties, sourceLevelDebuggingConfig and semanticsConfig

These properties are missing because I don't really understand them and when I looked at how mill handles linking they don't include these options...

I added @unroll nativeLinkerReleaseMode: Option[NativeLinkerReleaseMode] = None, as a way to preserve bincompat for LinkerMode. In bloop I configured it to default to release-fast if None and LinkerMode being Release. This also means than linking JS and Native still are similar.

Clients can override the linkermode for SN by setting the mode in NativeLinkerReleaseMode. I figure this is a good compromise for now.

still missing linktimeProperties, sourceLevelDebuggingConfig and
semanticsConfig
@KristianAN
Copy link
Contributor Author

I don't really get why mima is failing?

@tgodzik
Copy link
Contributor

tgodzik commented Jan 11, 2025

I don't really get why mima is failing?

Good question, and it seems to fail on an unapply. Maybe there is an optimization when there is more fields present? We might need to move it to a separate class?

@tgodzik
Copy link
Contributor

tgodzik commented Jan 11, 2025

Running javap or a decompiler could shed a light on it

@KristianAN
Copy link
Contributor Author

The mima issue happens with when the case class has more than 22 fields so maybe some optimization that is happening. Anyway I grouped some things in to case classes and made sure we had < 22 fields so that we can add another case class with more stuff later if needed. Preferably we can look at a 3.0 release somewhere down the line where we clean up everything.

I reduced the amount of fields by grouping some things in case classes
Copy link
Contributor

@tgodzik tgodzik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@tgodzik tgodzik merged commit 16c3b2d into scalacenter:main Jan 13, 2025
4 checks passed
@KristianAN KristianAN deleted the improve-sn-support branch January 13, 2025 11:31
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.

2 participants