[Bug target/80115] [7 Regression] OpenJDK 1.8 fails to build
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80115 Jakub Jelinek changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |INVALID --- Comment #10 from Jakub Jelinek --- Not a GCC bug then. https://sourceware.org/git/gitweb.cgi?p=systemtap.git;a=commitdiff;h=272146660f54786bb61d388f6d3a4eb20e7d9369
[Bug target/80115] [7 Regression] OpenJDK 1.8 fails to build
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80115 --- Comment #9 from Frank Ch. Eigler --- Thanks, Jakub; git systemtap now includes your %w[] patch.
[Bug target/80115] [7 Regression] OpenJDK 1.8 fails to build
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80115 --- Comment #8 from Jakub Jelinek --- Then do: --- /usr/include/sys/sdt.h 2017-01-25 23:20:05.0 +0100 +++ /usr/include/sys/sdt.h 2017-03-21 15:26:14.448999404 +0100 @@ -173,6 +173,8 @@ __extension__ extern unsigned long long #if defined __powerpc__ || defined __powerpc64__ # define _SDT_ARGTMPL(id) %I[id]%[id] +#elif defined __i386__ +# define _SDT_ARGTMPL(id) %w[id] #else # define _SDT_ARGTMPL(id) %[id] #endif and it ought to work right (and as added bonus be more compact (shorter strings)).
[Bug target/80115] [7 Regression] OpenJDK 1.8 fails to build
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80115 --- Comment #7 from Frank Ch. Eigler --- The systemtap operand encoding machinery separately gives us the byte-size of the operand, so even if gcc told us %si, we'd only look at %sil only anyway. But if gcc cannot let that level of ambiguity be, then I guess we must work around the change. In the sdt.h, we enjoyed using machine-independent operant-constraint codes - until now, I guess.
[Bug target/80115] [7 Regression] OpenJDK 1.8 fails to build
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80115 --- Comment #6 from Jakub Jelinek --- %si is 16-bit register name, not 8-bit register name. For that you need to use 16-bit operand, not 8-bit. Another option is to use a modifier to force some other size. I don't know what the stap note parser actually cares about, if it doesn't make any difference between %al, %ax, %eax and grabs the argument size from somewhere else, you might e.g. #define _SDT_ARGTMPL(id) %k[id] instead of %[id] for defined(__i386__) and then you'll always get %eax, %esi, etc. regardless of whether the argument is 8-bit, 16-bit, 32-bit or 64-bit. Or you can use %w[id] to always get %ax, %si, etc. (shorter).
[Bug target/80115] [7 Regression] OpenJDK 1.8 fails to build
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80115 --- Comment #5 from Frank Ch. Eigler --- (In reply to Jakub Jelinek from comment #4) > This "worked" in gcc 6 and earlier because we happily emitted %sil etc. into > the inline assembly, even when it is not valid for 32-bit code, but starting > with r245815 we diagnose that. Just curious, but could the "r" constraint be reinterpreted by gcc>6 so that it emits %si etc. for these small values rather than %sil?
[Bug target/80115] [7 Regression] OpenJDK 1.8 fails to build
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80115 Jakub Jelinek changed: What|Removed |Added CC||fche at redhat dot com, ||jakub at gcc dot gnu.org, ||rth at gcc dot gnu.org, ||uros at gcc dot gnu.org --- Comment #4 from Jakub Jelinek --- That looks like a systemtap or OpenJDK bug to me. For bool and other 8-bit values, one can't use the "r" constraint on ia32, but has to use "q" constraint instead, because ia32 32-bit doesn't have %sil, %dil, %bpl and %spl registers. So, for #ifdef __i386__, either sdt.h needs to force the sub-int arguments into int (e.g. #define _SDT_ARGVAL(x) ((x) + 0) would do it I think), or # define STAP_SDT_ARG_CONSTRAINTnoq instead of nor (again, ia32 only), or perhaps use the constraint conditional depending on sizeof (x). This "worked" in gcc 6 and earlier because we happily emitted %sil etc. into the inline assembly, even when it is not valid for 32-bit code, but starting with r245815 we diagnose that.
[Bug target/80115] [7 Regression] OpenJDK 1.8 fails to build
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80115 --- Comment #3 from Richard Biener --- This is from systemtap 3.0, didn't try with 3.1 which seems to be available since a few weeks.
[Bug target/80115] [7 Regression] OpenJDK 1.8 fails to build
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80115 Markus Trippelsdorf changed: What|Removed |Added Status|UNCONFIRMED |NEW Last reconfirmed||2017-03-20 CC||trippels at gcc dot gnu.org Ever confirmed|0 |1 --- Comment #2 from Markus Trippelsdorf --- struct A { void m_fn1(); void m_fn2(bool, bool); }; void A::m_fn2(bool p1, bool p2) { m_fn1(); __asm__( ".asciz \"%n[_SDT_S1]@%[_SDT_A1] @%[_SDT_A2] @%[_SDT_A3] @%[_SDT_A4]\"" :: [_SDT_S1] "n"(0), [_SDT_A1] "n"(0), [_SDT_A2] "nor"(p1), [_SDT_A3] "n"(0), [_SDT_A4] "nor"(p2)); }
[Bug target/80115] [7 Regression] OpenJDK 1.8 fails to build
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80115 Richard Biener changed: What|Removed |Added Target Milestone|--- |7.0
[Bug target/80115] [7 Regression] OpenJDK 1.8 fails to build
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80115 --- Comment #1 from Richard Biener --- Created attachment 41003 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=41003=edit unreduced testcase