Skip to content

Commit

Permalink
JDK-8346987
Browse files Browse the repository at this point in the history
  • Loading branch information
MBaesken committed Jan 17, 2025
1 parent f5573f5 commit 9e8524b
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 12 deletions.
6 changes: 3 additions & 3 deletions make/hotspot/lib/CompileJvm.gmk
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Copyright (c) 2013, 2024, Oracle and/or its affiliates. All rights reserved.
# Copyright (c) 2013, 2025, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
Expand Down Expand Up @@ -174,7 +174,7 @@ $(eval $(call SetupJdkLibrary, BUILD_LIBJVM, \
EXCLUDE_FILES := $(JVM_EXCLUDE_FILES), \
EXCLUDE_PATTERNS := $(JVM_EXCLUDE_PATTERNS), \
DEFAULT_CFLAGS := false, \
CFLAGS := $(JVM_CFLAGS), \
CFLAGS := $(JVM_CFLAGS) $(JVM_CFLAGS_FEATURES_LTO), \
abstract_vm_version.cpp_CXXFLAGS := $(CFLAGS_VM_VERSION), \
arguments.cpp_CXXFLAGS := $(CFLAGS_VM_VERSION), \
DISABLED_WARNINGS_gcc := $(DISABLED_WARNINGS_gcc), \
Expand Down Expand Up @@ -221,7 +221,7 @@ $(eval $(call SetupJdkLibrary, BUILD_LIBJVM, \
ASFLAGS := $(JVM_ASFLAGS), \
LD_SET_ORIGIN := false, \
DEFAULT_LDFLAGS := false, \
LDFLAGS := $(JVM_LDFLAGS), \
LDFLAGS := $(JVM_LDFLAGS) $(JVM_LDFLAGS_FEATURES_LTO), \
LIBS := $(JVM_LIBS), \
OPTIMIZATION := $(JVM_OPTIMIZATION), \
OBJECT_DIR := $(JVM_OUTPUTDIR)/objs, \
Expand Down
18 changes: 9 additions & 9 deletions make/hotspot/lib/JvmFeatures.gmk
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Copyright (c) 2013, 2024, Oracle and/or its affiliates. All rights reserved.
# Copyright (c) 2013, 2025, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
Expand Down Expand Up @@ -170,23 +170,23 @@ ifeq ($(call check-jvm-feature, link-time-opt), true)
# later on if desired
JVM_OPTIMIZATION := HIGHEST_JVM
ifeq ($(call isCompiler, gcc), true)
JVM_CFLAGS_FEATURES += -flto=auto -fuse-linker-plugin -fno-strict-aliasing \
JVM_CFLAGS_FEATURES_LTO += -flto=auto -fuse-linker-plugin -fno-strict-aliasing \
-fno-fat-lto-objects
JVM_LDFLAGS_FEATURES += $(CXX_O_FLAG_HIGHEST_JVM) -flto=auto \
JVM_LDFLAGS_FEATURES_LTO += $(CXX_O_FLAG_HIGHEST_JVM) -flto=auto \
-fuse-linker-plugin -fno-strict-aliasing
else ifeq ($(call isCompiler, clang), true)
JVM_CFLAGS_FEATURES += -flto -fno-strict-aliasing
JVM_CFLAGS_FEATURES_LTO += -flto -fno-strict-aliasing
ifeq ($(call isBuildOs, aix), true)
JVM_CFLAGS_FEATURES += -ffat-lto-objects
JVM_CFLAGS_FEATURES_LTO += -ffat-lto-objects
endif
JVM_LDFLAGS_FEATURES += $(CXX_O_FLAG_HIGHEST_JVM) -flto -fno-strict-aliasing
JVM_LDFLAGS_FEATURES_LTO += $(CXX_O_FLAG_HIGHEST_JVM) -flto -fno-strict-aliasing
else ifeq ($(call isCompiler, microsoft), true)
JVM_CFLAGS_FEATURES += -GL
JVM_LDFLAGS_FEATURES += -LTCG:INCREMENTAL
JVM_CFLAGS_FEATURES_LTO += -GL
JVM_LDFLAGS_FEATURES_LTO += -LTCG:INCREMENTAL
endif
else
ifeq ($(call isCompiler, gcc), true)
JVM_LDFLAGS_FEATURES += -O1
JVM_LDFLAGS_FEATURES_LTO += -O1
endif
endif

Expand Down

0 comments on commit 9e8524b

Please sign in to comment.