INCLUDE_TSAN inconsistent between launcher and hotspot

Jean Christophe Beyler jcbeyler at google.com
Fri Apr 19 19:42:02 UTC 2019


Renaming seems to remove any problems, perhaps LAUNCHER_INCLUDE_TSAN or
something?
Jc

On Fri, Apr 19, 2019 at 2:07 PM Man Cao <manc at google.com> wrote:

> The launcher's source code is completely separate from HotSpot. The
> launcher cannot use the macros defined in macros.hpp.
> There are two macros both called INCLUDE_TSAN, but for HotSpot it is
> defined to 0 or 1, for launcher it is just a symbol without any value.
>
> I think the difference is OK, but a bit confusing for readers of the code.
> Do we want to rename one of them?
>
> -Man
>
>
> On Fri, Apr 19, 2019 at 11:43 AM Arthur Eubanks <aeubanks at google.com>
> wrote:
>
> > In a previous change it was mentioned that we should use "#if
> > INCLUDE_TSAN", not "#ifdef INCLUDE_TSAN".
> >
> > I looked at all INCLUDE_TSAN, and the one
> > in src/java.base/share/native/launcher/main.c is different from the ones
> in
> > hotspot. I tried the following change:
> >
> >
> http://cr.openjdk.java.net/~aeubanks/tsanmainincludetsan/webrev.00/src/java.base/share/native/launcher/main.c.udiff.html
> > but I get
> > error: "INCLUDE_TSAN" is not defined, evaluates to 0 [-Werror=undef]
> >
> > In src/hotspot/share/utilities/macros.hpp in hotspot, there's
> > #ifndef INCLUDE_TSAN
> > #define INCLUDE_TSAN 1
> > #endif
> >
> > Do we need something like this in the launcher? Or is the difference ok?
> >
>


-- 

Thanks,
Jc


More information about the tsan-dev mailing list