-
Notifications
You must be signed in to change notification settings - Fork 110
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
primitiveImageFormatVersion may be not correct #638
Comments
It is a VM bug, sorry for overlooking this. Proposed fix in VMMaker inbox VMMaker.oscog-dtl.3185 |
Fix is in VMMaker (VMMaker.oscog-dtl.3185), still need to commit generated code and build VM. |
@marceltaeumel the fix inVMMaker.oscog-dtl.3185 is trivial, but I need someone else (you or Eliot) to do the code generation this time. The reason is that my generated code has differences that I cannot account for (specifically one value in the primitiveMetadataTable array is generated as 0x100 but should be 0x200, and in several places there are differences in integer type declarations). I have not be able to track down the reason for the differences, so I cannot commit the generated code. |
Wow. This is not over. Next issue is in |
The biggest issue for an image-side discrimination is that the VMMaker-specific constant |
For my understanding - is the concern with imageSegmentVersion a problem for practical reasons (something does not work as expected)? It certainly makes sense that an image segment should have a format number that matches the image from which it was saved, but as a practical matter does anything bad happen if this is not the case? |
In the extreme case, surely it could mean that the data was in a completely non-acceptable format?
On 2022-06-07, at 4:26 PM, David T Lewis ***@***.***> wrote:
For my understanding - is the concern with imageSegmentVersion a problem for practical reasons (something does not work as expected)? It certainly makes sense that an image segment should have a format number that matches the image from which it was saved, but as a practical matter does anything bad happen if this is not the case?
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.
tim
--
tim Rowledge; ***@***.***; http://www.rowledge.org/tim
Useful random insult:- A prime candidate for natural deselection.
|
I am trying to understand the real-world scenario in which this matters. I have an image running Sista bytecodes and my image format is 68533. I save an image segment to disk, and that image segment contains objects that contain compiled code that contain Sista bytecodes. The saved image segment records itself with format number 68021 (not 68533). Later on, someone loads that image segment using a VM that is a year or two old, so the VM does not know about 68533. But the VM probably does know how to run Sista bytecodes because it is only a year or two old. Everything still works, so as a practical matter what is the problem? |
Regarding image side code and MultipleBytecodeSetsBitmask in VMMaker, on the image side you would use this (only if necessary, and hopefully it is not necessary): (ImageFormat fromInteger: 68021) requiresMultipleBytecodeSupport ==> false |
Well, loads of tests fail or err at the moment. Maybe we should just fix the image-side load code for image segments to also accept 68021, even if the |
I committed a quickfix via System-mt.1355. Yet, this topic might need more discussion. |
My apologies, please disregard. Marcel, thank you for doing the code generation :-)
Dave
…On Thu, Jun 02, 2022 at 01:21:29PM -0700, David T Lewis wrote:
@marceltaeumel the fix inVMMaker.oscog-dtl.3185 is trivial, but I need someone else (you or Eliot) to do the code generation this time. The reason is that my generated code has differences that I cannot account for (specifically one value in the primitiveMetadataTable array is generated as 0x100 but should be 0x200, and in several places there are differences in integer type declarations). I have not be able to track down the reason for the differences, so I cannot commit the generated code.
--
Reply to this email directly or view it on GitHub:
#638 (comment)
You are receiving this because you are subscribed to this thread.
Message ID: ***@***.***>
|
The return value of
primitiveImageFormatVersion
is hard-coded and does not consider the value ofmultipleBytecodeSetsActive
, which is indeed important when trying to open a particular image with a particular VM.See:
And also:
Note that this can be fixed on the image-side by checking primitiveMultipleBytecodeSetsActive. Yet, we have a discrepancy between the definition of "image format" at time of snapshotting and during run-time.
The text was updated successfully, but these errors were encountered: