Skip to content

Commit c87a4db

Browse files
authored
Fix checks for AVX512 and atomics
1 parent 93a8185 commit c87a4db

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

c_check

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -254,7 +254,7 @@ if (($architecture eq "x86") || ($architecture eq "x86_64")) {
254254
# $tmpf = new File::Temp( UNLINK => 1 );
255255
($fh,$tmpf) = tempfile( SUFFIX => '.c' , UNLINK => 1 );
256256
$code = '"vbroadcastss -4 * 4(%rsi), %zmm2"';
257-
print $tmpf "#include <immintrin.h>\n\nint main(void){ __asm__ volatile($code); }\n";
257+
print $fh "#include <immintrin.h>\n\nint main(void){ __asm__ volatile($code); }\n";
258258
$args = " -march=skylake-avx512 -c -o $tmpf.o $tmpf";
259259
if ($compiler eq "PGI") {
260260
$args = " -tp skylake -c -o $tmpf.o $tmpf";
@@ -278,7 +278,7 @@ if ($data =~ /HAVE_C11/) {
278278
$c11_atomics = 0;
279279
} else {
280280
($fh,$tmpf) = tempfile( SUFFIX => '.c' , UNLINK => 1 );
281-
print $tmpf "#include <stdatomic.h>\nint main(void){}\n";
281+
print $fh "#include <stdatomic.h>\nint main(void){}\n";
282282
$args = " -c -o $tmpf.o $tmpf";
283283
my @cmd = ("$compiler_name $flags $args >/dev/null 2>/dev/null");
284284
system(@cmd) == 0;

0 commit comments

Comments
 (0)