On Fri, 11 Nov 2022 20:34:34 GMT, Vladimir Ivanov <vliva...@openjdk.org> wrote:
>> I am mystified at how it actually gets removed from the `assembler_x86.o` >> object on 32-bit.. The only reliable/portable way _would_ be with `#ifdef` >> but its not there.. so.. code-generation? `sed`-like preprocessing? Can one >> edit object files after the gcc ran? The build must be doing something >> clever!! Haven't seen it yet.. >> >> Whatever the trick is, `assembler_x86.hpp` gets it, but not >> `macroAssembler_x86.hpp`. >> >> If it doesn't ring any bells, maybe I will spend some more time looking at >> the traces, maybe can figure out what the build script is doing to remove >> the symbol. > > It's not specific to `andq`: there's a huge `#ifdef` block around the > definitions in `assembler_x86.hpp` (lines 12201 - 13773; and there's even a > nested `#ifdef _LP64` (lines 13515-13585)!) , but declarations aren't guarded > by `#ifdef _LP64`. Yeah, just got to about the same conclusion by looking at the preprocessor `-E` output.. its declared in the header, but not defined in the 'cpp' file.. One would think that that's a compile error, but its been more then a decade since I looked at the C++ spec; 'C++ compiler is always right'. ------------- PR: https://git.openjdk.org/jdk/pull/10582