Commit Graph

115 Commits

Author SHA1 Message Date
Licai Guo
cb46a3cf37 Merge pull request #547 from volvet/add-build-for-scene-change-detect-for-desktop
add scene change detector for screen in builder
2014-03-20 10:57:38 +08:00
volvet
157b876775 add set method for scene change detection 2014-03-20 09:12:29 +08:00
volvet
048c23431c add screen detector in builder 2014-03-19 16:55:21 +08:00
Licai Guo
53553f351e Merge pull request #542 from volvet/add-scene-change-detector-screen
Add scene change detector screen
2014-03-19 16:28:36 +08:00
volvet
fc4cd8b597 Merge pull request #543 from zhilwang/reorgcommon-xcode
Modify xcode project to fit common reorg.
2014-03-19 15:36:21 +08:00
Licai Guo
3febdc1d2e Modify xcode project to fit common reorg. 2014-03-19 15:08:14 +08:00
volvet
0f35049bb4 remove blank space 2014-03-19 15:00:54 +08:00
volvet
84903f145e add screen change detector for desktop share 2014-03-19 14:56:45 +08:00
ruil2
3238c913cc Merge pull request #535 from volvet/add-scene-change-detector
Add scene change detector
2014-03-19 14:52:08 +08:00
Licai Guo
e39de8d404 reoranize common to inc/src/x86/arm 2014-03-18 19:41:32 -07:00
volvet
7313ecdbd0 Merge pull request #538 from mstorsjo/use-apple-builtin-define
Use __APPLE__ instead of APPLE_IOS for apple/arm specific features
2014-03-19 09:45:56 +08:00
Martin Storsjö
9586c59b9e Use __APPLE__ instead of APPLE_IOS in the arm assembly sources 2014-03-18 23:15:49 +02:00
Martin Storsjö
ed9c03408f Rename the asm subdirectories to x86
This is consistent with having the arm assembly in a subdirectory
called arm.
2014-03-18 23:09:45 +02:00
Ethan Hugg
197423f271 Merge pull request #520 from ylatuya/master
Fix compiler warnings and remove dead code
2014-03-18 13:28:02 -07:00
Andoni Morales Alastruey
ae60f1bee9 Fix compiler warnings and remove dead code
Fix several -Werror=unused-variable and -Werror=unused-but-set-variable
and removed dead code found with this warnings
2014-03-18 19:15:25 +01:00
Martin Storsjö
e1b5e038d2 Use .obj as suffix for object files on MSVC
This avoids warnings when linking about "unrecognized source file
type, object file assumed".
2014-03-18 19:41:06 +02:00
volvet
af522899bd remove black space at lineend 2014-03-18 18:00:18 +08:00
volvet
d7b7419040 add scene change detector for further extension 2014-03-18 17:54:58 +08:00
volvet
fb1958ad13 Merge pull request #519 from mstorsjo/push-xmm-registers
Backup/restore the xmm6-xmm15 SSE registers within asm functions on win64

Reviewed by zhiliang
2014-03-18 15:04:54 +08:00
volvet
e75cd2298b Merge pull request #517 from mstorsjo/simplify-x86-asm-func-macro
Fold ALIGN 16 and the function label into WELS_EXTERN
2014-03-18 09:29:17 +08:00
Martin Storsjö
4633626d69 Remove XMMREG_PROTECT
This isn't necessary any longer, when all the assembly routines
take care of restoring registers as necessary.
2014-03-17 13:47:01 +02:00
Martin Storsjö
3cf52554f7 Backup/restore the xmm6-xmm15 SSE registers within asm functions on win64
According to the Win64 ABI, these registers need to be preserved,
and compilers are allowed to rely on their content to stay
available - not only for float usage but for any usage, anywhere,
in the calling C++ code.

This adds a macro which pushes the clobbered registers onto the
stack if targeting win64 (and a matching one which restores them).
The parameter to the macro is the number of xmm registers used
(e.g. if using xmm0 - xmm7, the parameter is 8), or in other
words, the number of the highest xmm register used plus one.

This is similar to how the same issue is handled for the NEON
registers q4-q7 with the vpush instruction, except that they needed
to be preserved on all platforms, not only on one particular platform.

This allows removing the XMMREG_PROTECT_* hacks, which can
easily fail if the compiler chooses to use the callee saved
xmm registers in an unexpected spot.
2014-03-17 13:44:33 +02:00
Martin Storsjö
9293f2f947 Remove commented out rodata sections and tables in assembly files 2014-03-17 13:42:18 +02:00
Martin Storsjö
eec968234d Fold ALIGN 16 and the function label into WELS_EXTERN
This simplifies the structure for all x86 assembly functions,
reducing the amount of duplicated code structure.
2014-03-17 13:35:00 +02:00
Martin Storsjö
f96918283f Remove commented out code for old, 32-bit only x86 assembly function prologues/epilogues 2014-03-17 11:20:11 +02:00
Licai Guo
fc4e0cacec Merge pull request #483 from volvet/develop_b
use large/medium/similar to define scene change result
2014-03-17 16:32:31 +08:00
Martin Storsjö
d45e624cd4 Simplify code by using the arg11 and arg12 defines 2014-03-15 14:42:27 +02:00
Martin Storsjö
9199798f22 Fix a typo in a macro name, EXTENTION -> EXTENSION 2014-03-14 10:13:18 +02:00
Martin Storsjö
2bce50283f Fix a mismatched ifdef comment
This is an ifdef block for HAVE_NEON.
2014-03-14 10:01:18 +02:00
volvet
fc5c48830a fix the condition of scene change flag and comments 2014-03-14 09:53:24 +08:00
volvet
c8761c08ae use large/medium/similar to define scene change result 2014-03-13 10:43:20 +08:00
Martin Storsjö
c011890764 Push clobbered neon registers on the stack
According to the calling convention, the registers q4-q7 should be
preserved by functions. The caller (generated by the compiler) could
be using those registers anywhere for any intermediate data.

Functions that use more than 12 of the qX registers must push
the clobbered registers on the stack in order to be able to restore them
afterwards.

In functions that don't use all 16 registers, but clobber some of
the callee saved registers q4-q7, one or more of them are remapped
to reduce the number of registers that have to be saved/restored.

This incurs a very small (around 0.5%) slowdown in the decoder and
encoder.
2014-03-10 22:07:36 +02:00
Martin Storsjö
811c647c0e Remap registers to avoid clobbering the neon registers q4-q7
According to the calling convention, the registers q4-q7 should be
preserved by functions. The caller (generated by the compiler) could
be using those registers anywhere for any intermediate data.

Functions that use 12 or less of the qX registers can avoid
violating the calling convention by simply using other registers instead
of the callee saved registers q4-q7.

This change only remaps the registers used within functions - therefore
this does not affect performance at all. E.g. in functions using
registers q0-q7, we now use q0-q3 and q8-q11 instead.
2014-03-10 22:07:25 +02:00
Ethan Hugg
3627875986 Merge pull request #456 from mstorsjo/use-common-threadlib
Make the processing lib use mutexes from WelsThreadLib from the common library
2014-03-10 09:45:51 -07:00
ruil2
e99df3377d Merge pull request #460 from mstorsjo/add-const
Mark pointers as const where possible in vaacalc
2014-03-10 15:35:57 +08:00
Martin Storsjö
e31ba7a775 Fix a typo, "heigth" -> "height" 2014-03-09 19:19:37 +02:00
Martin Storsjö
2a23a508e1 Mark pointers as const where possible in vaacalc 2014-03-09 18:52:17 +02:00
Martin Storsjö
c5390521ec Make the processing lib use mutexes from WelsThreadLib from the common library
This requires always building the WelsMutex* functions,
even if MT_ENABLED isn't set.
2014-03-08 12:46:25 +02:00
Martin Storsjö
c87bb2b449 Remove unused/undeclared arm assembly macro parameters
The SAD_VAR_16_END macro only takes 3 parameters, never 4,
and SAD_SSD_16_END never is called with more than 3 parameters
either.
2014-03-07 10:26:54 +02:00
Martin Storsjö
c0043f7053 Use the three-operand form of add/sub with shift
When using unified syntax, the two operand form with a shift
isn't allowed.
2014-03-06 16:21:54 +02:00
Martin Storsjö
8ba79262bf Rename a function to avoid conflicts between almost duplicate neon functions
There's a different version of the same function in the encoder,
but they're not identical - the encoder version has got stricter
alignment requirements.

If someone can confirm that it is ok to use the function from the
encoder, pixel_sad_neon.S in processing could be deleted, and the
encoder version moved to codec/common instead.
2014-03-06 16:19:48 +02:00
Martin Storsjö
4e4bfcc1bc Regenerate makefiles to include the encoder arm assembly 2014-03-06 16:11:54 +02:00
Licai Guo
e7cc8c2780 Add arm asm code for processing. 2014-03-05 16:54:05 +08:00
Licai Guo
efcee63692 Remove .DS_Store file. 2014-03-05 10:24:05 +08:00
Licai Guo
bb244d736b Partly add arm asm code to encoder. 2014-03-05 10:24:05 +08:00
Martin Storsjö
9cf34e7615 Unify the interface for the different variants of WelsCPUFeatureDetect
The caller of the function should not need to know exactly which
implementation of it is being used.

For the variants that don't support detecting the number of cores,
the pNumberOfLogicProcessors parameter can be left untouched
and the caller will use a higher level API for finding it out.

This simplifies all the calling code, and simplifies adding
more implementations of cpu feature detection.
2014-03-04 10:18:30 +02:00
Martin Storsjö
3ccd2ae4cf Remove a redundant makefile ifdef
ASM_ARCH=x86 is only set if USE_ASM is enabled.
2014-03-01 23:56:14 +02:00
Martin Storsjö
7d2c761604 Allow using the USE_ASM makefile variable for architectures other than x86
Add an ASM_ARCH variable which specifies which kind of assembly
is supposed to be built.
2014-02-28 10:19:53 +02:00
volvet
73ce4adc85 add encode test for iOS 2014-02-26 14:53:31 +08:00
Licai Guo
fc056c7ef0 Refine structure of iOS project to fix the issue. 2014-02-25 13:46:18 +08:00