Commit Graph

18321 Commits

Author SHA1 Message Date
Linfeng Zhang
cd83802885 Shrink size of mode_map in struct TileDataEnc
To reduce the memcpy() cycles in vp9_rd_pick_inter_mode_sb().
The maximum value of mode_map is (MAX_MODES - 1) = 29.

Change-Id: I5704bd66838ea0b075f0afb001f5cbebfd3f1602
2018-03-28 12:50:31 -07:00
Linfeng Zhang
39de45d3cc Update sad4d x86 functions
Speed change is marginal.

Change-Id: I4d548e9763ce43bd546f19132202f7a8509a32bf
2018-03-28 12:49:12 -07:00
Linfeng Zhang
debd86ec82 Merge "Add speed test in SADx4Test" 2018-03-28 19:39:37 +00:00
Linfeng Zhang
8edd5051aa Add speed test in SADx4Test
Change-Id: I42dd3df8c13c0a6d08ce28e27e8917b5d831fc1a
2018-03-28 11:13:28 -07:00
Marco Paniconi
872e34ae8d vp9-svc: Add check in datarate unittests for frame-dropping.
Add verfication for constrained svc framedrop mode: check that
if a given spatial is dropped, all uppper layers must be dropped.

Change-Id: I9b4821b23c95d1d9d0c031a41af19984647ec5dc
2018-03-28 10:30:59 -07:00
Marco Paniconi
7b9984b386 vp9-svc: Add logic to enable for constrained framedrop.
Add the logic for the constrained framdrop mode for SVC.

Add test case in datarate unittests.
Also lower target bitrates in the tests to better test
frame dropper.

Change-Id: I8ee1b8cb56d835c233ad1fbe0fc1456cb2e7291f
2018-03-27 15:02:12 -07:00
Johann Koenig
239511fad8 Merge "third_part/googletest: update to release-1.8.0-742-g7857975" 2018-03-27 01:08:12 +00:00
Marco Paniconi
223f9e3671 vp9-svc: Allow for setting frame drop thresholds per layer.
Add encoder control to set the frame drop thresholds per
spatial layer, and add a frame drop mode: 0 = per-layer drop,
and 1 = constrained drop mode (a drop on a given layer forces
drops to all upper layers).

Default is mode 0 (per-layer dropping).
Implementation for mode 1 will come in subsequent change.

If the control is not used, then the spatial layer frame
drop thresholds (water mark) are all equal and set to the value
given by the encoder config (oxcf->drop_frames_water_mark).

Bump up the ABI version.

Change-Id: Id038d4181b86fa98b3d44d026f96d5f344d81629
2018-03-26 13:56:55 -07:00
Johann
aa5e9c6a7c third_part/googletest: update to release-1.8.0-742-g7857975
Address std::tr1::tuple warnings:
https://github.com/google/googletest/issues/1111

The unsigned overflow fix has been superseded by:
https://github.com/google/googletest/pull/1180

Change-Id: I92dc0ba08a4d0d63f5e5b2da7b64f4a4642ed9ab
2018-03-26 11:29:11 -07:00
Johann
9037a05041 msvs build: only fix_file_list when it is broken
Clears a warning when generating VS project files with older versions of
bash:
declare: -n: invalid option

Change-Id: Id0c0bc17dc5a1599f7d2d73e3cc9259a45540f3f
2018-03-26 09:39:24 -07:00
Paul Wilkins
2b800d9394 Merge "Adjustment to initial q range estimate and kf boost." 2018-03-24 11:27:12 +00:00
Martin Storsjö
f4b1eca53e Merge "Restore emms usage on x86_64 after 726b021a12c1b" 2018-03-23 22:04:43 +00:00
Martin Storsjo
a6fdfda44c Restore emms usage on x86_64 after 726b021a12
Even on x86_64, emms has to be called if the x87 state has
been clobbered - the calling code (either within libvpx or
in a caller outside of libvpx) may be using the x87 instructions,
even though use of them isn't all that common on x86_64.

This fixes builds with clang for mingw/x86_64.

Change-Id: I1f6072835590b862bad156f17331ba65c813ddd9
2018-03-23 19:57:46 +00:00
Martin Storsjö
343ef23db0 Merge "thumb: Remove a brittle, ugly and unused arm->thumb conversion" 2018-03-23 19:54:01 +00:00
Martin Storsjö
9c9de8a8ce Merge changes from topic "llvm-mingw"
* changes:
  configure: Add an arm64-win64-gcc target
  test: Check for ARCH_X86_64 in addition to _WIN64
  configure: Add an armv7-win32-gcc target
  ads2gas: Add a -noelf option
2018-03-23 19:49:40 +00:00
Johann Koenig
99e1784525 Revert "remove fldcw/fstcw from Win64 builds"
This reverts commit 60a3cb9ad8.

Reason for revert: x87 instruction usage might not be as
clear cut as I would like. At the very least, llvm mingw
builds appear to having issues with emms.

Original change's description:
> remove fldcw/fstcw from Win64 builds
>
> _MCW_PC (Precision control) is not supported on x64:
> https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/control87-controlfp-control87-2
>
> The x87 FPU is not used on Win64 or ARM so setting the x87 control word
> is not necessary. The SSE/SSE2 and ARM FPUs don't have a precision
> control - the precision is embedded in each instruction - so the need to
> set the control word is also gone.

BUG=webm:1500

Change-Id: I25bcfa96bc9c860f6c7e03315d75fa6fd1d88ec5
2018-03-23 11:09:15 -07:00
Johann Koenig
1000e07609 Merge "remove fldcw/fstcw from Win64 builds" 2018-03-23 13:23:58 +00:00
Johann
60a3cb9ad8 remove fldcw/fstcw from Win64 builds
_MCW_PC (Precision control) is not supported on x64:
https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/control87-controlfp-control87-2

The x87 FPU is not used on Win64 or ARM so setting the x87 control word
is not necessary. The SSE/SSE2 and ARM FPUs don't have a precision
control - the precision is embedded in each instruction - so the need to
set the control word is also gone.

BUG=webm:1500

Change-Id: I014513282a7dc320d1cdeaec48249d98a66bf09f
2018-03-23 06:22:39 -07:00
Martin Storsjo
8af243cfba configure: Add an arm64-win64-gcc target
This configuration doesn't require any extra custom settings, since
it only uses neon intrinsics that are handled automatically by the
compiler (no external assembly).

Change-Id: I35415c68f483a430c0672e060a7bbd09a3469512
2018-03-23 13:42:01 +02:00
Martin Storsjo
e9ea629b13 test: Check for ARCH_X86_64 in addition to _WIN64
_WIN64 is also defined when targeting windows on aarch64.

Change-Id: I42b84e14079c19d0ba9362a06d8c6e7287644373
2018-03-23 13:41:35 +02:00
Martin Storsjo
b08a0b07d4 configure: Add an armv7-win32-gcc target
This builds for windows on arm, with llvm-mingw. The target triplet
is named -gcc since that's how similar existing targets are named,
even though it technically runs clang (via frontends named
"$CROSS-gcc").

Assemble using $CC -c since there's no standalone assembler
available (except perhaps llvm-mc).

Change-Id: I2c9a319730afef73f811bad79f488dcdc244ab0d
2018-03-23 13:25:35 +02:00
Martin Storsjo
2cc5c8f97c ads2gas: Add a -noelf option
This allows skipping elf specific features from the output.

Change-Id: I739299ba41286ca10415e056b4ffd561be5e0350
2018-03-23 13:23:16 +02:00
Martin Storsjo
3abdb1ca65 thumb: Remove a brittle, ugly and unused arm->thumb conversion
The relevant code that this conversion handled was removed in
c26a9ecaa2.

Change-Id: Iee40f95134e609c291c7c4e06bc50dcb895bc5e3
2018-03-23 13:16:57 +02:00
James Zern
c13aaf7a3e Merge changes Ied91c7ef,If2dcc6e2,Ib7397e71,Ib6392c79
* changes:
  Fix implicit-fallthrough warnings
  Fix dangling-else warnings
  Fix a strict-overflow warning
  Rename several static NEON iht functions
2018-03-23 03:56:50 +00:00
Jerome Jiang
4bff5bca92 Merge "vp9 svc frame drop: enable adaptive rd for row mt." 2018-03-23 01:41:21 +00:00
Jerome Jiang
1ae97b4a4d vp9 svc frame drop: enable adaptive rd for row mt.
adaptive_rd_threshold_mt is set to 1 when speed >= 7 for SVC.
QVGA in SVC uses speed 5 which set adaptive_rd_threshold_mt to 0.
If VGA or HD is dropped for the last super frame, the flag is still 0
when the encoder is destroyed. Thus memory won't be released.

Change the bitrate threshold in datarate test.

Change-Id: I55352cc0b030568d38eb735d99c2fa29058d3690
2018-03-22 17:11:05 -07:00
Linfeng Zhang
920f4ab8f8 Fix implicit-fallthrough warnings
Compiler -- gcc (Debian 7.3.0-5) 7.3.0

Change-Id: Ied91c7ef3d25c3ef44a1f667656176e2709b4f44
2018-03-22 11:44:05 -07:00
Linfeng Zhang
c101a5f5c4 Fix dangling-else warnings
Compiler -- gcc (Debian 7.3.0-5) 7.3.0

Change-Id: If2dcc6e215a2990cde575f0e744ce0c7a44a15f1
2018-03-22 11:44:01 -07:00
Linfeng Zhang
5192ce92b8 Fix a strict-overflow warning
Compiler -- gcc (Debian 7.3.0-5) 7.3.0

./libvpx/vp9/encoder/vp9_denoiser.c:374:9: assuming signed overflow
does not occur when assuming that (X + c) < X is always false
[-Wstrict-overflow]
         for (j = 0; j < xmis; j++) {

Change-Id: Ib7397e718ff717bdabc088fc4c6e1771381fb522
2018-03-22 11:42:25 -07:00
Linfeng Zhang
a09acf7e19 Rename several static NEON iht functions
Change-Id: Ib6392c79d0269a43dbe180a89f2571482d98844d
2018-03-22 11:13:12 -07:00
Marco Paniconi
3cb9c5ffe9 vp9-svc: Fix to sample encoder
Get the correct computation of number of input
layers to account for frame drops.

Change-Id: I39637381e1981b53c930da67a5c525191de6907d
2018-03-21 16:47:59 -07:00
James Zern
62c4747532 Merge "vp9_highbd_iht8x8_add_neon: rm unused functions" 2018-03-21 17:52:47 +00:00
Jerome Jiang
1f82e06122 VP9 SVC: Add control to disable inter layer prediction.
Add VP9E_SET_SVC_INTER_LAYER_PRED to disable inter layer (spatial)
prediction.
0: prediction on
1: prediction off for all frames
2: prediction off for non key frames

Bump up ABI version.

Change-Id: I5ab2a96b47e6bef202290fe726bed5f99bd4951f
2018-03-20 19:28:12 -07:00
Marco Paniconi
4a20caef78 Merge "vp9-svc: Improve frame dropper for spatial layers." 2018-03-20 21:46:36 +00:00
Marco Paniconi
126a3718fc vp9-svc: Improve frame dropper for spatial layers.
SVC frame dropper: modify the logic to allow for individual
spatial layers to drop. This removes the constraint that all
upper spatial layers must drop when a given spatial layer drops.

Add a flag to the pkt to indicate whether a spatial layer is
encoded or dropped. This is needed for applications that enable
this feature (frame dropping for SVC).

For a current spatial layer, if its previous spatial layer is
dropped, then disable certain features for that layer:
inter-layer prediction, base_mv, partition_reuse, copy partition.

Also add the constraint to never drop a spatial layer if its
base layer is a key frame.

Updates to sample encoder (vp9_spatial_svc_encoder) and the
SVC datarate unittests to properly handle frame dropping.

Bump up ABI version.
Change-Id: I7d14ccf67b8d014a7abfce5ba3989fc623e94067
2018-03-20 10:34:45 -07:00
Johann
7a9a46fb53 visual studio: add yasm instructions
Change-Id: Ied2a1fc0e1d1a2245d63f267669add8889dd0cec
2018-03-20 10:08:45 -07:00
Johann Koenig
8b263798d0 Merge "x86 android: default on realtime-only" 2018-03-20 17:06:18 +00:00
Johann Koenig
c5630b9e6c Merge "build: remove stale .git files" 2018-03-20 17:06:05 +00:00
Johann Koenig
52da0428be Merge "reland "use intrinsics for 'emms'"" 2018-03-20 17:05:17 +00:00
Johann
907e966adf build: remove stale .git files
These were used for an older style of Visual Studio configurations.

Change-Id: I51f07b30ad51c4da0c5caf1ede36cdb69b2d2b19
2018-03-19 17:36:38 -07:00
Johann
726b021a12 reland "use intrinsics for 'emms'"
Only target 32bit builds. Visual Studio does not define _mm_empty for
64bit configurations.

Rename emms.asm and remove from 32 bit builds to avoid empty file
warnings.

Don't check register state on 64bit builds.

BUG=webm:1500

This reverts commit 60beb781c1.

Change-Id: I5ac4cf6c67249ff24f7da19792144de20527bfce
2018-03-19 17:11:55 -07:00
Jerome Jiang
4038632fab Merge "VP8: Fix out of range index for mvcost." 2018-03-19 19:00:55 +00:00
James Zern
0dad4e2997 vp9_highbd_iht8x8_add_neon: rm unused functions
their use was removed in:
d8424d289 Fix a bug in vp9_highbd_iht8x8_64_add_neon

Change-Id: I041800f3fb34ffbb7cfa7401370c5a5ceeab01c6
2018-03-18 18:24:41 -07:00
James Zern
0f9521f0a8 CopyFrameTest: reduce max size for 32-bit targets
avoids potential OOM when allocating 3 buffers for 16383x16383; 3840 is
used as a replacement
this test was missed in:
215bddf32 vpx_scale_test: reduce max size for 32-bit targets

Change-Id: I515adf5999c6ef1724394ccd62d677134bd35e6d
2018-03-18 15:15:07 -07:00
Jerome Jiang
ca28740570 VP8: Fix out of range index for mvcost.
Clamp index between 0 and MVvals.

Bit exact for speed -8, -6 and -4 on RTC set.

BUG=b/72510002

Change-Id: I61bdb02a0924e157b3c1980f74fbbfe5ce51bc44
2018-03-17 04:04:10 +00:00
James Zern
215bddf324 vpx_scale_test: reduce max size for 32-bit targets
avoids potential OOM when allocating 3 buffers for 16383x16383; 3840 is
used as a replacement

Change-Id: I92116ab69b10db6820fc651d3626bd9699700208
2018-03-16 17:47:56 -07:00
paulwilkins
da7a7089c6 Adjustment to initial q range estimate and kf boost.
Adjustment to initial active based on image size.
Add extra breakout case for kf boost loop.
Small adjustment to q delta calculation for key frames.

Net % improvements for all standard tests sets (-ve values) measured
using c-bvr mode.

(Overall PSNR, SSIM, PSNR-HVS)
Low Res:  -0.223	-0.229	-0.107
Mid Res:  -0.175	0.008	-0.180
High Res: -0.131	0.106	-0.206
NFlix 2K:   -0.390	-0.271	-0.489
NFlix 4K:   -1.370	-0.825	-1.590

Change-Id: I06a39de43594e1a99bb0cb281af15cdb8058a8ed
2018-03-16 12:24:54 +00:00
Marco Paniconi
2640f25072 vp9-svc: Frame dropper for SVC.
If a given spatial layer decides to drop, due to the
buffer/overshoot conditions for that layer, then drop
that current spatial layer and all spatial layers above.

In the current implementation the svc frame counter
(and hence the pattern for the non-flexible SVC case)
are updated on frame drops.

Also add last spatial layer encoded to the pkt.
This is useful for RTC applications that enable
frame dropping for SVC.

Update to the SVC datarate tests:
enabled frame dropper on all SVC datarate tests, and
made a fix to properly set the temporal_layer_id, which
works now even on frame drops.

Change-Id: If828c193f3cb6b1839803fd52fe9fbbda5b5a039
2018-03-15 21:04:59 -07:00
James Zern
d07a5bfbf8 Merge "libs.mk,vcxproj generation: split srcs in invocation" 2018-03-16 03:52:02 +00:00
James Zern
b986ba84b3 Merge "Revert "vp9_loopfilter.c: zero lfl_uv"" 2018-03-16 02:11:52 +00:00