cast_unittests cannot run on official builds because of FAKE codecs |
||||||||||
Issue descriptionVersion: tip OS: Linux What steps will reproduce the problem? (1) Build cast_unittests in the official mode: $ gn gen out/gn-off '--args=is_chrome_branded=true is_official_build=true is_debug=false' --check $ ninja -C out/gn-off cast_unittests (2) Run cast_unittests: $ ./out/gn-off/cast_unittests This will fail in multiple test cases: In particular, it fails on End2EndTest.BasicFakeSoftwareVideo. I've taken a closer look by running it under gdb: $ gdb --args ./out/gn-off/cast_unittests --gtest_filter=End2EndTest.BasicFakeSoftwareVideo ... (gdb) b end2end_unittest.cc:99 Breakpoint 1 at 0x4d8cbb: end2end_unittest.cc:99. (2 locations) ... (gdb) b video_sender.cc:128 Breakpoint 2 at 0x506a9c: file ../../media/cast/sender/video_sender.cc, line 128. ... Breakpoint 2, media::cast::VideoSender::VideoSender(scoped_refptr<media::cast::CastEnvironment>, media::cast::VideoSenderConfig const&, base::Callback<void (media::cast::OperationalStatus), (base::internal::Cop yMode)1> const&, base::Callback<void (base::Callback<void (scoped_refptr<base::SingleThreadTaskRunner>, std::unique_ptr<media::VideoEncodeAccelerator, std::default_delete<media::VideoEncodeAccelerator> >), (bas e::internal::CopyMode)1> const&), (base::internal::CopyMode)1> const&, base::Callback<void (unsigned long, base::Callback<void (std::unique_ptr<base::SharedMemory, std::default_delete<base::SharedMemory> >), (b ase::internal::CopyMode)1> const&), (base::internal::CopyMode)1> const&, media::cast::CastTransport*, base::Callback<void (base::TimeDelta), (base::internal::CopyMode)1> const&) (this=0x146c0714f200, cast_envir onment=..., video_config=..., status_change_cb=..., create_vea_cb=..., create_video_encode_mem_cb=..., transport_sender=<optimized out>, playout_delay_change_cb=...) at ../../media/cast/sender/video_sender.cc:1 29 129 cast_environment_->PostTask( (gdb) p video_encoder_ $3 = std::unique_ptr<media::cast::VideoEncoder> containing 0x0 (gdb) p video_config.codec $4 = media::cast::CODEC_VIDEO_FAKE The culprit seems to be in VideoEncoderImpl::IsSupported: https://code.google.com/p/chromium/codesearch#chromium/src/media/cast/sender/video_encoder_impl.cc&l=54&cl=GROK&gsn=Create&rcl=1463483832 bool VideoEncoderImpl::IsSupported(const VideoSenderConfig& video_config) { #ifndef OFFICIAL_BUILD if (video_config.codec == CODEC_VIDEO_FAKE) return true; #endif return video_config.codec == CODEC_VIDEO_VP8; } Please, take a look. It seems reasonable to have cast_unittests green in the official mode.
,
May 17 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/f7e3c42cc1d32437f3a9e7d0c9f5adecf92b43a5 commit f7e3c42cc1d32437f3a9e7d0c9f5adecf92b43a5 Author: krasin <krasin@google.com> Date: Tue May 17 20:06:59 2016 Disable broken tests on 'LTO Linux' buildbot. These breakages are not related to LTO, and only happen in the official mode. All of them are reported, and the tests will be reenabled after they are fixed. BUG= 612473 ,612496, 612503 , 612507 Review-Url: https://codereview.chromium.org/1985123002 Cr-Commit-Position: refs/heads/master@{#394201} [modify] https://crrev.com/f7e3c42cc1d32437f3a9e7d0c9f5adecf92b43a5/testing/buildbot/chromium.fyi.json
,
Jun 7 2016
This is to confirm that the issue still happening:
media::cast::LocalVideoFrameInput::InsertRawVideoFrame (this=0x0, video_frame=..., capture_time=...) at ../../media/cast/cast_sender_impl.cc:32
32 cast_environment_->PostTask(CastEnvironment::MAIN,
(gdb) bt
#0 media::cast::LocalVideoFrameInput::InsertRawVideoFrame (this=0x0, video_frame=..., capture_time=...) at ../../media/cast/cast_sender_impl.cc:32
#1 0x00000000004ba48c in media::cast::End2EndTest::SendVideoFrame (this=0x1342ffe62680, frame_number=0, reference_time=...) at ../../media/cast/test/end2end_unittest.cc:591
#2 0x00000000004b7c1e in media::cast::End2EndTest::RunAudioVideoLoop (this=<optimized out>, duration=...) at ../../media/cast/test/end2end_unittest.cc:625
#3 0x00000000004b744c in media::cast::End2EndTest_LoopWithLosslessEncoding_Test::TestBody (this=0x1342ffe62680) at ../../media/cast/test/end2end_unittest.cc:969
#4 0x00000000005c2034 in HandleExceptionsInMethodIfSupported<testing::Test, void> (object=0x1342ffe62680, method=<error reading variable: DWARF-2 expression error: `DW_OP_stack_value' operations must be used either alone or in conjunction with DW_OP_piece or DW_OP_bit_piece.>, location=<optimized out>) at ../../testing/gtest/src/gtest.cc:2458
#5 testing::Test::Run (this=0x1342ffe62680) at ../../testing/gtest/src/gtest.cc:2474
#6 0x00000000005c3238 in testing::TestInfo::Run (this=0x1342ffe640c0) at ../../testing/gtest/src/gtest.cc:2656
#7 0x00000000005c3553 in testing::TestCase::Run (this=<optimized out>) at ../../testing/gtest/src/gtest.cc:2774
#8 0x00000000005c8009 in testing::internal::UnitTestImpl::RunAllTests (this=<optimized out>) at ../../testing/gtest/src/gtest.cc:4647
#9 0x00000000005c7cba in HandleExceptionsInMethodIfSupported<testing::internal::UnitTestImpl, bool> (method=<error reading variable: access outside bounds of object referenced via synthetic pointer>, object=<optimized out>, location=<optimized out>) at ../../testing/gtest/src/gtest.cc:2458
#10 testing::UnitTest::Run (this=<optimized out>) at ../../testing/gtest/src/gtest.cc:4255
#11 0x000000000059dd27 in RUN_ALL_TESTS () at ../../testing/gtest/include/gtest/gtest.h:2237
#12 base::TestSuite::Run (this=0x7fffffffd4c8) at ../../base/test/test_suite.cc:230
#13 0x00000000005a93bf in Run (this=0x7fffffffd4b8) at ../../base/callback.h:397
#14 base::(anonymous namespace)::LaunchUnitTestsInternal(base::Callback<int (), (base::internal::CopyMode)1> const&, int, int, bool, base::Callback<void (), (base::internal::CopyMode)1> const&) (run_test_suite=..., default_jobs=48, default_batch_limit=10, use_job_objects=true, gtest_init=...) at ../../base/test/launcher/unit_test_launcher.cc:206
#15 0x00000000005a926b in base::LaunchUnitTests(int, char**, base::Callback<int (), (base::internal::CopyMode)1> const&) (argc=<optimized out>, argv=<optimized out>, run_test_suite=...) at ../../base/test/launcher/unit_test_launcher.cc:445
#16 0x00000000004e6d8f in main (argc=1, argv=0x7fffffffd5f8) at ../../base/test/run_all_unittests.cc:21
12 tests crashed:
End2EndTest.BasicFakeSoftwareVideo (../../media/cast/test/end2end_unittest.cc:1079)
End2EndTest.EvilNetwork (../../media/cast/test/end2end_unittest.cc:1165)
End2EndTest.LoopWithLosslessEncoding (../../media/cast/test/end2end_unittest.cc:965)
End2EndTest.OldPacketNetwork (../../media/cast/test/end2end_unittest.cc:1208)
End2EndTest.ReceiverClockFast (../../media/cast/test/end2end_unittest.cc:1114)
End2EndTest.ReceiverClockSlow (../../media/cast/test/end2end_unittest.cc:1129)
End2EndTest.ShoveHighFrameRateDownYerThroat (../../media/cast/test/end2end_unittest.cc:1187)
End2EndTest.SmoothPlayoutWithFivePercentClockRateSkew (../../media/cast/test/end2end_unittest.cc:1144)
End2EndTest.TestSetPlayoutDelay (../../media/cast/test/end2end_unittest.cc:1241)
VideoEncoderTest.CanBeDestroyedBeforeVEAIsCreated/0 (../../media/cast/sender/video_encoder_unittest.cc:282)
VideoEncoderTest.EncodesVariedFrameSizes/0 (../../media/cast/sender/video_encoder_unittest.cc:282)
VideoEncoderTest.GeneratesKeyFrameThenOnlyDeltaFrames/0 (../../media/cast/sender/video_encoder_unittest.cc:282)
Please, fix or find a better owner for the bug.
,
Jun 7 2016
(Re-prioritized based on need.) We had never anticipated the unit test binary would be built in an OFFICIAL_BUILD flavor. We'll have to re-visit our strategy here, as we really don't want to compile in the "FAKE" codec in official chrome builds: It would just be code bloat.
,
Jun 7 2016
Okay, that's a valid answer. I've tried to look up other bots, it seems that none are broken due to this issue, which means they don't run it So, while it would be good to fix, it's not P1 as I have guessed.
,
Jun 8 2017
This issue has been Available for over a year. If it's no longer important or seems unlikely to be fixed, please consider closing it out. If it is important, please re-triage the issue. Sorry for the inconvenience if the bug really should have been left as Available. If you change it back, also remove the "Hotlist-Recharge-Cold" label. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Jun 12 2017
miu, if this is expected could we just make cast_unittests's main() early-out in official builds or something?
,
Jun 19 2017
Sorry for the delay. I'll take a look this week.
,
Jan 13 2018
,
Feb 1 2018
Still an issue...
,
May 25 2018
,
May 28 2018
Let's get these tests disabled: https://chromium-review.googlesource.com/#/c/chromium/src/+/1075027
,
May 29 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/2cdcbfbbd931520d0e3eb74737276662c9379a6d commit 2cdcbfbbd931520d0e3eb74737276662c9379a6d Author: inglorion <inglorion@chromium.org> Date: Tue May 29 21:34:31 2018 Disable cast_unittests cases that fail with official_build = true Some test cases in cast_unittests fail with official_build = true, causing bots with that configuration to be red. This change disables these cases. Bug: 612496 Change-Id: I2993729b3e6d3b268d2291b2046e8f189ba92681 Reviewed-on: https://chromium-review.googlesource.com/1074383 Reviewed-by: Reid Kleckner <rnk@chromium.org> Reviewed-by: Yuri Wiitala <miu@chromium.org> Commit-Queue: Bob Haarman <inglorion@chromium.org> Cr-Commit-Position: refs/heads/master@{#562597} [modify] https://crrev.com/2cdcbfbbd931520d0e3eb74737276662c9379a6d/media/cast/sender/video_encoder_unittest.cc [modify] https://crrev.com/2cdcbfbbd931520d0e3eb74737276662c9379a6d/media/cast/test/end2end_unittest.cc
,
May 30 2018
The bots are green now. Back to miu to decide if you want to fix this properly or close it. As I said on my patch, not running this code in the official build config seems potentially unfortunate.
,
May 31 2018
,
May 31 2018
|
||||||||||
►
Sign in to add a comment |
||||||||||
Comment 1 by krasin@chromium.org
, May 17 2016