[PATCH] D15619: [Support] Make llvm::Timer reusable

Nico Weber via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 22 16:48:51 PST 2015


Now it fails to build on Linux for me:

FAILED: /usr/bin/g++   -DGTEST_HAS_PTHREAD=0 -DGTEST_HAS_RTTI=0 -D_DEBUG
-D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS
-D__STDC_LIMIT_MACROS -fPIC -fvisibility-inlines-hidden -Wall -W
-Wno-unused-parameter -Wwrite-strings -Wcast-qual
-Wno-missing-field-initializers -pedantic -Wno-long-long
-Wno-maybe-uninitialized -Wdelete-non-virtual-dtor -Wno-comment -std=c++11
-ffunction-sections -fdata-sections -O3  -Iunittests/Support
-I/usr/local/google/home/thakis/src/chrome/src/third_party/llvm/unittests/Support
-Iinclude
-I/usr/local/google/home/thakis/src/chrome/src/third_party/llvm/include
-I/usr/local/google/home/thakis/src/chrome/src/third_party/llvm/utils/unittest/googletest/include
   -UNDEBUG  -Wno-variadic-macros -fno-exceptions -fno-rtti -MMD -MT
unittests/Support/CMakeFiles/SupportTests.dir/TimerTest.cpp.o -MF
unittests/Support/CMakeFiles/SupportTests.dir/TimerTest.cpp.o.d -o
unittests/Support/CMakeFiles/SupportTests.dir/TimerTest.cpp.o -c
/usr/local/google/home/thakis/src/chrome/src/third_party/llvm/unittests/Support/TimerTest.cpp

chrome/src/third_party/llvm/unittests/Support/TimerTest.cpp:29:8: error:
‘std::this_thread’ has not been declared
   std::this_thread::sleep_for(std::chrono::milliseconds(1));


On Tue, Dec 22, 2015 at 6:21 PM, Vedant Kumar <vsk at apple.com> wrote:

> vsk added inline comments.
>
> ================
> Comment at: unittests/Support/TimerTest.cpp:12
> @@ +11,3 @@
> +#include "gtest/gtest.h"
> +#include <chrono>
> +#include <thread>
> ----------------
> thakis wrote:
> > This doesn't build on Windows:
> >
> > FAILED: C:\PROGRA~2\MICROS~1.0\VC\bin\cl.exe   /nologo /TP /DWIN32
> /D_WINDOWS   -wd4141 -wd4146 -wd4180 -wd4244 -wd4258 -wd4267 -wd4291
> -wd4345 -wd4351 -wd4355 -wd4456 -wd4457 -wd4458 -wd4459 -wd4503 -wd4624
> -wd4722 -wd4800 -wd4100 -wd4127 -wd4512 -wd4505 -wd4610 -wd4510 -wd4702
> -wd4245 -wd4706 -wd4310 -wd4701 -wd4703 -wd4389 -wd4611 -wd4805 -wd4204
> -wd4577 -wd4091 -wd4592 -wd4324 -w14062 -we4238 /W4 /Zc:inline /MD /O2 /Ob2
> -Iunittests\Support
> -IC:\buildbot\slave-config\clang-x86-win2008-selfhost\llvm\unittests\Support
> -Iinclude
> -IC:\buildbot\slave-config\clang-x86-win2008-selfhost\llvm\include
> -IC:\buildbot\slave-config\clang-x86-win2008-selfhost\llvm\utils\unittest\googletest\include
>   -UNDEBUG  /EHs-c- /GR- /showIncludes -DGTEST_HAS_RTTI=0
> -D_CRT_NONSTDC_NO_DEPRECATE -D_CRT_NONSTDC_NO_WARNINGS
> -D_CRT_SECURE_NO_DEPRECATE -D_CRT_SECURE_NO_WARNINGS
> -D_DEBUG_POINTER_IMPL="" -D_HAS_EXCEPTIONS=0 -D_SCL_SECURE_NO_DEPRECATE
> -D_SCL_SECURE_NO_WARNINGS -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS
> -D__STDC_LIMIT_MACROS
> /Founittests\Support\CMakeFiles\SupportTests.dir\TimerTest.cpp.obj
> /Fdunittests\Support\CMakeFiles\SupportTests.dir\ /FS -c
> C:\buildbot\slave-config\clang-x86-win2008-selfhost\llvm\unittests\Support\TimerTest.cpp
> > C:\Program Files (x86)\Microsoft Visual Studio
> 12.0\VC\INCLUDE\concrt.h(313) : warning C4530: C++ exception handler used,
> but unwind semantics are not enabled. Specify /EHsc
> > C:\Program Files (x86)\Microsoft Visual Studio
> 12.0\VC\INCLUDE\concrt.h(4774) : error C3861: '__uncaught_exception':
> identifier not found
> >
> > See the goop in include/llvm/Support/ThreadPool.h for what you probably
> need to do here.
> Sorry for the delay. I got bitten by hfs case-insensitivity in r256290,
> hopefully r256292 fixes things.
>
>
> http://reviews.llvm.org/D15619
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20151222/afaeec9f/attachment.html>


More information about the llvm-commits mailing list