Giter VIP home page Giter VIP logo

Comments (3)

mdb256 avatar mdb256 commented on May 31, 2024

Thanks for reporting this. This appears to be an issue with Clang/Xcode.

I don't have a 6th Gen Core (aka Skylake) machine running OS X, but I can replicate this using clang-3.6 on Linux on a Core i5-6600K.

Running clang -### -c -march=native -E - on Linux, the output contains the flags -target-cpu x86-64 so clang is failing to pick up the processor model. Further clang -march=native -dM -E - < /dev/null | grep SSE shows that the defines for anything over SSE2 aren't available (SSE2 is part of the x86-64 standard).

Clang-3.7 currently reports the target cpu as "broadwell", which is more accurate. There is no guarantee for when these processor detection improvements will make it into Xcode builds, though.

We will improve our CMake feature testing so we can pick this up earlier in the build process - relying on -march=native and not checking is obviously fragile.

A workaround right now is to add -march=core-avx2 to CFLAGS.

I'm no homebrew expert - far from it, in fact - but I was able to test this by running brew edit hyperscan and adding "-DCMAKE_C_FLAGS='-march=core-avx2'", "-DCMAKE_CXX_FLAGS='-march=core-avx2'" after *std_cmake_flags on line 21.

from hyperscan.

ilovezfs avatar ilovezfs commented on May 31, 2024

Unfortunately, that will still fail:

refurbishing removed:
-march=core-avx2
-O3
-Wall
-Wextra
-Wshadow
-Wcast-qual
-Werror
-Wvla
-Wpointer-arith
-Wstrict-prototypes
-Wmissing-prototypes

refurbishing added:
-pipe
-w
-Os
-march=native
-isystem/usr/local/include
-isystem/usr/include/libxml2
-isystem/System/Library/Frameworks/OpenGL.framework/Versions/Current/Headers

That, of course, is not your fault, but fixing it will require more intervention than that. It would be good if the source itself could be tweaked in some way not to fail with -march=native because that will be used unless a brew-very-non-standard system "xcrun", "make", "install" is used instead of a brew-standard system "make", "install".

from hyperscan.

ilovezfs avatar ilovezfs commented on May 31, 2024

@mdb256 OK, good news!
Using
Command Line Tools OS X 10.11 for Xcode 7.3 beta 5
instead of
Command Line Tools OS X 10.11 for Xcode 7.2
gives us

< CLT: 7.2.0.0.1.1447826929
< Clang: 7.0 build 700
---
> CLT: 7.3.0.0.1.1456551150
> Clang: 7.3 build 703

and the problem is fixed.

Xcode 7.3 will probably be released simultaneously with OS X 10.11.4 which is currently at
10.11.4 Beta 6 (15E61b) (March 7, 2016; 1 day ago)

So the final release should be within days, not weeks.

from hyperscan.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.