Now that OpenMP is part of BASE, it could be enabled by default so packages will use it automatically. If gives a huge performance boost.
(In reply to devries.arno from comment #0) Is it available on all arches?
(In reply to Mikael Urankar from comment #1) I didn't think of that. I am not sure if aarch64 is supported in OpenMP. It was not supported in the deprecated OpenMP port, but it IS supported in LLVM. Can't find anything about the current state in FreeBSD. But either way, isn't it possible to make the Configuration Options architecture aware? I am not that familiar with the ports build system. If this is a problem I will have to continue using the port.But that would be a pity because it really makes a lot of difference, not only for ImageMagick.
(In reply to devries.arno from comment #2) Yes: bsd.options.mk:# OPTIONS_DEFINE_${ARCH} - List of options this ports accept and are bsd.options.mk:# OPTIONS_DEFAULT_${ARCH} - List of options activated by default for a bsd.options.mk:# OPTIONS_EXCLUDE_${ARCH} - List of options unsupported on a given ${ARCH}
I've looked at a few independent sources and all shows the same conclusion that OpenMP and threads scales badly / makes things worse. The issue appears to be that each job is usually too small to utilize many cores and/or algorithms doesn't scale well on modern systems so more time is spent on dispatching the workload rather than processing it so utilizing OpenMP uses more CPU time than it being disabled. Please re-open and provide benchmarks if this is an incorrect conclusion.