-
Notifications
You must be signed in to change notification settings - Fork 79
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
Support for AnyCPU #48
Comments
I'm not sure that this is the best way to support AnyCPU. Rather, I think that we should change the order of the field offests, and make the value types come first (with an offset of 0) since Bool and Double have guarantees about their length in the Spec. Something like:
|
I would absolutely love to get away from separate X86 and X64 builds, if that is possible, but I have to defer to Fredrik on this one, since I don't know the nuances of the Boxing as well as he does. If we do this, I will immediately get a build of the project up on NuGet, since this was the primary reason for holding off. |
We may want to start using discriminated unions to circumvent the issue completely. From an API perspective this shouldn't be a major change. However the performance benefits of tagged unions are currently unknown to me from within a managed language. |
@ChaosPandion: We have to use this struct because of the performance implications of using a tagged union,this struct is the fastest possible way to do dynamic typing within the DLR |
@fholm: Are my changes feasible? I'm running the tests right now, but I cant test for regressions, since I hadn't run the tests before on this machine. (And, I have no access to the tests on my home computer right now, either.) |
…e reference types can grow to the end, as needed. This should alleviate the need for separate x86 / x64 builds. (re: issue #48)
(Sorry, Github auto-closed the issue.) I have run the Sputnik tests, and there were no regressions. I have also reconfigured the solution and project files to reflect the unified processor format. @fholm, I'll let you make the decision on whether to merge this into master. |
@jlarsson, we have made the update. I have also pushed it to NuGet! Whee! |
Ty guys. It works like a charm with NuGet. |
Thanks for the update! Now I can move over from Jint :) |
Support for AnyCPU can be enabled by
Currently,this would only be BoxedValueOffests in Runtime.fs.
Below is a proposed change
module BoxedValueOffsets =
#if X64
let [] ValueType = 8
let [] Tag = 12
let [] Marker = 14
#else
#if X86
let [] ValueType = 4
let [] Tag = 8
let [] Marker = 10
#else
let [] ValueType = 8
let [] Tag = 12
let [] Marker = 14
#endif
#endif
The text was updated successfully, but these errors were encountered: