Details
Details
- Reviewers
spatel efriedma majnemer rja bkramer - Commits
- rGcd93c4ef1ac4: [InstCombine] snprintf optimizations
rG9b5e6e828850: [InstCombine] snprintf optimizations
rG44a37f04b253: [InstCombine] snprintf optimizations
rL332110: [InstCombine] snprintf optimizations
rL331889: [InstCombine] snprintf optimizations
rL331849: [InstCombine] snprintf optimizations
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
test/Transforms/InstCombine/snprintf.ll | ||
---|---|---|
10 ↗ | (On Diff #144779) | Remove dso_local Add test for snprintf(buf, 0, fmt) |
Comment Actions
This caused lots of assertion errors in building code with mingw-w64 headers (where snprintf can be a static inline function), see https://bugs.llvm.org/show_bug.cgi?id=37408. I would like to revert this change to unbreak things until this can be fixed.
Comment Actions
C standard says:
int snprintf(char * restrict s, size_t n, const char * restrict format, ...);
Comment Actions
Yes, but that's not an argument for making the compiler trigger a failed assertion if faced with code that doesn't exactly comply with it. Reverted until this issue is fixed.
Comment Actions
But I am not sure how to fix. This is not related to just snprintf case at all then.
@efriedma Eli maybe knows better what we should do, so please Eli can you look at that crash?