mir-glas icon indicating copy to clipboard operation
mir-glas copied to clipboard

2 x slower with LLVM 4.X - 5.X

Open 9il opened this issue 9 years ago • 12 comments

LLVM 4.0, avx512f has the same issue as LLVM 4.0, broadwell.

LDC - the LLVM D compiler (1.1.1):
  based on DMD v2.071.2 and LLVM 4.0.0
  built with LDC - the LLVM D compiler (0.17.3)
  Default target: x86_64-apple-darwin16.4.0
  Host CPU: haswell
  http://dlang.org - http://wiki.dlang.org/LDC

vs

LDC - the LLVM D compiler (1.1.1):
  based on DMD v2.071.2 and LLVM 3.9.1
  built with LDC - the LLVM D compiler (1.1.1)
  Default target: x86_64-apple-darwin16.4.0
  Host CPU: haswell
  http://dlang.org - http://wiki.dlang.org/LDC

9il avatar Mar 30 '17 05:03 9il

Could you spend some time on minimizing this? Thanks!

JohanEngelen avatar Mar 30 '17 20:03 JohanEngelen

Could you spend some time on minimizing this? Thanks!

Done, please see gists list in the issue.

9il avatar Mar 31 '17 05:03 9il

@9il: What would probably be most useful is to generate the LLVM IR for the kernel function (-output-ll) and post it at bugs.llvm.org together with the assembler listings, possibly CCing some of the people who have worked on x86 codegen before (if you happen to know someone). Am I correct in the assumption that simple is just a manually expanded version of generic?

dnadlinger avatar Mar 31 '17 11:03 dnadlinger

Am I correct in the assumption that simple is just a manually expanded version of generic?

Yes.

9il avatar Mar 31 '17 11:03 9il

I have requested account at bugs.llvm.org

9il avatar Mar 31 '17 12:03 9il

Okay, thanks. If there are any issues with the account, I can also make the report for you.

dnadlinger avatar Mar 31 '17 14:03 dnadlinger

Any update on this? And does LLVM 4.0 only decrease performance on your code or are there improvements as well? We'll have to decide on the compiler to use to ship the pre-built 1.2 binaries soon.

dnadlinger avatar Apr 06 '17 15:04 dnadlinger

Only LLVM 4.0 has no bad AVX512 support. Feel free to update compiler to the LLVM 4.0. GLAS is not completely implemented for BLAS API. I will fill the issue and send link to the LDC gitter

9il avatar Apr 08 '17 12:04 9il

Any news on whether v4.0.1 or v5.0.0 fix this?

WebDrake avatar Sep 11 '17 21:09 WebDrake

I can not compile LDC with LLVM 5.0 on macos

9il avatar Sep 12 '17 10:09 9il

@9il: See Gitter – you might need to turn off detection of LLD headers explicitly with LLVM 5.0 until this is fixed.

dnadlinger avatar Sep 12 '17 10:09 dnadlinger

Any news on whether v4.0.1 or v5.0.0 fix this?

It is not fixed in v5.0

9il avatar Oct 27 '17 03:10 9il