mirror of
https://gitee.com/openharmony/arkcompiler_runtime_core
synced 2024-10-07 22:03:39 +00:00
Delete some unnecessary exclusive words
Signed-off-by: shawn_hu_ls <huxiaowei3@huawei.com>
This commit is contained in:
parent
9915fedb2d
commit
fa595eeb87
@ -23,7 +23,7 @@
|
||||
namespace panda::os::unix::native_stack {
|
||||
|
||||
static constexpr int MOVE_2 = 2; // delete kernel stack's prefix
|
||||
static constexpr int STACK_TYPE = 2; // for call ANR type
|
||||
static constexpr int STACK_TYPE = 2; // for calling Application Not Responding stack type
|
||||
static constexpr int FIND_TID = 10; // decimal number
|
||||
|
||||
std::string GetNativeThreadNameForFile(pid_t tid)
|
||||
@ -75,7 +75,7 @@ void DumpKernelStack(std::ostream &os, pid_t tid, const char *tag, bool count)
|
||||
const char *kernel_stack_build = kernel_stack_frames[i].c_str();
|
||||
// change the stack string, case:
|
||||
// kernel stack in linux file is : "[<0>] do_syscall_64+0x73/0x130"
|
||||
// kernel stack in ANR file is : "do_syscall_64+0x73/0x130"
|
||||
// kernel stack in Application Not Responding file is : "do_syscall_64+0x73/0x130"
|
||||
const char *remove_bracket = strchr(kernel_stack_build, ']');
|
||||
if (remove_bracket != nullptr) {
|
||||
kernel_stack_build = remove_bracket + MOVE_2; // NOLINT(cppcoreguidelines-pro-bounds-pointer-arithmetic)
|
||||
|
@ -211,14 +211,14 @@ public:
|
||||
return unwindstack_;
|
||||
}
|
||||
|
||||
void SetTombstoneConnect(void *in)
|
||||
void SetCrashConnect(void *in)
|
||||
{
|
||||
tombstone_connect_ = reinterpret_cast<char *>(in);
|
||||
crash_connect_ = reinterpret_cast<char *>(in);
|
||||
}
|
||||
|
||||
void *GetTombstoneConnect()
|
||||
void *GetCrashConnect()
|
||||
{
|
||||
return tombstone_connect_;
|
||||
return crash_connect_;
|
||||
}
|
||||
|
||||
void SetMobileLog(void *mlog_buf_print_ptr)
|
||||
@ -269,7 +269,7 @@ private:
|
||||
void *mlog_buf_print_ptr_ {nullptr};
|
||||
std::string fingerPrint_ {"unknown"};
|
||||
void *unwindstack_ {nullptr};
|
||||
void *tombstone_connect_ {nullptr};
|
||||
void *crash_connect_ {nullptr};
|
||||
|
||||
friend class panda::JSNApi;
|
||||
friend class coretypes::test::ArrayTest;
|
||||
|
@ -124,7 +124,7 @@ public:
|
||||
};
|
||||
|
||||
struct GCSettings {
|
||||
bool is_gc_enable_tracing = false; /// tracing via systrace
|
||||
bool is_gc_enable_tracing = false; /// if true then enable tracing
|
||||
NativeGcTriggerType native_gc_trigger_type = {
|
||||
NativeGcTriggerType::INVALID_NATIVE_GC_TRIGGER}; /// type of native trigger
|
||||
bool is_dump_heap = false; /// dump heap at the beginning and the end of GC
|
||||
|
@ -139,7 +139,7 @@ void ReferenceStorage::RemoveRef(const Reference *ref)
|
||||
|
||||
if (ref_check_validate_) {
|
||||
if (UNLIKELY(!IsValidRef(ref))) {
|
||||
// Undefined behavior, we just print warning here to comply with ART.
|
||||
// Undefined behavior, we just print warning here.
|
||||
LOG(WARNING, RUNTIME) << "Try to remove not existed ref: " << std::hex << ref;
|
||||
return;
|
||||
}
|
||||
@ -169,7 +169,7 @@ ObjectHeader *ReferenceStorage::GetObject(const Reference *ref)
|
||||
|
||||
if (ref_check_validate_) {
|
||||
if (UNLIKELY(!IsValidRef(ref))) {
|
||||
// Undefined behavior, we just print warning here to comply with ART.
|
||||
// Undefined behavior, we just print warning here.
|
||||
LOG(WARNING, RUNTIME) << "Try to GetObject from a not existed ref: " << std::hex << ref;
|
||||
return nullptr;
|
||||
}
|
||||
|
@ -128,7 +128,7 @@ bool SignalManager::SignalActionHandler(int sig, siginfo_t *info, void *context)
|
||||
}
|
||||
|
||||
bool SignalManager::InOatCode([[maybe_unused]] const siginfo_t *siginfo, [[maybe_unused]] const void *context,
|
||||
[[maybe_unused]] bool check_dex_pc)
|
||||
[[maybe_unused]] bool check_bytecode_pc)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
@ -38,7 +38,7 @@ public:
|
||||
}
|
||||
|
||||
bool SignalActionHandler(int sig, siginfo_t *info, void *context);
|
||||
bool InOatCode(const siginfo_t *siginfo, const void *context, bool check_dex_pc);
|
||||
bool InOatCode(const siginfo_t *siginfo, const void *context, bool check_bytecode_pc);
|
||||
bool InOtherCode(int sig, siginfo_t *info, void *context);
|
||||
|
||||
void AddHandler(SignalHandler *handler, bool oat_code);
|
||||
|
@ -335,8 +335,7 @@ TEST_F(StringTest, ForeignLenghtAndCopyTest3b)
|
||||
TEST_F(StringTest, ForeignLenghtAndCopyTest6b)
|
||||
{
|
||||
std::vector<uint8_t> data {0xed, 0xa0, 0x81, 0xed, 0xb0, 0xb7, 0x20, 0x00}; // UTF-16 size is 3
|
||||
// To be compatible with ART we support 4-byte utf-8 sequences, so {0xd801, 0xdc37} is encoded to 4 bytes instead of
|
||||
// 6
|
||||
// We support 4-byte utf-8 sequences, so {0xd801, 0xdc37} is encoded to 4 bytes instead of 6
|
||||
std::vector<uint8_t> utf8_data {0xf0, 0x90, 0x90, 0xb7, 0x20, 0x00};
|
||||
String *string = String::CreateFromMUtf8(data.data(), 3, GetLanguageContext(), Runtime::GetCurrent()->GetPandaVM());
|
||||
ASSERT_EQ(string->GetMUtf8Length(), utf8_data.size());
|
||||
|
@ -16,7 +16,7 @@
|
||||
#include "include/tooling/debug_inf.h"
|
||||
|
||||
//
|
||||
// Debuge interface for native tools(simpleperf, libunwind).
|
||||
// Debuge interface for native tools(perf, libunwind).
|
||||
//
|
||||
|
||||
namespace panda::tooling {
|
||||
@ -55,7 +55,7 @@ struct PCodeMetaInfo {
|
||||
uint64_t timestamp_ = 1;
|
||||
};
|
||||
|
||||
// simpleperf currently use g_jitDebugDescriptor and g_dexDebugDescriptor
|
||||
// perf currently use g_jitDebugDescriptor and g_dexDebugDescriptor
|
||||
// to find the jit code item and dexfiles.
|
||||
// for using the variable interface, we doesn't change the name in panda
|
||||
// NOLINTNEXTLINE(readability-identifier-naming, fuchsia-statically-constructed-objects)
|
||||
|
Loading…
Reference in New Issue
Block a user