5 #include "src/code-reference.h" 7 #include "src/handles-inl.h" 8 #include "src/objects-inl.h" 9 #include "src/wasm/wasm-code-manager.h" 14 Address CodeReference::constant_pool()
const {
15 return kind_ == JS ? js_code_->constant_pool() : wasm_code_->constant_pool();
18 Address CodeReference::instruction_start()
const {
20 ? js_code_->InstructionStart()
21 :
reinterpret_cast<Address
>(wasm_code_->instructions().start());
24 Address CodeReference::instruction_end()
const {
26 ? js_code_->InstructionEnd()
27 :
reinterpret_cast<Address
>(wasm_code_->instructions().start() +
28 wasm_code_->instructions().size());
31 int CodeReference::instruction_size()
const {
32 return kind_ == JS ? js_code_->InstructionSize()
33 : wasm_code_->instructions().length();
36 const byte* CodeReference::relocation_start()
const {
37 return kind_ == JS ? js_code_->relocation_start()
38 : wasm_code_->reloc_info().start();
41 const byte* CodeReference::relocation_end()
const {
42 return kind_ == JS ? js_code_->relocation_end()
43 : wasm_code_->reloc_info().start() +
44 wasm_code_->reloc_info().length();
47 int CodeReference::relocation_size()
const {
48 return kind_ == JS ? js_code_->relocation_size()
49 : wasm_code_->reloc_info().length();