On 11.09.2015 09:49 PM, Benjamin Gilbert wrote:
> On Fri, Sep 11, 2015 at 3:13 PM, Mihai Moldovan <[email protected]
> <mailto:[email protected]>> wrote:
> 
>     [05:41:47] < irker342> [email protected] 
> <mailto:[email protected]> *
>     https://trac.macports.org/changeset/140185
>     /trunk/dports/sysutils/tarsnap/Portfile:
>     [05:41:48] < irker342> tarsnap: Update to 1.0.36.1
>     [05:41:48] < irker342> SSE2 is now autodetected.
> 
>     Careful, this could be a problem. Depending on what the compiler does and 
> the
>     system CPU, this may lead to unreproduceable builds, especially when using
>     archives vs. source builds.
> 
> 
> Yeah, that commit message was probably more confusing than helpful.  I meant 
> to
> say that SSE2 support is now detected at runtime; the --enable-sse2 configure
> option no longer exists.  I've clarified the commit message.

You misinterpreted what I actually meant. The commit message is (kind of) fine,
but irrespectively the new behavior is dangerous.

Especially when it comes to autodetected CPU flags, software that autoconfigures
is building potentially unreproducibly.

Imagine the following situation: port is built as a binary archive on the
buildslave, which has AVX support. A user installs this binary archive on his
machine, that has a CPU not supporting AVX. Inevitably this program will crash.

AVX is quite new and potentially unsupported even by CPUs built into machines
that are capable to run 10.10. My CPU for instance does not support AVX.

Hence CPU autodetection should be either a variant and disabled by default, or,
if enabled by default, archive_sites be cleared so that no binary archives are
created.


In this special case, SSE2 might be safe to be autodetected unconditionally,
because it will either always be enabled on x86 and x86_64, or disabled on ppc
and ppc64.



Mihai

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
macports-dev mailing list
[email protected]
https://lists.macosforge.org/mailman/listinfo/macports-dev

Reply via email to