Hi Martin, On Mon, 2019-07-08 at 10:42 -0700, Martin Buchholz wrote: > (not really a review ...) > > I'm confused because the assembler is invoked when compiling any sort of > source file - C, C++, or .s/.S. > Wouldn't we want assembler flags passed uniformly, no matter when the > assembler is invoked?
Good point. I guess that's debatable. The intention is to only affect assembling of, well, assembly files (.s/.S). Right now, --with-extra- cflags would work, but that's more an accident I'd think: http://hg.openjdk.java.net/jdk/jdk/file/377e49b3014c/make/autoconf/flags-other.m4#l119 In JDK 8 this is a real issue. See: https://bugs.openjdk.java.net/browse/JDK-8219772 During review this suggestion (with-extra-asflags) came up: http://mail.openjdk.java.net/pipermail/jdk8u-dev/2019-March/008861.html > It looks like this patch only affects compilation of .s/.S files in hotspot? Yes. I've only found assemly files in hotspot. Happy to add it for core libs, too, but not sure where. Thanks, Severin > On Mon, Jul 8, 2019 at 8:57 AM Severin Gehwolf <sgehw...@redhat.com> wrote: > > Hi, > > > > Could I please get a review for this patch which adds a new configure > > option --with-extra-asflags? The issue at hand is that we, Red Hat, > > need to pass certain extra flags to the assembler when OpenJDK is being > > compiled. -Wa,--generate-missing-build-notes=yes in our case. That's > > currently not possible and extra C/C++ flags would need to be used, > > which seems not nice. > > > > Bug: https://bugs.openjdk.java.net/browse/JDK-8227397 > > webrev: http://cr.openjdk.java.net/~sgehwolf/webrevs/JDK-8227397/01/webrev/ > > > > After this patch extra assembler flags get added to *.s/.S files for > > libjvm.so: > > > > $ grep -n generate-missing-build-notes=yes > > build/linux-x86_64-server-release/build.log > > 1049: [18] ASFLAGS := -m64 -Wa,--generate-missing-build-notes=yes > > 15005:( /usr/bin/rm -f > > /disk/openjdk/upstream-sources/openjdk-head/build/linux-x86_64-server-release/hotspot/variant-server/libjvm/objs/linux_x86_64.o.log > > && /usr/bin/gcc -c -m64 -Wa,--generate-missing-build-notes=yes -g -o > > /disk/openjdk/upstream-sources/openjdk-head/build/linux-x86_64-server-release/hotspot/variant-server/libjvm/objs/linux_x86_64.o > > > > /disk/openjdk/upstream-sources/openjdk-head/src/hotspot/os_cpu/linux_x86/linux_x86_64.s > > > >(/usr/bin/tee -a > > /disk/openjdk/upstream-sources/openjdk-head/build/linux-x86_64-server-release/hotspot/variant-server/libjvm/objs/linux_x86_64.o.log) > > 2> >(/usr/bin/tee -a > > /disk/openjdk/upstream-sources/openjdk-head/build/linux-x86_64-server-release/hotspot/variant-server/libjvm/objs/linux_x86_64.o.log > > >&2) || ( exitcode=$? && /usr/bin/cp > > /disk/openjdk/upstream-sources/openjdk-head/build/linux-x86_64-server-release/hotspot/variant-server/libjvm/objs/linux_x86_64.o.log > > > > /disk/openjdk/upstream-sources/openjdk-head/build/linux-x86_64-server-release/make-support/failure-logs/hotspot_variant-server_libjvm_objs_linux_x86_64.o.log > > && /usr/bin/cp > > /disk/openjdk/upstream-sources/openjdk-head/build/linux-x86_64-server-release/hotspot/variant-server/libjvm/objs/linux_x86_64.o.cmdline > > > > /disk/openjdk/upstream-sources/openjdk-head/build/linux-x86_64-server-release/make-support/failure-logs/hotspot_variant-server_libjvm_objs_linux_x86_64.o.cmdline > > && exit $exitcode ) ) > > > > I'll run this through jdk/submit before I push. > > > > Thoughts? > > > > Thanks, > > Severin > >