Flutter Engine
The Flutter Engine
Public Member Functions | List of all members
dart::AbstractCode Class Reference

#include <profiler.h>

Public Member Functions

 AbstractCode (ObjectPtr code)
 
ObjectPtr ptr () const
 
const Objecthandle () const
 
uword PayloadStart () const
 
uword Size () const
 
int64_t compile_timestamp () const
 
const char * Name () const
 
const char * QualifiedName () const
 
bool IsStubCode () const
 
bool IsAllocationStubCode () const
 
bool IsTypeTestStubCode () const
 
ObjectPtr owner () const
 
bool IsNull () const
 
bool IsCode () const
 
bool is_optimized () const
 

Detailed Description

Definition at line 406 of file profiler.h.

Constructor & Destructor Documentation

◆ AbstractCode()

dart::AbstractCode::AbstractCode ( ObjectPtr  code)
inlineexplicit

Definition at line 408 of file profiler.h.

408 : code_(Object::Handle(code)) {
409 ASSERT(code_.IsNull() || code_.IsCode());
410 }
bool IsNull() const
Definition: object.h:363
static Object & Handle()
Definition: object.h:407
#define ASSERT(E)

Member Function Documentation

◆ compile_timestamp()

int64_t dart::AbstractCode::compile_timestamp ( ) const
inline

Definition at line 425 of file profiler.h.

425 {
426 if (code_.IsCode()) {
427 return Code::Cast(code_).compile_timestamp();
428 } else {
429 return 0;
430 }
431 }

◆ handle()

const Object * dart::AbstractCode::handle ( ) const
inline

Definition at line 413 of file profiler.h.

413{ return &code_; }

◆ is_optimized()

bool dart::AbstractCode::is_optimized ( ) const
inline

Definition at line 485 of file profiler.h.

485 {
486 if (code_.IsCode()) {
487 return Code::Cast(code_).is_optimized();
488 } else {
489 return false;
490 }
491 }

◆ IsAllocationStubCode()

bool dart::AbstractCode::IsAllocationStubCode ( ) const
inline

Definition at line 458 of file profiler.h.

458 {
459 if (code_.IsCode()) {
460 return Code::Cast(code_).IsAllocationStubCode();
461 } else {
462 return false;
463 }
464 }

◆ IsCode()

bool dart::AbstractCode::IsCode ( ) const
inline

Definition at line 483 of file profiler.h.

483{ return code_.IsCode(); }

◆ IsNull()

bool dart::AbstractCode::IsNull ( ) const
inline

Definition at line 482 of file profiler.h.

482{ return code_.IsNull(); }

◆ IsStubCode()

bool dart::AbstractCode::IsStubCode ( ) const
inline

Definition at line 450 of file profiler.h.

450 {
451 if (code_.IsCode()) {
452 return Code::Cast(code_).IsStubCode();
453 } else {
454 return false;
455 }
456 }

◆ IsTypeTestStubCode()

bool dart::AbstractCode::IsTypeTestStubCode ( ) const
inline

Definition at line 466 of file profiler.h.

466 {
467 if (code_.IsCode()) {
468 return Code::Cast(code_).IsTypeTestStubCode();
469 } else {
470 return false;
471 }
472 }

◆ Name()

const char * dart::AbstractCode::Name ( ) const
inline

Definition at line 433 of file profiler.h.

433 {
434 if (code_.IsCode()) {
435 return Code::Cast(code_).Name();
436 } else {
437 return "";
438 }
439 }

◆ owner()

ObjectPtr dart::AbstractCode::owner ( ) const
inline

Definition at line 474 of file profiler.h.

474 {
475 if (code_.IsCode()) {
476 return Code::Cast(code_).owner();
477 } else {
478 return Object::null();
479 }
480 }
static ObjectPtr null()
Definition: object.h:433

◆ PayloadStart()

uword dart::AbstractCode::PayloadStart ( ) const
inline

Definition at line 415 of file profiler.h.

415 {
416 ASSERT(code_.IsCode());
417 return Code::Cast(code_).PayloadStart();
418 }

◆ ptr()

ObjectPtr dart::AbstractCode::ptr ( ) const
inline

Definition at line 412 of file profiler.h.

412{ return code_.ptr(); }
ObjectPtr ptr() const
Definition: object.h:332

◆ QualifiedName()

const char * dart::AbstractCode::QualifiedName ( ) const
inline

Definition at line 441 of file profiler.h.

441 {
442 if (code_.IsCode()) {
443 return Code::Cast(code_).QualifiedName(
444 NameFormattingParams(Object::kUserVisibleName));
445 } else {
446 return "";
447 }
448 }
@ kUserVisibleName
Definition: object.h:645

◆ Size()

uword dart::AbstractCode::Size ( ) const
inline

Definition at line 420 of file profiler.h.

420 {
421 ASSERT(code_.IsCode());
422 return Code::Cast(code_).Size();
423 }

The documentation for this class was generated from the following file: