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 -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer to CFLAGS #151

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions .azure-pipelines/azure-pipelines-linux.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ channel_targets:
cross_target_platform:
- osx-64
docker_image:
- quay.io/condaforge/linux-anvil-cos7-x86_64
- quay.io/condaforge/linux-anvil-x86_64:alma9
macos_machine:
- x86_64-apple-darwin13.4.0
meson_cpu_family:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ channel_targets:
cross_target_platform:
- osx-64
docker_image:
- quay.io/condaforge/linux-anvil-cos7-x86_64
- quay.io/condaforge/linux-anvil-x86_64:alma9
macos_machine:
- x86_64-apple-darwin13.4.0
meson_cpu_family:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ channel_targets:
cross_target_platform:
- osx-64
docker_image:
- quay.io/condaforge/linux-anvil-cos7-x86_64
- quay.io/condaforge/linux-anvil-x86_64:alma9
macos_machine:
- x86_64-apple-darwin13.4.0
meson_cpu_family:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ channel_targets:
cross_target_platform:
- osx-arm64
docker_image:
- quay.io/condaforge/linux-anvil-cos7-x86_64
- quay.io/condaforge/linux-anvil-x86_64:alma9
macos_machine:
- arm64-apple-darwin20.0.0
meson_cpu_family:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ channel_targets:
cross_target_platform:
- osx-arm64
docker_image:
- quay.io/condaforge/linux-anvil-cos7-x86_64
- quay.io/condaforge/linux-anvil-x86_64:alma9
macos_machine:
- arm64-apple-darwin20.0.0
meson_cpu_family:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ channel_targets:
cross_target_platform:
- osx-arm64
docker_image:
- quay.io/condaforge/linux-anvil-cos7-x86_64
- quay.io/condaforge/linux-anvil-x86_64:alma9
macos_machine:
- arm64-apple-darwin20.0.0
meson_cpu_family:
Expand Down
7 changes: 7 additions & 0 deletions build-locally.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions recipe/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
CHOST=${macos_machine}

FINAL_CPPFLAGS="-D_FORTIFY_SOURCE=2"
FINAL_CFLAGS="-ftree-vectorize -fPIC -fstack-protector-strong -O2 -pipe"
FINAL_CXXFLAGS="-ftree-vectorize -fPIC -fstack-protector-strong -O2 -pipe -stdlib=libc++ -fvisibility-inlines-hidden -fmessage-length=0"
FINAL_CFLAGS="-fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -ftree-vectorize -fPIC -fstack-protector-strong -O2 -pipe"
FINAL_CXXFLAGS="-fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -ftree-vectorize -fPIC -fstack-protector-strong -O2 -pipe -stdlib=libc++ -fvisibility-inlines-hidden -fmessage-length=0"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll have to read up on this, but at first glance, we don't want this in non CONDA_BUILD usage. We want to reduce the usage.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If it shouldn't be in non-CONDA_BUILD usage, we would add it directly to

CFLAGS_USED="@CFLAGS@ -isystem ${PREFIX}/include -fdebug-prefix-map=${SRC_DIR}=/usr/local/src/conda/${PKG_NAME}-${PKG_VERSION} -fdebug-prefix-map=${PREFIX}=/usr/local/src/conda-prefix"
or should we introduce another variable?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, add it directly there.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

https://www.brendangregg.com/blog/2024-03-17/the-return-of-the-frame-pointers.html is also a good resource for reading up. It probably doesn't add much to the Fedora page, it's just a different perspective.

if [[ "${uname_machine}" == "x86_64" ]]; then
FINAL_CFLAGS="-march=core2 -mtune=haswell -mssse3 $FINAL_CFLAGS"
FINAL_CXXFLAGS="-march=core2 -mtune=haswell -mssse3 $FINAL_CXXFLAGS"
Expand Down
2 changes: 1 addition & 1 deletion recipe/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
# of the C++ stdlib; keep the variable in case this happens again
{% set libcxx_major = major_ver %}

{% set build_number = 23 %}
{% set build_number = 24 %}

package:
name: clang-compiler-activation
Expand Down