zstd icon indicating copy to clipboard operation
zstd copied to clipboard

Fix building on Solaris 10 x86_64 GCC 4.9.2

Open likema opened this issue 1 year ago • 4 comments

Prevent building x86_64 ASM from Solaris x86_64

likema avatar Jan 13 '24 16:01 likema

This PR conflicts with an old patch that was recently merged. It should be trivially fixable though.

Cyan4973 avatar Jan 13 '24 19:01 Cyan4973

This PR conflicts with an old patch that was recently merged. It should be trivially fixable though.

Fixed

likema avatar Jan 13 '24 19:01 likema

I finally found the time to create a Solaris test for Github Actions. It can be seen here : https://github.com/facebook/zstd/actions/runs/7690458663/job/20954282520?pr=3885

The test includes running cmake, both build and install stages. I was expecting it to fail, considering the description of this PR, which is accepted but not merged, hence not yet applied to #3885. But apparently, it's not necessary : the test just runs completely fine without it.

Among the potential differences that could explain this surprising outcome: this PR mentions an issue with Solaris 10 and gcc 4.9.2, while #3885 runs a Solaris VM version 11.4, shipping gcc 5.5.0. So maybe something changed between versions 10 and 11 (gcc version notably).

Conversely, it also means that this patch might be a bit too strong: if I read it correctly, it removes assembly support for any version of SunOS. But, since 11.4 works fine, it could miss some performance due to the removal of this support.

Therefore, it seems a more adjusted solution would be to limit removal of asm support for Solaris version 10 and below.

Cyan4973 avatar Jan 29 '24 03:01 Cyan4973

You are right.

Checking if x86_64 ASM source can be compiled in cmake may be a better solution.

I will try to do it later

likema avatar Jan 29 '24 09:01 likema