forked from mirrors/gecko-dev
Bug 1827566 - Isolate SSE2 requirements to SSE-compiled file r=glandium
Only provide forward declaration to the generic code. Differential Revision: https://phabricator.services.mozilla.com/D175742
This commit is contained in:
parent
f8f8179943
commit
7df7d42bf2
3 changed files with 28 additions and 2 deletions
|
|
@ -159,7 +159,7 @@ static inline int32_t FirstNon8BitUnvectorized(const char16_t* str,
|
|||
}
|
||||
|
||||
#if defined(MOZILLA_MAY_SUPPORT_SSE2)
|
||||
# include "nsTextFragmentGeneric.h"
|
||||
# include "nsTextFragmentGenericFwd.h"
|
||||
#endif
|
||||
|
||||
#ifdef __powerpc__
|
||||
|
|
|
|||
|
|
@ -4,10 +4,14 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
#ifndef nsTextFragmentGeneric_h__
|
||||
#define nsTextFragmentGeneric_h__
|
||||
|
||||
#include "nsTextFragmentGenericFwd.h"
|
||||
|
||||
#include "nscore.h"
|
||||
#include "nsTextFragmentImpl.h"
|
||||
#include <algorithm>
|
||||
#include <xsimd/xsimd.hpp>
|
||||
|
||||
namespace mozilla {
|
||||
|
||||
|
|
@ -57,3 +61,5 @@ int32_t FirstNon8Bit(const char16_t* str, const char16_t* end) {
|
|||
}
|
||||
|
||||
} // namespace mozilla
|
||||
|
||||
#endif
|
||||
|
|
|
|||
20
dom/base/nsTextFragmentGenericFwd.h
Normal file
20
dom/base/nsTextFragmentGenericFwd.h
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim: set ts=8 sts=2 et sw=2 tw=80: */
|
||||
/* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
#ifndef nsTextFragmentGenericFwd_h__
|
||||
#define nsTextFragmentGenericFwd_h__
|
||||
|
||||
#include <cstdint>
|
||||
#include <xsimd/xsimd.hpp>
|
||||
|
||||
namespace mozilla {
|
||||
|
||||
template <class Arch>
|
||||
int32_t FirstNon8Bit(const char16_t* str, const char16_t* end);
|
||||
|
||||
} // namespace mozilla
|
||||
|
||||
#endif
|
||||
Loading…
Reference in a new issue