Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add IntraSad asm code. #779

Merged
merged 2 commits into from
May 4, 2014
Merged

Add IntraSad asm code. #779

merged 2 commits into from
May 4, 2014

Conversation

zhilwang
Copy link
Contributor

@zhilwang zhilwang commented May 4, 2014

Enable intraSad ASM code

Refine format

Add X86_ASM pretect for intraSad ASM code UT

remove duplicated code.
volvet added a commit that referenced this pull request May 4, 2014
@volvet volvet merged commit e4a9c7f into cisco:master May 4, 2014
cMemoryAlign.WelsFree(pDst,"pDst");
}

TEST(IntraSadSatdFuncTest, WelsSampleSatdThree4x4_sse2){
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This test is crashing on my Windows builder on a g++ release run. Under the debugger on a debug build with asm turned on I get this:

[----------] 4 tests from IntraSadSatdFuncTest
[ RUN ] IntraSadSatdFuncTest.WelsIntra16x16Combined3Sad_ssse3
[ OK ] IntraSadSatdFuncTest.WelsIntra16x16Combined3Sad_ssse3 (0 ms)
[ RUN ] IntraSadSatdFuncTest.WelsIntra16x16Combined3Satd_sse41
[ OK ] IntraSadSatdFuncTest.WelsIntra16x16Combined3Satd_sse41 (0 ms)
[ RUN ] IntraSadSatdFuncTest.WelsSampleSatdThree4x4_sse2

Program received signal SIGSEGV, Segmentation fault.
0x00000000 in ?? ()
(gdb) bt
#0 0x00000000 in ?? ()
#1 0x004e3c55 in WelsSVCEnc::WelsI4x4LumaPredDc_c (
pPred=0x28fba0 "\027\002",
pRef=0xdcb290 "\177#»\231\201ò\022╪\032A\033IbWO\020<\032L.Ü,z\003╪Oî]s÷\21
îIawuºUo$s__óNvD:▌+4\177Ü·?ObZöÅ**U1tß¼÷C\025o#22\235IìAop)-\210s01r\f\231½2X\ ,¥÷\201QÇ#SO-j\005rvC cUO\210\021\b_U[ªµ[\nJ\017èOUá0", kiStride=32) at codec/encoder/core/src/get_intra_predictor.cpp:128 #2 0x004e8e49 in WelsSVCEnc::WelsSampleSatdIntra4x4Combined3_c ( pDec=0xdcb290 "\177#»\231\201ò\022╪\032A\033IbWO\020<\032L.Ü,z\003╪Oî]s÷\21 îIawuºUo$s**óNvD:▌+4\177Ü·?ObZöÅ__U1tß¼÷C\025o#22\235IìAop)-\210s01r\f\231½2X
,¥÷\201QÇ#SO-j\005rvC cUO\210\021\b_U[ªµ[\nJ\017èOUá0", iDecStride=32,
pEnc=0xdcb640 "o\037_\nCjq\030[s'\020n°E\017÷E"@A"Zo)\aëö%U{\030.\034\262\0
2ùÜ]\215T-╪z\217\061\231"\021ÇÆ--\001▌+íY!O\016\037\217ƒK¶\035 ß",
iEncStride=32,
pDst=0xdcba70 ")\025\033O±_ó☼%¡ïp\037-¢-/°A,D\031MÉ|Yrn<'°%\002\064,\017Oa
31ê\v\026>Lê°kB\023PyO\033ÉY¬IO\003=z", pBestMode=0x28fc44, iLambda2=50,
iLambda1=200, iLambda0=200) at codec/encoder/core/src/sample.cpp:147
#3 0x0049e9ea in IntraSadSatdFuncTest_WelsSampleSatdThree4x4_sse2_Test::TestBo
y (this=0xdc9ff0) at test/encoder/EncUT_Sample.cpp:96
#4 0x0057ece5 in testing::internal::HandleSehExceptionsInMethodIfSupported<tes
ing::Test, void> (object=0xdc9ff0,
method=&virtual testing::Test::TestBody(),
location=0x5ae3a7 testing::internal::kStackTraceMarker+1562 "the test bod
") at gtest/src/gtest.cc:2078
#5 0x0057e8db in testing::internal::HandleExceptionsInMethodIfSupported<testin
::Test, void> (object=0xdc9ff0, method=&virtual testing::Test::TestBody(),
location=0x5ae3a7 testing::internal::kStackTraceMarker+1562 "the test bod
") at gtest/src/gtest.cc:2114
#6 0x004ae0ac in testing::Test::Run (this=0xdc9ff0)
at gtest/src/gtest.cc:2151
#7 0x004ae7af in testing::TestInfo::Run (this=0xf13b08)
at gtest/src/gtest.cc:2326
#8 0x004aed90 in testing::TestCase::Run (this=0xf13868)
at gtest/src/gtest.cc:2444
#9 0x004b423b in testing::internal::UnitTestImpl::RunAllTests (this=0xf12cd8)
at gtest/src/gtest.cc:4315
#10 0x0057ec6d in testing::internal::HandleSehExceptionsInMethodIfSupported<tes
ing::internal::UnitTestImpl, bool> (object=0xf12cd8,
method=(bool (testing::internal::UnitTestImpl::)(testing::internal::UnitTe
tImpl * const)) 0x4b3fce testing::internal::UnitTestImpl::RunAllTests(),
location=0x5aeac4 <testing::internal::OsStackTraceGetter::kElidedFramesMark
r+40> "auxiliary test code (environments or event listeners)")
at gtest/src/gtest.cc:2078
#11 0x0057e5b3 in testing::internal::HandleExceptionsInMethodIfSupported<testin
::internal::UnitTestImpl, bool> (object=0xf12cd8,
method=(bool (testing::internal::UnitTestImpl::
)(testing::internal::UnitTe
tImpl * const)) 0x4b3fce testing::internal::UnitTestImpl::RunAllTests(),
location=0x5aeac4 <testing::internal::OsStackTraceGetter::kElidedFramesMark
r+40> "auxiliary test code (environments or event listeners)")
at gtest/src/gtest.cc:2114
#12 0x004b33a8 in testing::UnitTest::Run (
this=0x670c64 testing::UnitTest::GetInstance()::instance)
at gtest/src/gtest.cc:3929
#13 0x00536912 in RUN_ALL_TESTS () at gtest/include/gtest/gtest.h:2288
#14 0x004a8749 in main (argc=1, argv=0xf12ae0) at test/api/simple_test.cpp:6
(gdb)

@zhilwang
Copy link
Contributor Author

zhilwang commented May 6, 2014

I have fixed the crash issue by adding function initial for welsfillingPred, the pull request is #791

huili2 added a commit to huili2/openh264 that referenced this pull request May 6, 2014
commit 7746e3f
Merge: 69fe242 853e71e
Author: zhilwang <zhilwang@cisco.com>
Date:   Tue May 6 16:52:57 2014 +0800

    Merge pull request cisco#793 from mstorsjo/fix-msvc-gtest

    Fix building gtest on MSVC 2010 and newer

commit 853e71e
Author: Martin Storsjö <martin@martin.st>
Date:   Tue May 6 11:14:41 2014 +0300

    Fix building gtest on MSVC

    The previous define change in 1e607d7 only made it work on MSVC
    2005 and 2008, but broke things even more for 2010 and newer.
    (One shouldn't override the internal details about which tuple
    implementation to use, since one implementation don't work on
    all versions.) Since we don't need or use the gtest tuple code,
    the simplest workaround used to be just to disable it altogether,
    but that was broken in r682 in gtest.

    This has been tested and works on MSVC 2005, 2008, 2010, 2012 and
    2013.

commit 69fe242
Merge: 9a74427 5ed24f2
Author: sijchen <sijchen@cisco.com>
Date:   Tue May 6 15:29:56 2014 +0800

    Merge pull request cisco#790 from huili2/astyle_all

    astyle all files

commit 9a74427
Merge: f897029 92e5489
Author: volvet <qizh@cisco.com>
Date:   Tue May 6 15:00:01 2014 +0800

    Merge pull request cisco#788 from mstorsjo/factorize-duplicated-test

    Avoid duplicating code in the MotionEstimate test

    Approved by Sijia.

commit f897029
Merge: d4145ee 82b875c
Author: huili2 <huili2@cisco.com>
Date:   Tue May 6 14:00:32 2014 +0800

    Merge pull request cisco#791 from zhilwang/intraSad

    Add func init for welsfillingPred

commit d4145ee
Merge: 0c24686 1e607d7
Author: huili2 <huili2@cisco.com>
Date:   Tue May 6 13:59:36 2014 +0800

    Merge pull request cisco#792 from zhilwang/msvc-gtest

    Fix gtest build error when OS=msvc.

commit 1e607d7
Author: zhiliang wang <zhilwang@cisco.com>
Date:   Tue May 6 13:06:37 2014 +0800

    Fix gtest build error when OS=msvc.

commit 82b875c
Author: zhiliang wang <zhilwang@cisco.com>
Date:   Tue May 6 11:16:46 2014 +0800

    Add func init on UT source code

commit 2d26587
Author: zhiliang wang <zhilwang@cisco.com>
Date:   Tue May 6 10:45:25 2014 +0800

    Add func init for welsfillingPred

commit 5ed24f2
Author: huili2 <huili2@cisco.com>
Date:   Mon May 5 19:30:21 2014 -0700

    astyle all files

commit 0c24686
Merge: 15432d4 c0f2487
Author: volvet <qizh@cisco.com>
Date:   Mon May 5 22:13:43 2014 +0800

    Merge pull request cisco#789 from mstorsjo/remove-unused-static-func

    Remove an unused static method

commit 92e5489
Author: Martin Storsjö <martin@martin.st>
Date:   Mon May 5 16:11:19 2014 +0300

    Avoid duplicating code in the MotionEstimate test

    All the tests of the line search (unoptimized and optimized)
    use the exact same copypasted structure. Instead factorize this
    into a test function which uses the provided function.

commit c0f2487
Author: Martin Storsjö <martin@martin.st>
Date:   Mon May 5 15:13:43 2014 +0300

    Remove an unused static method

    This was added in 4464071 without actually being used.

commit 15432d4
Merge: cf5edec 4464071
Author: huili2 <huili2@cisco.com>
Date:   Mon May 5 15:56:31 2014 +0800

    Merge pull request cisco#787 from sijchen/fme_merge97

    [Encoder ME] Add FME unit test

commit 4464071
Author: sijchen <sijchen@cisco.com>
Date:   Mon May 5 15:41:15 2014 +0800

    Add FME unit test

commit cf5edec
Merge: 81467fd 1711b49
Author: sijchen <sijchen@cisco.com>
Date:   Mon May 5 10:29:35 2014 +0800

    Merge pull request cisco#785 from mstorsjo/fix-me-test

    Fix occasional errors in the motion estimation tests by correcting the range limits

commit 81467fd
Merge: f797785 26624bb
Author: sijchen <sijchen@cisco.com>
Date:   Mon May 5 10:27:13 2014 +0800

    Merge pull request cisco#786 from mstorsjo/use-proper-types

    Use the proper type in function parameters instead of void pointers

commit f797785
Merge: fd446a1 f99336d
Author: zhilwang <zhilwang@cisco.com>
Date:   Mon May 5 09:26:59 2014 +0800

    Merge pull request cisco#782 from mstorsjo/fix-msvc-warning

    Don't compare a boolean to an integer

commit fd446a1
Merge: 5c5a233 b8eeda1
Author: zhilwang <zhilwang@cisco.com>
Date:   Mon May 5 08:45:48 2014 +0800

    Merge pull request cisco#783 from mstorsjo/win64-clobber

    Properly back up and restore XMM registers on win64 in WelsSampleSadFour4x4_sse2

commit 5c5a233
Merge: e4a9c7f b4fdfa6
Author: Ethan Hugg <ethanhugg@gmail.com>
Date:   Sun May 4 15:19:51 2014 -0700

    Merge pull request cisco#784 from mstorsjo/renamed-lib

    Take the new external library name in use, fix building for android

commit 26624bb
Author: Martin Storsjö <martin@martin.st>
Date:   Sun May 4 18:00:36 2014 +0300

    Use the proper type in function parameters instead of void pointers

commit 1711b49
Author: Martin Storsjö <martin@martin.st>
Date:   Sun May 4 17:48:39 2014 +0300

    Take the test of TestHorizontalSearch_SSE41 into use

    After fixing the ranges, there's no reason to exclude this test.

commit b1c13f4
Author: Martin Storsjö <martin@martin.st>
Date:   Sun May 4 17:40:28 2014 +0300

    Properly limit the range for the random target motion vectors

    A 16x16 pixel block is copied to the destination pointed out by the
    target motion vector. Since the motion vector is relative to the
    center of the buffer, the upper bound of the range is size/2-16.

    Previously we never used negative motion vectors, but there is no
    reason not to test that direction. Therefore, the possible range
    would be [-size/2,size/2-16]. Additionally pad this range with
    INTPEL_NEEDED_MARGIN.

commit 03db750
Author: Martin Storsjö <martin@martin.st>
Date:   Sun May 4 17:35:01 2014 +0300

    Limit the ME scanning range to 16 pixels from the end of the buffer

    The block size is chosen randomly; if the block size is 16,
    LineFullSearch_c will read a block with 16 pixels from kiMaxPos;
    thus kiMaxPos cannot be larger than height-16, otherwise the calls
    end up with reads out of bounds.

commit b4fdfa6
Author: Martin Storsjö <martin@martin.st>
Date:   Sun May 4 16:00:04 2014 +0300

    Use the new library name in the android sample projects

commit a0002c2
Author: Martin Storsjö <martin@martin.st>
Date:   Sun May 4 15:57:40 2014 +0300

    Use $(PROJECT_NAME) in the android .so name

commit dc57301
Author: Martin Storsjö <martin@martin.st>
Date:   Sun May 4 15:55:17 2014 +0300

    Rename the DLL definition file according to what the output DLL is named

commit 9d0647b
Author: Martin Storsjö <martin@martin.st>
Date:   Sun May 4 15:54:16 2014 +0300

    Use $(PROJECT_NAME) for naming the DLL import library as well

commit b8eeda1
Author: Martin Storsjö <martin@martin.st>
Date:   Sun May 4 15:45:51 2014 +0300

    Properly back up and restore XMM registers on win64 in WelsSampleSadFour4x4_sse2

commit f99336d
Author: Martin Storsjö <martin@martin.st>
Date:   Sun May 4 14:53:36 2014 +0300

    Don't compare a boolean to an integer

    This avoids a warning when building with MSVC.

commit e4a9c7f
Merge: 0e7ed62 fe5b8d1
Author: volvet <qizh@cisco.com>
Date:   Sun May 4 16:29:59 2014 +0800

    Merge pull request cisco#779 from zhilwang/intraSad

    Add IntraSad asm code.

commit 0e7ed62
Merge: 30687f4 9380197
Author: ruil2 <ruil2@cisco.com>
Date:   Sun May 4 15:31:13 2014 +0800

    Merge pull request cisco#780 from sijchen/md_merge25

    [Encoder MD] Add scrolling skip function pointers in MD

commit 9380197
Author: sijchen <sijchen@cisco.com>
Date:   Sun May 4 15:03:23 2014 +0800

    add scrolling skip function pointers in MD

commit fe5b8d1
Author: Licai Guo <guolicai@gmail.com>
Date:   Sun May 4 14:51:05 2014 +0800

    refine format

commit 30687f4
Merge: ba7b4ad 2ad7bb9
Author: ruil2 <ruil2@cisco.com>
Date:   Sun May 4 14:25:10 2014 +0800

    Merge pull request cisco#761 from sijchen/md_merge31

    [Encoder MD] Adjust MD under Screen Content route

commit 485b2b5
Author: Licai Guo <guolicai@gmail.com>
Date:   Wed Apr 30 15:54:49 2014 +0800

    Add IntraSad asm code.

    Enable intraSad ASM code

    Refine format

    Add X86_ASM pretect for intraSad ASM code UT

    remove duplicated code.

commit ba7b4ad
Merge: 1560eec deb01d3
Author: sijchen <sijchen@cisco.com>
Date:   Sun May 4 10:24:21 2014 +0800

    Merge pull request cisco#778 from ethanhugg/rename

    Parameterize the project name and change it to openh264

commit deb01d3
Author: Ethan Hugg <ehugg@cisco.com>
Date:   Fri May 2 08:12:40 2014 -0700

    Parameterize the project name and change it to openh264

commit 2ad7bb9
Author: sijchen <sijchen@cisco.com>
Date:   Tue Apr 29 11:10:15 2014 +0800

    adjust the intra md under scc
@ethanhugg
Copy link
Contributor

Windows builds run fine now since the merge of pull reqs 791 and 792. Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants