Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

LDC should not enable host CPU features by default #323

Closed
svenstaro opened this Issue · 2 comments

2 participants

@svenstaro

Judging by this issue posted by one of our users, there seems to be a problem with ldc currently picking best available flags on the host CPU. Arch uses -march=x86_64 for x86_64 so nothing fancy. It surely shouldn't enable AVX but apparently it does. The system I build this package on has AVX support. This might explain it. It is as though ldc uses -march=native.

This doesn't seem to be a downstream packaging problem on my side. Can you guys investigate please? The bug report I linked includes some helpful information.

@klickverbot
Owner

Yep, we should definitely do the equivalent of -mtune=generic by default.

@klickverbot klickverbot was assigned
@klickverbot
Owner

On it, just need a few quiet minutes to sit down and commit this.

I chose to just take the code from Clang.

Maybe this should be abstracted to into LLVM.

@klickverbot klickverbot referenced this issue from a commit in klickverbot/ldc
@klickverbot klickverbot Do not optimize for host CPU by default.
GitHub: Fixes #323.
1a2ca17
@klickverbot klickverbot referenced this issue from a commit in klickverbot/ldc
@klickverbot klickverbot Do not optimize for host CPU by default.
GitHub: Fixes #323.
b2ff695
@klickverbot klickverbot referenced this issue from a commit in klickverbot/ldc
@klickverbot klickverbot Do not optimize for host CPU by default.
GitHub: Fixes #323.
bd7f9a8
@klickverbot klickverbot referenced this issue from a commit in klickverbot/ldc
@klickverbot klickverbot Do not optimize for host CPU by default.
GitHub: Fixes #323.
dde0714
@klickverbot klickverbot referenced this issue from a commit in klickverbot/ldc
@klickverbot klickverbot Do not optimize for host CPU by default.
GitHub: Fixes #323.
c8949d7
@klickverbot klickverbot referenced this issue from a commit in klickverbot/ldc
@klickverbot klickverbot Do not optimize for host CPU by default.
GitHub: Fixes #323.
ef2f5e8
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.