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

Fallback from -O3 to -O2 -ftree-vectorize #223

Open
V10lator opened this issue Jan 10, 2019 · 1 comment
Open

Fallback from -O3 to -O2 -ftree-vectorize #223

V10lator opened this issue Jan 10, 2019 · 1 comment

Comments

@V10lator
Copy link

According to https://gcc.gnu.org/ml/gcc/2019-01/msg00019.html it might be a good idea to use "-O2 -ftree-vectorize" in case -O3 fails on modern CPUs. Only if -ftree-vectorize fails (which didn't happen for me while compiling ~600 packages) one should fallback to plain -O2.

With GCC 10 this might no longer be needed (if you look at the link you'll notice that GCC devs think about including -ftree-vectorize into -O2) but untill then I think it would be nice to have.

@ionenwks
Copy link

On that topic, I just found something curious with -O2 -ftree-vectorize on rxvt-unicode 9.22. If I build it with -O3, it's fine, with -O2 it's also fine, but if I build it with -O2 -ftree-vectorize it segfaults while creating the window. Adding -ftree-loop-distribute-patterns (which is normally enabled by -O3) fixes it.

Not sure if it's a gcc bug, something misleading the compiler in rxvt, or something more specific to my setup. Haven't found anything else affected but it may possibly be unsafe on its own.

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

No branches or pull requests

2 participants