Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add libjpeg-turbo as jpeg #62

Merged
merged 1 commit into from
Nov 13, 2019
Merged

Add libjpeg-turbo as jpeg #62

merged 1 commit into from
Nov 13, 2019

Conversation

rbsheth
Copy link
Member

@rbsheth rbsheth commented Nov 11, 2019

Adding experimental functionality to see if turbojpeg can replace libjpeg in existing dependencies. Avoiding making turbojpeg the default option.

Something to note is that turbojpeg will generate machine code that may not be portable (ex. with AVX2) but Hunter will still cache and distribute the binaries to similar machines. Perhaps we need to add an architecture flag to the toolchain or the package name.

@rbsheth rbsheth requested a review from bkotzz November 11, 2019 23:15
@rbsheth rbsheth self-assigned this Nov 11, 2019
@hjmallon
Copy link

libjpeg_turbo != turbojpeg. They have a page about it (https://libjpeg-turbo.org/About/TurboJPEG).

I think the library should be called libjpeg_tubo everywhere to avoid confusion.

Also I believe (though I am not sure) that libjpeg_turbo should gate its SIMD behind cpuid calls (so at least objects on the same arch (x64, x86, arm64) should be compatible, but I'm not sure about that.

@rbsheth rbsheth changed the title Add turbojpeg as jpeg Add libjpeg-turbo as jpeg Nov 12, 2019
@rbsheth
Copy link
Member Author

rbsheth commented Nov 12, 2019

@hjmallon Good point, I renamed the PR title to reflect which turbo version we're referring to.

Perhaps keeping the turbo in the version is sufficient as far as Hunter is concerned here? This is a turbo version within the libjpeg package description.

I suppose SIMD could be gated behind cpuid calls, but I'm sure that there are packages that do not gate correctly. I wonder what we should do in those cases.

@hjmallon
Copy link

Yeah I'm not sure about that. It's probably a separate issue. I think we have had invalid instruction problems with GRPC between AVX/AVX2 machines before so it's probably not specific to this change.

@rbsheth rbsheth merged commit 68a59f8 into cpp-pm:master Nov 13, 2019
@rbsheth rbsheth deleted the pr.jpeg branch November 13, 2019 22:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants