-
Notifications
You must be signed in to change notification settings - Fork 141
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
[MSVC] Object file size cannot exceed 4 GB #1448
Comments
Yes, this is an MSVC compiler bug, which I reported and they fixed in less than 24 hours. But, we're now waiting on the next incremental release. This seems only to occur with the function Here is the bug report: https://developercommunity.visualstudio.com/t/Memory-Explosion:-compiler-limit:-objec/10795558 |
I ran onto this issue with simple_enum tests, tried to fix it without luck .. target_compile_options(glaze_enum_name_ut PRIVATE
"/bigobj"
"/Zm500" # Increased memory allocation
"/Os" # Favor small code size
)
target_link_options(glaze_enum_name_ut PRIVATE "/LARGEADDRESSAWARE") |
Yeah, I think this was due to a memory leak in the MSVC compiler, which they fixed, but we need to wait until the next incremental version to be released. |
I'm also encountering this issue when using a simple struct with explicit metadata with a struct function_data
{
std::uint64_t id;
std::string name;
glz::raw_json params;
}; template <>
struct glz::meta<function_data>
{
using T = function_data;
static constexpr auto value = object( //
"saucer:call", skip{}, // Using this line causes the error, without it, no error occurs.
&T::id, //
&T::name, //
"params", glz::escaped<&T::params> //
);
}; Is there something I can do while we wait for a proper upstream fix? |
This is an MSVC compiler bug: https://developercommunity.visualstudio.com/t/Memory-Explosion:-compiler-limit:-objec/10795558 We're awaiting the next MSVC minor release, which is usually every few weeks. They fixed the bug internally, but have yet to release it. You could go back to a previous version of MSVC. They didn't give any indication of what went wrong, so I wouldn't know of any work arounds. |
Thanks for the swift response!
Good to know, hope it'll be released soon ^^ |
I checked the MSVC 17.12.3 release from December 3rd and looked at their notes and the fix has not yet been released. Still waiting... |
MSVC 17.13 Preview fixes this problem for me, seems like they might not include it in an incremental 17.12 release after all... -.- |
With the newest release of MSVC 17.12 / 19.42.34433.0 the object file size seems to explode. With Version 17.11 / 19.41 the object has less than 10 MB. Something in the new MSVC makes glaze explode. Here is the log:
Link to my failed CI job: https://github.com/christianbrugger/logiksim/actions/runs/11875447310/job/33092660483
This happens when building glaze: https://github.com/stephenberry/glaze/actions/runs/11935224664/job/33266080750
I am sure you guys are aware of the issue.
How is the status so far. Does this need to be fixed in the MSVC compiler. Or will this be fixable in glaze?
The text was updated successfully, but these errors were encountered: