-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
fix address alignment, required by cran #3415
Conversation
src/io/file_io.cpp
Outdated
@@ -47,6 +47,8 @@ struct LocalFile : VirtualFileReader, VirtualFileWriter { | |||
} | |||
|
|||
size_t Write(const void* buffer, size_t bytes) const { | |||
// 4 bytes alignment | |||
CHECK_EQ(bytes % 4, 0); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok I tried this using the steps in #3338 (comment), got a similar error too the one showing up in CI
I have an early morning tomorrow so I'm going to get some sleep, but if you're able to fix it I can test this again tomorrow! |
@jameslamb It turns out that the fix is not trivial. many parts need to rewrite. |
thanks very much! I'll test this right now with the steps from #3338 (comment) |
Ok I can see that the tests are all "passing" now, but I still see misalignment errors.
|
Okay, they need 8 bytes alignment. |
@jameslamb now it should work |
I see this in the CI jobs
|
sorry, it is a typo caused by editing on the web page. |
no problem! testing right now |
@guolinke THIS WORKED!! 🎉 No test failures, and no mis-alignment errors |
great! let us move forward to the memory leakage problem. |
ok sounds good! I will approve this so we can merge it, and I'll cherry-pick it onto #3338 I'm working on trying to reproduce the CRAN valgrind checks right now. |
* fix dataset binary file alignment * many fixes * fix warnings * fix bug * Update file_io.cpp * Update file_io.cpp * simplify code * Apply suggestions from code review * general * remove unneeded alignment * Update file_io.h * int32 to byte8 alignment * Apply suggestions from code review * Apply suggestions from code review
…3338) * [R-package] update DESCRIPTION per CRAN comments * newlines * Apply suggestions from code review Co-authored-by: Nikita Titov <nekit94-08@mail.ru> * more fixes * update Rbuildignore * more changes * more changes per CRAN response * add email * run examples in CI * add newest CRAN response * add Solaris patch * update patch * another attempt at ifaddrs patch * fix unnecessary comment * update configure * comments * bump version * tabs * fix address alignment, required by cran (#3415) * fix dataset binary file alignment * many fixes * fix warnings * fix bug * Update file_io.cpp * Update file_io.cpp * simplify code * Apply suggestions from code review * general * remove unneeded alignment * Update file_io.h * int32 to byte8 alignment * Apply suggestions from code review * Apply suggestions from code review * [R-package] add new copyright holder in DESCRIPTION (#3409) * [R-package] add new copyright holder in DESCRIPTION * fix role * fixing conflicts * [R-package] add new copyright holder in DESCRIPTION (#3409) * [R-package] add new copyright holder in DESCRIPTION * fix role * trying to fix conflicts * more fixes * this will work * update cran-comments * simplify solaris, add more testing docs * stuff * remove rchck docs * Apply suggestions from code review Co-authored-by: Nikita Titov <nekit94-08@mail.ru> * remove extra use of cat() * change solaris check * update docs * remove testing code * fix warning about cleanup not having execute permissions * fix cmake builds * remove blank line Co-authored-by: Nikita Titov <nekit94-08@mail.ru> Co-authored-by: Guolin Ke <guolin.ke@outlook.com>
This pull request has been automatically locked since there has not been any recent activity since it was closed. To start a new related discussion, open a new issue at https://github.com/microsoft/LightGBM/issues including a reference to this. |
No description provided.