v8
V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++.
Loading...
Searching...
No Matches
code-kind.cc
Go to the documentation of this file.
1
// Copyright 2020 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
#include "
src/objects/code-kind.h
"
6
7
namespace
v8
{
8
namespace
internal
{
9
10
const
char
*
CodeKindToString
(
CodeKind
kind
) {
11
switch
(
kind
) {
12
#define CASE(name) \
13
case CodeKind::name: \
14
return #name;
15
CODE_KIND_LIST
(
CASE
)
16
#undef CASE
17
}
18
UNREACHABLE
();
19
}
20
21
const
char
*
CodeKindToMarker
(
CodeKind
kind
,
bool
context_specialized) {
22
switch
(
kind
) {
23
case
CodeKind::INTERPRETED_FUNCTION:
24
return
"~"
;
25
case
CodeKind::BASELINE:
26
return
"^"
;
27
case
CodeKind::MAGLEV:
28
return
context_specialized ?
"+'"
:
"+"
;
29
case
CodeKind::TURBOFAN_JS:
30
return
context_specialized ?
"*'"
:
"*"
;
31
default
:
32
return
""
;
33
}
34
}
35
36
}
// namespace internal
37
}
// namespace v8
kind
Builtins::Kind kind
Definition
builtins.cc:40
code-kind.h
CODE_KIND_LIST
#define CODE_KIND_LIST(V)
Definition
code-kind.h:18
v8::internal::TranslationOpcode::CASE
CASE(name,...)
v8::internal::CodeKindToMarker
const char * CodeKindToMarker(CodeKind kind, bool context_specialized)
Definition
code-kind.cc:21
v8::internal::CodeKindToString
const char * CodeKindToString(CodeKind kind)
Definition
code-kind.cc:10
v8::internal::internal
internal
Definition
wasm-objects-inl.h:458
v8::internal::CodeKind
CodeKind
Definition
code-kind.h:33
v8::internal::UNREACHABLE
UNREACHABLE()
v8
Definition
api-arguments-inl.h:19
src
objects
code-kind.cc
Generated on Sun Apr 6 2025 21:08:55 for v8 by
1.12.0