-
Notifications
You must be signed in to change notification settings - Fork 13
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
Arena may produce misaligned values #16
Comments
ortuman
added a commit
that referenced
this issue
Mar 6, 2024
ref: #16 Signed-off-by: Miguel Ángel Ortuño <[email protected]>
ortuman
added a commit
that referenced
this issue
Mar 6, 2024
ref: #16 Signed-off-by: Miguel Ángel Ortuño <[email protected]>
ortuman
added a commit
that referenced
this issue
Mar 6, 2024
ref: #16 Signed-off-by: Miguel Ángel Ortuño <[email protected]>
ortuman
added a commit
that referenced
this issue
Mar 6, 2024
ref: #16 Signed-off-by: Miguel Ángel Ortuño <[email protected]>
ortuman
added a commit
that referenced
this issue
Mar 6, 2024
ref: #16 Signed-off-by: Miguel Ángel Ortuño <[email protected]>
ortuman
added a commit
that referenced
this issue
Mar 6, 2024
ref: #16 Signed-off-by: Miguel Ángel Ortuño <[email protected]>
Thank you for reporting the issue @MortenLohne. I was aware that allocated pointers were not aligned, and I had planned to change this. However I simply assumed it could negatively affect performance, but it never occurred to me that with Anyway, I've already worked on a fix, and after merging #17 , this condition should not occur again. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Mixing and matching multiple types in an arena may produce misaligned values, like an
int
at an odd byte:The Go spec requires all values to be aligned correctly. For example, this test fails if run with
go test -race
:In theory, even a monotype arena can produce unaligned values, because the go spec does not guarantee that the underlying
[]byte
is 8-byte aligned in the first place.The text was updated successfully, but these errors were encountered: