v8
V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++.
Loading...
Searching...
No Matches
fpu.h
Go to the documentation of this file.
1
// Copyright 2025 the V8 project authors. All rights reserved.
2
// Use of this source code is governed by a BSD-style license that can be
3
// found in the LICENSE file.
4
5
#ifndef V8_BASE_FPU_H_
6
#define V8_BASE_FPU_H_
7
8
#include "
src/base/base-export.h
"
9
10
namespace
v8::base
{
11
class
FPU
final {
12
public
:
13
V8_BASE_EXPORT
static
bool
GetFlushDenormals
();
14
V8_BASE_EXPORT
static
void
SetFlushDenormals
(
bool
);
15
};
16
class
V8_BASE_EXPORT
FlushDenormalsScope
final {
17
public
:
18
explicit
FlushDenormalsScope
(
bool
value)
19
: old_flush_state_(
FPU
::GetFlushDenormals()) {
20
FPU::SetFlushDenormals(value);
21
}
22
~FlushDenormalsScope
() { FPU::SetFlushDenormals(old_flush_state_); }
23
24
private
:
25
bool
old_flush_state_
;
26
};
27
}
// namespace v8::base
28
29
#endif
// V8_BASE_FPU_H_
base-export.h
V8_BASE_EXPORT
#define V8_BASE_EXPORT
Definition
base-export.h:26
v8::base::FPU
Definition
fpu.h:11
v8::base::FPU::GetFlushDenormals
static V8_BASE_EXPORT bool GetFlushDenormals()
Definition
fpu.cc:96
v8::base::FPU::SetFlushDenormals
static V8_BASE_EXPORT void SetFlushDenormals(bool)
Definition
fpu.cc:97
v8::base::FlushDenormalsScope
Definition
fpu.h:16
v8::base::FlushDenormalsScope::FlushDenormalsScope
FlushDenormalsScope(bool value)
Definition
fpu.h:18
v8::base::FlushDenormalsScope::~FlushDenormalsScope
~FlushDenormalsScope()
Definition
fpu.h:22
v8::base::FlushDenormalsScope::old_flush_state_
bool old_flush_state_
Definition
fpu.h:25
v8::base
Definition
scopes.h:26
src
base
fpu.h
Generated on Sun Apr 6 2025 21:08:50 for v8 by
1.12.0