svn commit: r263097 - in projects/uefi: contrib/libc++/include contrib/llvm/tools/clang/lib/CodeGen sys/net
Ed Maste
emaste at FreeBSD.org
Wed Mar 12 19:52:05 UTC 2014
Author: emaste
Date: Wed Mar 12 19:52:04 2014
New Revision: 263097
URL: http://svnweb.freebsd.org/changeset/base/263097
Log:
Merge ^/head at 262809
Sponsored by: The FreeBSD Foundation
Modified:
projects/uefi/contrib/libc++/include/__functional_03
projects/uefi/contrib/libc++/include/functional
projects/uefi/contrib/llvm/tools/clang/lib/CodeGen/CGCXX.cpp
projects/uefi/sys/net/route.c
projects/uefi/sys/net/route.h
Directory Properties:
projects/uefi/ (props changed)
projects/uefi/contrib/libc++/ (props changed)
projects/uefi/contrib/llvm/ (props changed)
projects/uefi/contrib/llvm/tools/clang/ (props changed)
projects/uefi/sys/ (props changed)
Modified: projects/uefi/contrib/libc++/include/__functional_03
==============================================================================
--- projects/uefi/contrib/libc++/include/__functional_03 Wed Mar 12 17:18:15 2014 (r263096)
+++ projects/uefi/contrib/libc++/include/__functional_03 Wed Mar 12 19:52:04 2014 (r263097)
@@ -33,28 +33,28 @@ public:
// invoke
typename __invoke_return<type>::type
- operator() ()
+ operator() () const
{
return __invoke(__f_);
}
template <class _A0>
typename __invoke_return0<type, _A0>::type
- operator() (_A0& __a0)
+ operator() (_A0& __a0) const
{
return __invoke(__f_, __a0);
}
template <class _A0, class _A1>
typename __invoke_return1<type, _A0, _A1>::type
- operator() (_A0& __a0, _A1& __a1)
+ operator() (_A0& __a0, _A1& __a1) const
{
return __invoke(__f_, __a0, __a1);
}
template <class _A0, class _A1, class _A2>
typename __invoke_return2<type, _A0, _A1, _A2>::type
- operator() (_A0& __a0, _A1& __a1, _A2& __a2)
+ operator() (_A0& __a0, _A1& __a1, _A2& __a2) const
{
return __invoke(__f_, __a0, __a1, __a2);
}
Modified: projects/uefi/contrib/libc++/include/functional
==============================================================================
--- projects/uefi/contrib/libc++/include/functional Wed Mar 12 17:18:15 2014 (r263096)
+++ projects/uefi/contrib/libc++/include/functional Wed Mar 12 19:52:04 2014 (r263097)
@@ -1221,7 +1221,7 @@ public:
template <class... _ArgTypes>
_LIBCPP_INLINE_VISIBILITY
typename __invoke_return<type, _ArgTypes...>::type
- operator() (_ArgTypes&&... __args)
+ operator() (_ArgTypes&&... __args) const
{
return __invoke(__f_, _VSTD::forward<_ArgTypes>(__args)...);
}
Modified: projects/uefi/contrib/llvm/tools/clang/lib/CodeGen/CGCXX.cpp
==============================================================================
--- projects/uefi/contrib/llvm/tools/clang/lib/CodeGen/CGCXX.cpp Wed Mar 12 17:18:15 2014 (r263096)
+++ projects/uefi/contrib/llvm/tools/clang/lib/CodeGen/CGCXX.cpp Wed Mar 12 19:52:04 2014 (r263097)
@@ -92,7 +92,13 @@ bool CodeGenModule::TryEmitBaseDestructo
if (!ClassLayout.getBaseClassOffset(UniqueBase).isZero())
return true;
+ // Give up if the calling conventions don't match. We could update the call,
+ // but it is probably not worth it.
const CXXDestructorDecl *BaseD = UniqueBase->getDestructor();
+ if (BaseD->getType()->getAs<FunctionType>()->getCallConv() !=
+ D->getType()->getAs<FunctionType>()->getCallConv())
+ return true;
+
return TryEmitDefinitionAsAlias(GlobalDecl(D, Dtor_Base),
GlobalDecl(BaseD, Dtor_Base),
false);
Modified: projects/uefi/sys/net/route.c
==============================================================================
--- projects/uefi/sys/net/route.c Wed Mar 12 17:18:15 2014 (r263096)
+++ projects/uefi/sys/net/route.c Wed Mar 12 19:52:04 2014 (r263097)
@@ -237,6 +237,14 @@ rtentry_ctor(void *mem, int size, void *
}
static void
+rtentry_dtor(void *mem, int size, void *arg)
+{
+ struct rtentry *rt = mem;
+
+ RT_UNLOCK_COND(rt);
+}
+
+static void
vnet_route_init(const void *unused __unused)
{
struct domain *dom;
@@ -248,7 +256,7 @@ vnet_route_init(const void *unused __unu
sizeof(struct radix_node_head *), M_RTABLE, M_WAITOK|M_ZERO);
V_rtzone = uma_zcreate("rtentry", sizeof(struct rtentry),
- rtentry_ctor, NULL,
+ rtentry_ctor, rtentry_dtor,
rtentry_zinit, rtentry_zfini, UMA_ALIGN_PTR, 0);
for (dom = domains; dom; dom = dom->dom_next) {
if (dom->dom_rtattach == NULL)
Modified: projects/uefi/sys/net/route.h
==============================================================================
--- projects/uefi/sys/net/route.h Wed Mar 12 17:18:15 2014 (r263096)
+++ projects/uefi/sys/net/route.h Wed Mar 12 19:52:04 2014 (r263097)
@@ -309,6 +309,10 @@ struct rt_addrinfo {
#define RT_UNLOCK(_rt) mtx_unlock(&(_rt)->rt_mtx)
#define RT_LOCK_DESTROY(_rt) mtx_destroy(&(_rt)->rt_mtx)
#define RT_LOCK_ASSERT(_rt) mtx_assert(&(_rt)->rt_mtx, MA_OWNED)
+#define RT_UNLOCK_COND(_rt) do { \
+ if (mtx_owned(&(_rt)->rt_mtx)) \
+ mtx_unlock(&(_rt)->rt_mtx); \
+} while (0)
#define RT_ADDREF(_rt) do { \
RT_LOCK_ASSERT(_rt); \
More information about the svn-src-projects
mailing list