-
Notifications
You must be signed in to change notification settings - Fork 10.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
Recent regression produces crash in clang #80127
Comments
Can't reproduce a crash on current main. What's the backtrace you got? |
|
@llvm/issue-subscribers-clang-frontend Author: None (dcb314)
[eggwrapbox-e1f21d.c.gz](https://github.com/llvm/llvm-project/files/14110352/eggwrapbox-e1f21d.c.gz)
[eggwrapbox-e1f21d.sh.gz](https://github.com/llvm/llvm-project/files/14110377/eggwrapbox-e1f21d.sh.gz)
I struggled to reproduce the bug here, so I hand it over to folks with more idea. |
Sounds like my fault. |
I can't reproduce either though, the output I get is: ../src/widgets/eggwrapbox.c:322:3: warning: 'g_type_class_add_private' is deprecated [-Wdeprecated-declarations]
322 | g_type_class_add_private (class, sizeof (EggWrapBoxPrivate));
| ^
/usr/include/glib-2.0/gobject/gtype.h:1382:1: note: 'g_type_class_add_private' has been explicitly marked deprecated here
1382 | GOBJECT_DEPRECATED_IN_2_58
| ^
/usr/include/glib-2.0/gobject/gobject-visibility.h:581:36: note: expanded from macro 'GOBJECT_DEPRECATED_IN_2_58'
581 | #define GOBJECT_DEPRECATED_IN_2_58 GOBJECT_DEPRECATED
| ^
/usr/include/glib-2.0/gobject/gobject-visibility.h:30:28: note: expanded from macro 'GOBJECT_DEPRECATED'
30 | #define GOBJECT_DEPRECATED G_DEPRECATED _GOBJECT_EXTERN
| ^
/usr/include/glib-2.0/glib/gmacros.h:1262:37: note: expanded from macro 'G_DEPRECATED'
1262 | #define G_DEPRECATED __attribute__((__deprecated__))
| ^
../src/widgets/eggwrapbox.c:331:5: warning: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE" [-W#pragma-messages]
331 | G_TYPE_INSTANCE_GET_PRIVATE (box, EGG_TYPE_WRAP_BOX, EggWrapBoxPrivate);
| ^
/usr/include/glib-2.0/gobject/gtype.h:686:145: note: expanded from macro 'G_TYPE_INSTANCE_GET_PRIVATE'
686 | #define G_TYPE_INSTANCE_GET_PRIVATE(instance, g_type, c_type) ((c_type*) g_type_instance_get_private ((GTypeInstance*) (instance), (g_type))) GOBJECT_DEPRECATED_MACRO_IN_2_58_FOR(G_ADD_PRIVATE)
| ^
/usr/include/glib-2.0/gobject/gobject-visibility.h:584:49: note: expanded from macro 'GOBJECT_DEPRECATED_MACRO_IN_2_58_FOR'
584 | #define GOBJECT_DEPRECATED_MACRO_IN_2_58_FOR(f) GLIB_DEPRECATED_MACRO_FOR (f)
| ^
/usr/include/glib-2.0/glib/gmacros.h:1299:3: note: expanded from macro 'GLIB_DEPRECATED_MACRO_FOR'
1299 | _GLIB_GNUC_DO_PRAGMA(GCC warning G_STRINGIFY (Deprecated pre-processor symbol: replace with #f))
| ^
/usr/include/glib-2.0/glib/gmacros.h:1296:33: note: expanded from macro '_GLIB_GNUC_DO_PRAGMA'
1296 | #define _GLIB_GNUC_DO_PRAGMA(x) _Pragma(G_STRINGIFY (x))
| ^
<scratch space>:47:6: note: expanded from here
47 | GCC warning "Deprecated pre-processor symbol: replace with \"G_ADD_PRIVATE\""
| ^
2 warnings generated. Do you have an in-development version of any of the dependencies installed? |
I am not sure I understand your question. I have enough installed to start the compilation, Here is what looks like a duplicate: test-gom-sorting-44de12.sh.gz Stack backtrace is
|
What version of glib and other dependencies your test case uses do you have installed?
No luck here either. :( |
glib2 is at version 2.76.6, but I don't see how that helps.
I am happy to write this bug report off as can't reproduce ;-| |
I compiled Clang at b5c0b67 in release configuration with assertions enabled, and can't reproduce the crash using either of the examples. |
@dcb314 Can you try to reduce your reproducers using |
Sadly no. See original comment. I struggle to reproduce it here. I suspect some other flag from the reproducer is required, but that is much later |
The crash happens when emitting a diagnostic, where we no re-lex part of the file. |
Thanks for the extra detail. I tried -g -O3 -march=native -Wall -Wextra and git revision I even added -Winvalid-pch and -Werror=format-security, from the reproducer I am still happy to write this one off as can't reproduce. |
@dcb314 are you getting this crash with some open source libraries? If that is the case can you share what libraries I'd need to configure and build and any other specific steps required to repro the crash? |
Yes, packages almanah & gom so far. From Fedora rawhide.
Not a feasible idea. I have a rather contrived development environment here. I have rebuilt today's clang with assertions enabled and now get this stack backtrace: Stack dump:
So the bug is reproducible here. I don't have enough compute power here to build clang with debug switched on (-g), My clang build script is the following: cmake -S /home/dcb38/llvm/trunk/llvm -B /home/dcb38/llvm/working If anyone can remove unneeded features from that script, but still build clang, Perhaps there is a debug flag (other than -g) that is really lightweight ?. |
Despite having this, there are still 6+ links running in parallel on a make with -j 16.
-g on its own is -g2. I am trying again with -g1, but even with 16 Gig RAM, there I also checked the number of binaries that my build script produces. bin $ pwd I am somewhat sceptical that all 103 binaries are the minimal set bin $ ls -C | more Now, how to not build all the ones I don't need ? |
eggwrapbox-e1f21d.c.gz
eggwrapbox-e1f21d.sh.gz
I struggled to reproduce the bug here, so I hand it over to folks with more idea.
The text was updated successfully, but these errors were encountered: