[Bug 229788] march=ivybridge breaks certain ports

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Wed Jul 25 19:41:24 UTC 2018


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=229788

--- Comment #6 from Dimitry Andric <dim at FreeBSD.org> ---
Created attachment 195456
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=195456&action=edit
Avoid undefined behavior in cuTreeFix8Pack

As noted in the upstream x265 bug report, it turns out cuTreeFix8Pack() has
undefined behavior when it attempts to fit negative double values into
uint16_t.  There needs to be an intermediate cast to int16_t to avoid this, and
I verified that the input values are never outside the range
[INT16_MIN..INT16_MAX].

In addition I added a part to the port Makefile which sets the port LLD_UNSAFE
on i386.  (I have had this patch in my tree for a while, might as well get it
applied now...)

Note that independently of this patch, or adding -mno-avx, for me TestBench
still crashes with a segfault at the end, but that is apparently unrelated to
this particular bug:

Using random seed 5B58D03E 8bit
Testing primitives: SSE2
Testing primitives: SSE3
Testing primitives: SSSE3
Testing primitives: SSE4
Testing primitives: AVX
Testing primitives: AVX2
Testing primitives: BMI2
Testing primitives: ARMv6
Testing primitives: NEON
Testing primitives: FastNeonMRC

Test performance improvement with full optimizations
== pixel primitives ==
           satd[  4x4]  3.65x    147.78          538.83
         avg_pp[  4x4]  1.25x    244.77          305.50
[... much more of these stats ... ]
pelFilterLumaStrong_Vertical    1.49x    723.31          1075.46
*** Signal 11

Stop.
make: stopped in /share/dim/ports/multimedia/x265

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-toolchain mailing list