Only set gcc's "-msse4.2", etc, option when compiling for generic targets.
We don't need it when ispc is just generating an object file directly, and gcc on OS X doesn't recognize -mavx.
This commit is contained in:
@@ -265,11 +265,9 @@ def run_test(filename):
|
|||||||
gcc_arch = '-m64'
|
gcc_arch = '-m64'
|
||||||
|
|
||||||
gcc_isa=""
|
gcc_isa=""
|
||||||
if options.target == 'sse2' or options.target == 'sse2-x2':
|
if options.target == 'generic-4':
|
||||||
gcc_isa = '-msse3'
|
|
||||||
if options.target == 'sse4' or options.target == 'sse4-x2' or options.target == 'generic-4':
|
|
||||||
gcc_isa = '-msse4.2'
|
gcc_isa = '-msse4.2'
|
||||||
if options.target == 'avx' or options.target == 'avx-x2' or options.target == 'generic-8':
|
if options.target == 'generic-8':
|
||||||
gcc_isa = '-mavx'
|
gcc_isa = '-mavx'
|
||||||
if (options.target == 'generic-16' or options.target == 'generic-32' or options.target == 'generic-64') \
|
if (options.target == 'generic-16' or options.target == 'generic-32' or options.target == 'generic-64') \
|
||||||
and (options.include_file.find("knc.h")!=-1 or options.include_file.find("knc2x.h")!=-1):
|
and (options.include_file.find("knc.h")!=-1 or options.include_file.find("knc2x.h")!=-1):
|
||||||
|
|||||||
Reference in New Issue
Block a user