#include "src/diagnostics/eh-frame.h"
#include <iomanip>
#include <ostream>
#include "src/codegen/code-desc.h"
#if !defined(V8_TARGET_ARCH_X64) && !defined(V8_TARGET_ARCH_ARM) && \
!defined(V8_TARGET_ARCH_ARM64) && !defined(V8_TARGET_ARCH_S390X) && \
!defined(V8_TARGET_ARCH_PPC64)
namespace v8 {
namespace internal {
const int EhFrameConstants::kCodeAlignmentFactor = 1;
const int EhFrameConstants::kDataAlignmentFactor = 1;
void EhFrameWriter::WriteReturnAddressRegisterCode() { UNIMPLEMENTED(); }
void EhFrameWriter::WriteInitialStateInCie() { UNIMPLEMENTED(); }
int EhFrameWriter::RegisterToDwarfCode(Register) {
UNIMPLEMENTED();
}
#ifdef ENABLE_DISASSEMBLER
const char* EhFrameDisassembler::DwarfRegisterCodeToString(int) {
UNIMPLEMENTED();
}
#endif
}
}
#endif
namespace v8 {
namespace internal {
STATIC_CONST_MEMBER_DEFINITION const int
EhFrameConstants::kEhFrameTerminatorSize;
STATIC_CONST_MEMBER_DEFINITION const int EhFrameConstants::kEhFrameHdrVersion;
STATIC_CONST_MEMBER_DEFINITION const int EhFrameConstants::kEhFrameHdrSize;
STATIC_CONST_MEMBER_DEFINITION const uint32_t EhFrameWriter::kInt32Placeholder;
void EhFrameWriter::WriteEmptyEhFrame(std::ostream& stream) { … }
EhFrameWriter::EhFrameWriter(Zone* zone)
: … { … }
void EhFrameWriter::Initialize() { … }
void EhFrameWriter::WriteCie() { … }
void EhFrameWriter::WriteFdeHeader() { … }
void EhFrameWriter::WriteEhFrameHdr(int code_size) { … }
void EhFrameWriter::WritePaddingToAlignedSize(int unpadded_size) { … }
void EhFrameWriter::AdvanceLocation(int pc_offset) { … }
void EhFrameWriter::SetBaseAddressOffset(int base_offset) { … }
void EhFrameWriter::SetBaseAddressRegister(Register base_register) { … }
void EhFrameWriter::SetBaseAddressRegisterAndOffset(Register base_register,
int base_offset) { … }
void EhFrameWriter::RecordRegisterSavedToStack(int dwarf_register_code,
int offset) { … }
void EhFrameWriter::RecordRegisterNotModified(Register name) { … }
void EhFrameWriter::RecordRegisterNotModified(int dwarf_register_code) { … }
void EhFrameWriter::RecordRegisterFollowsInitialRule(Register name) { … }
void EhFrameWriter::RecordRegisterFollowsInitialRule(int dwarf_register_code) { … }
void EhFrameWriter::Finish(int code_size) { … }
void EhFrameWriter::GetEhFrame(CodeDesc* desc) { … }
void EhFrameWriter::WriteULeb128(uint32_t value) { … }
void EhFrameWriter::WriteSLeb128(int32_t value) { … }
uint32_t EhFrameIterator::GetNextULeb128() { … }
int32_t EhFrameIterator::GetNextSLeb128() { … }
uint32_t EhFrameIterator::DecodeULeb128(const uint8_t* encoded,
int* encoded_size) { … }
int32_t EhFrameIterator::DecodeSLeb128(const uint8_t* encoded,
int* encoded_size) { … }
#ifdef ENABLE_DISASSEMBLER
namespace {
class V8_NODISCARD StreamModifiersScope final { … };
}
void EhFrameDisassembler::DumpDwarfDirectives(std::ostream& stream,
const uint8_t* start,
const uint8_t* end) { … }
void EhFrameDisassembler::DisassembleToStream(std::ostream& stream) { … }
#endif
}
}