-
Bug
-
Resolution: Fixed
-
P2
-
8
-
b49
-
Not verified
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-8024569 | 8 | Harold Seigel | P2 | Closed | Fixed | b107 |
In file make/bsd/makefiles/gcc.make - the optimization level specified for unsafe.cpp is -01 instead of -O1.
In file make/bsd/makefiles/gcc.make the following comment is incorrect:
# There are some files which don't like precompiled headers
# The following files are build with 'OPT_CFLAGS/NOOPT' (-O0) in the opt build.
# But Clang doesn't support a precompiled header which was compiled with -O3
# to be used in a compilation unit which uses '-O0'. We could also prepare an
# extra '-O0' PCH file for the opt build and use it here, but it's probably
# not worth the effort as long as only two files need this special handling.
Needs to be updated to reflect:
- Not all files in the list are compiled with 'OPT_CFLAGS/NOOPT'.
- The precompiled header may be compiled with -O3 or -Os depending on the setting of 'OPT_CFLAGS_DEFAULT'.
- This is not just an issue between the compilation of -O0 and -O3. The issue is more general. When USE_CLANG is true, if the PCH file is compiled at a higher optimization level, (-Os or -O3), than the C++ file, (-O0 thru -O2), the following compile time error message is generated.
error: __OPTIMIZE_SIZE__ predefined macro was enabled in PCH file but is currently disabled
- The last sentence should be updated, because since the files in the list are not all compiled with -O0, the solution would only solve the issue for some of the files but not all.
- backported by
-
JDK-8024569 Incorrect optimization level and comment specified for unsafe.cpp
-
- Closed
-