Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add -O2 copt to release config #893

Merged
merged 1 commit into from
Jan 7, 2022
Merged

Add -O2 copt to release config #893

merged 1 commit into from
Jan 7, 2022

Conversation

pudelkoM
Copy link
Member

@pudelkoM pudelkoM commented Jan 7, 2022

Currently we append a special bazelrc file for CI runs. It overrides the compiler optimization level with -O0. This is not suitable for release builds. Therefore we add the copt for release builds explicitly.

fixes #891

Currently we append a special bazelrc file for CI runs. It overrides the compiler optimization level with `-O0`. This is not suitable for release builds. Therefore we add the copt for release builds explicitly.

fixes #891
@pudelkoM
Copy link
Member Author

pudelkoM commented Jan 7, 2022

Invocation with -O2 last:

/usr/bin/clang -U_FORTIFY_SOURCE -fstack-protector -Wall -Wthread-safety -Wself-assign -Wno-free-nonheap-object -fcolor-diagnostics -fno-omit-frame-pointer -g0 -O2 '-D_FORTIFY_SOURCE=1' -DNDEBUG -ffunction-sections -fdata-sections '-std=c++0x' -MD -MF bazel-out/k8-opt/bin/external/com_github_openconfig_hercules/_objs/openconfig_proto/openconfig.pb.d '-frandom-seed=bazel-out/k8-opt/bin/external/com_github_openconfig_hercules/_objs/openconfig_proto/openconfig.pb.o' -iquote external/com_github_openconfig_hercules -iquote bazel-out/k8-opt/bin/external/com_github_openconfig_hercules -iquote external/com_google_protobuf -iquote bazel-out/k8-opt/bin/external/com_google_protobuf -iquote external/zlib -iquote bazel-out/k8-opt/bin/external/zlib -iquote external/com_github_openconfig_ygot_proto -iquote bazel-out/k8-opt/bin/external/com_github_openconfig_ygot_proto -Ibazel-out/k8-opt/bin/external/com_github_openconfig_hercules/_virtual_includes/openconfig_proto -Ibazel-out/k8-opt/bin/external/com_github_openconfig_ygot_proto/_virtual_includes/yext_proto -Ibazel-out/k8-opt/bin/external/com_google_protobuf/_virtual_includes/descriptor_proto -Ibazel-out/k8-opt/bin/external/com_github_openconfig_ygot_proto/_virtual_includes/ywrapper_proto -Ibazel-out/k8-opt/bin/external/com_google_protobuf/_virtual_includes/any_proto -isystem external/com_google_protobuf/src -isystem bazel-out/k8-opt/bin/external/com_google_protobuf/src -isystem external/zlib -isystem bazel-out/k8-opt/bin/external/zlib -O0 -O2 '-std=gnu++11' -no-canonical-prefixes -Wno-builtin-macro-redefined '-D__DATE__="redacted"' '-D__TIMESTAMP__="redacted"' '-D__TIME__="redacted"' -c bazel-out/k8-opt/bin/external/com_github_openconfig_hercules/_virtual_imports/openconfig_proto/openconfig/openconfig.pb.cc -o bazel-out/k8-opt/bin/external/com_github_openconfig_hercules/_objs/openconfig_proto/openconfig.pb.o

@codecov
Copy link

codecov bot commented Jan 7, 2022

Codecov Report

Merging #893 (f849d74) into main (4be1639) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##             main     #893   +/-   ##
=======================================
  Coverage   78.80%   78.80%           
=======================================
  Files         336      336           
  Lines       30128    30128           
=======================================
  Hits        23742    23742           
  Misses       6386     6386           

@pudelkoM pudelkoM merged commit f632af8 into main Jan 7, 2022
@pudelkoM pudelkoM deleted the bazelrc-release-opt-2 branch January 7, 2022 18:58
5abeel pushed a commit to ipdk-io/stratum-dev that referenced this pull request Jan 9, 2024
Currently we append a special bazelrc file for CI runs. It overrides the compiler optimization level with `-O0`. This is not suitable for release builds. Therefore we add the copt for release builds explicitly.

fixes stratum#891
ffoulkes added a commit to ipdk-io/stratum-dev that referenced this pull request Jan 13, 2024
Signed-off-by: Derek G Foster <derek.foster@intel.com>
ffoulkes added a commit to ipdk-io/stratum-dev that referenced this pull request Jan 17, 2024
Signed-off-by: Derek G Foster <derek.foster@intel.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

CI release builds are compiled with -O0
1 participant