Commit 9960f69f authored by Deepti Gandluri's avatar Deepti Gandluri Committed by Commit Bot

Stop inlining the SupportsWasmSimd128 function

Change-Id: Id9b69f960887f55d26842ecad57c43367c7ddfcd
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2704951Reviewed-by: 's avatarZhi An Ng <zhin@chromium.org>
Commit-Queue: Deepti Gandluri <gdeepti@chromium.org>
Cr-Commit-Position: refs/heads/master@{#73083}
parent 8bc2cfb7
......@@ -49,8 +49,6 @@ namespace internal {
bool CpuFeatures::SupportsOptimizer() { return true; }
bool CpuFeatures::SupportsWasmSimd128() { return IsSupported(NEON); }
int DoubleRegister::SupportedRegisterCount() {
return CpuFeatures::IsSupported(VFP32DREGS) ? 32 : 16;
}
......
......@@ -198,6 +198,8 @@ static constexpr unsigned CpuFeaturesFromCompiler() {
#endif
}
bool CpuFeatures::SupportsWasmSimd128() { return IsSupported(NEON); }
void CpuFeatures::ProbeImpl(bool cross_compile) {
dcache_line_size_ = 64;
......
......@@ -19,8 +19,6 @@ namespace internal {
bool CpuFeatures::SupportsOptimizer() { return true; }
bool CpuFeatures::SupportsWasmSimd128() { return true; }
void RelocInfo::apply(intptr_t delta) {
// On arm64 only internal references and immediate branches need extra work.
if (RelocInfo::IsInternalReference(rmode_)) {
......
......@@ -82,6 +82,7 @@ constexpr unsigned CpuFeaturesFromTargetOS() {
// -----------------------------------------------------------------------------
// CpuFeatures implementation.
bool CpuFeatures::SupportsWasmSimd128() { return true; }
void CpuFeatures::ProbeImpl(bool cross_compile) {
// Only use statically determined features for cross compile (snapshot).
......
......@@ -108,9 +108,9 @@ class V8_EXPORT_PRIVATE CpuFeatures : public AllStatic {
return (supported_ & (1u << f)) != 0;
}
static inline bool SupportsOptimizer();
static bool SupportsWasmSimd128();
static inline bool SupportsWasmSimd128();
static inline bool SupportsOptimizer();
static inline unsigned icache_line_size() {
DCHECK_NE(icache_line_size_, 0);
......
......@@ -49,12 +49,6 @@ namespace internal {
bool CpuFeatures::SupportsOptimizer() { return true; }
bool CpuFeatures::SupportsWasmSimd128() {
if (IsSupported(SSE4_1)) return true;
if (FLAG_wasm_simd_ssse3_codegen && IsSupported(SSSE3)) return true;
return false;
}
// The modes possibly affected by apply must be in kApplyMask.
void RelocInfo::apply(intptr_t delta) {
DCHECK_EQ(kApplyMask, (RelocInfo::ModeMask(RelocInfo::CODE_TARGET) |
......
......@@ -122,6 +122,12 @@ bool OSHasAVXSupport() {
} // namespace
bool CpuFeatures::SupportsWasmSimd128() {
if (IsSupported(SSE4_1)) return true;
if (FLAG_wasm_simd_ssse3_codegen && IsSupported(SSSE3)) return true;
return false;
}
void CpuFeatures::ProbeImpl(bool cross_compile) {
base::CPU cpu;
CHECK(cpu.has_sse2()); // SSE2 support is mandatory.
......
......@@ -47,8 +47,6 @@ namespace internal {
bool CpuFeatures::SupportsOptimizer() { return IsSupported(FPU); }
bool CpuFeatures::SupportsWasmSimd128() { return IsSupported(MIPS_SIMD); }
// -----------------------------------------------------------------------------
// Operand and MemOperand.
......
......@@ -67,6 +67,8 @@ static unsigned CpuFeaturesImpliedByCompiler() {
return answer;
}
bool CpuFeatures::SupportsWasmSimd128() { return IsSupported(MIPS_SIMD); }
void CpuFeatures::ProbeImpl(bool cross_compile) {
supported_ |= CpuFeaturesImpliedByCompiler();
......
......@@ -47,8 +47,6 @@ namespace internal {
bool CpuFeatures::SupportsOptimizer() { return IsSupported(FPU); }
bool CpuFeatures::SupportsWasmSimd128() { return IsSupported(MIPS_SIMD); }
// -----------------------------------------------------------------------------
// Operand and MemOperand.
......
......@@ -67,6 +67,8 @@ static unsigned CpuFeaturesImpliedByCompiler() {
return answer;
}
bool CpuFeatures::SupportsWasmSimd128() { return IsSupported(MIPS_SIMD); }
void CpuFeatures::ProbeImpl(bool cross_compile) {
supported_ |= CpuFeaturesImpliedByCompiler();
......
......@@ -48,8 +48,6 @@ namespace internal {
bool CpuFeatures::SupportsOptimizer() { return true; }
bool CpuFeatures::SupportsWasmSimd128() { return false; }
void RelocInfo::apply(intptr_t delta) {
// absolute code pointer inside code object moves with the code object.
if (IsInternalReference(rmode_)) {
......
......@@ -54,6 +54,8 @@ static unsigned CpuFeaturesImpliedByCompiler() {
return answer;
}
bool CpuFeatures::SupportsWasmSimd128() { return false; }
void CpuFeatures::ProbeImpl(bool cross_compile) {
supported_ |= CpuFeaturesImpliedByCompiler();
icache_line_size_ = 128;
......
......@@ -45,8 +45,6 @@ namespace internal {
bool CpuFeatures::SupportsOptimizer() { return IsSupported(FPU); }
bool CpuFeatures::SupportsWasmSimd128() { return IsSupported(RISCV_SIMD); }
// -----------------------------------------------------------------------------
// Operand and MemOperand.
......
......@@ -60,6 +60,8 @@ static unsigned CpuFeaturesImpliedByCompiler() {
return answer;
}
bool CpuFeatures::SupportsWasmSimd128() { return IsSupported(RISCV_SIMD); }
void CpuFeatures::ProbeImpl(bool cross_compile) {
supported_ |= CpuFeaturesImpliedByCompiler();
......
......@@ -48,10 +48,6 @@ namespace internal {
bool CpuFeatures::SupportsOptimizer() { return true; }
bool CpuFeatures::SupportsWasmSimd128() {
return CpuFeatures::IsSupported(VECTOR_ENHANCE_FACILITY_1);
}
void RelocInfo::apply(intptr_t delta) {
// Absolute code pointer inside code object moves with the code object.
if (IsInternalReference(rmode_)) {
......
......@@ -159,6 +159,10 @@ static bool supportsSTFLE() {
#endif
}
bool CpuFeatures::SupportsWasmSimd128() {
return CpuFeatures::IsSupported(VECTOR_ENHANCE_FACILITY_1);
}
void CpuFeatures::ProbeImpl(bool cross_compile) {
supported_ |= CpuFeaturesImpliedByCompiler();
icache_line_size_ = 256;
......
......@@ -17,12 +17,6 @@ namespace internal {
bool CpuFeatures::SupportsOptimizer() { return true; }
bool CpuFeatures::SupportsWasmSimd128() {
if (IsSupported(SSE4_1)) return true;
if (FLAG_wasm_simd_ssse3_codegen && IsSupported(SSSE3)) return true;
return false;
}
// -----------------------------------------------------------------------------
// Implementation of Assembler
......
......@@ -71,6 +71,12 @@ bool OSHasAVXSupport() {
} // namespace
bool CpuFeatures::SupportsWasmSimd128() {
if (IsSupported(SSE4_1)) return true;
if (FLAG_wasm_simd_ssse3_codegen && IsSupported(SSSE3)) return true;
return false;
}
void CpuFeatures::ProbeImpl(bool cross_compile) {
base::CPU cpu;
CHECK(cpu.has_sse2()); // SSE2 support is mandatory.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment