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

#include <il.h>

Inheritance diagram for dart::MoveOperands:
dart::ZoneAllocated

Public Member Functions

 MoveOperands (Location dest, Location src)
 
 MoveOperands (const MoveOperands &other)
 
MoveOperandsoperator= (const MoveOperands &other)
 
Location src () const
 
Location dest () const
 
Locationsrc_slot ()
 
Locationdest_slot ()
 
void set_src (const Location &value)
 
void set_dest (const Location &value)
 
Location MarkPending ()
 
void ClearPending (Location dest)
 
bool IsPending () const
 
bool Blocks (Location loc) const
 
bool IsRedundant () const
 
void Eliminate ()
 
bool IsEliminated () const
 
void Write (FlowGraphSerializer *s) const
 
 MoveOperands (FlowGraphDeserializer *d)
 
- Public Member Functions inherited from dart::ZoneAllocated
 ZoneAllocated ()
 
void * operator new (size_t size)
 
void * operator new (size_t size, Zone *zone)
 
void operator delete (void *pointer)
 

Detailed Description

Definition at line 1528 of file il.h.

Constructor & Destructor Documentation

◆ MoveOperands() [1/3]

dart::MoveOperands::MoveOperands ( Location  dest,
Location  src 
)
inline

Definition at line 1530 of file il.h.

1530: dest_(dest), src_(src) {}
Location src() const
Definition: il.h:1540
Location dest() const
Definition: il.h:1541

◆ MoveOperands() [2/3]

dart::MoveOperands::MoveOperands ( const MoveOperands other)
inline

Definition at line 1531 of file il.h.

1532 : ZoneAllocated(), dest_(other.dest_), src_(other.src_) {}

◆ MoveOperands() [3/3]

dart::MoveOperands::MoveOperands ( FlowGraphDeserializer d)
explicit

Definition at line 1377 of file il_serializer.cc.

1378 : dest_(Location::Read(d)), src_(Location::Read(d)) {}
static Location Read(FlowGraphDeserializer *d)
VULKAN_HPP_DEFAULT_DISPATCH_LOADER_DYNAMIC_STORAGE auto & d
Definition: main.cc:19

Member Function Documentation

◆ Blocks()

bool dart::MoveOperands::Blocks ( Location  loc) const
inline

Definition at line 1569 of file il.h.

1569 {
1570 return !IsEliminated() && src_.Equals(loc);
1571 }
bool Equals(Location other) const
Definition: locations.h:519
bool IsEliminated() const
Definition: il.h:1581

◆ ClearPending()

void dart::MoveOperands::ClearPending ( Location  dest)
inline

Definition at line 1558 of file il.h.

1558 {
1559 ASSERT(IsPending());
1560 dest_ = dest;
1561 }
bool IsPending() const
Definition: il.h:1563
#define ASSERT(E)

◆ dest()

Location dart::MoveOperands::dest ( ) const
inline

Definition at line 1541 of file il.h.

1541{ return dest_; }

◆ dest_slot()

Location * dart::MoveOperands::dest_slot ( )
inline

Definition at line 1544 of file il.h.

1544{ return &dest_; }

◆ Eliminate()

void dart::MoveOperands::Eliminate ( )
inline

Definition at line 1580 of file il.h.

1580{ src_ = dest_ = Location::NoLocation(); }
static Location NoLocation()
Definition: locations.h:387

◆ IsEliminated()

bool dart::MoveOperands::IsEliminated ( ) const
inline

Definition at line 1581 of file il.h.

1581 {
1582 ASSERT(!src_.IsInvalid() || dest_.IsInvalid());
1583 return src_.IsInvalid();
1584 }
bool IsInvalid() const
Definition: locations.h:289

◆ IsPending()

bool dart::MoveOperands::IsPending ( ) const
inline

Definition at line 1563 of file il.h.

1563 {
1564 ASSERT(!src_.IsInvalid() || dest_.IsInvalid());
1565 return dest_.IsInvalid() && !src_.IsInvalid();
1566 }

◆ IsRedundant()

bool dart::MoveOperands::IsRedundant ( ) const
inline

Definition at line 1575 of file il.h.

1575 {
1576 return IsEliminated() || dest_.IsInvalid() || src_.Equals(dest_);
1577 }

◆ MarkPending()

Location dart::MoveOperands::MarkPending ( )
inline

Definition at line 1551 of file il.h.

1551 {
1552 ASSERT(!IsPending());
1553 Location dest = dest_;
1554 dest_ = Location::NoLocation();
1555 return dest;
1556 }

◆ operator=()

MoveOperands & dart::MoveOperands::operator= ( const MoveOperands other)
inline

Definition at line 1534 of file il.h.

1534 {
1535 dest_ = other.dest_;
1536 src_ = other.src_;
1537 return *this;
1538 }

◆ set_dest()

void dart::MoveOperands::set_dest ( const Location value)
inline

Definition at line 1547 of file il.h.

1547{ dest_ = value; }
uint8_t value

◆ set_src()

void dart::MoveOperands::set_src ( const Location value)
inline

Definition at line 1546 of file il.h.

1546{ src_ = value; }

◆ src()

Location dart::MoveOperands::src ( ) const
inline

Definition at line 1540 of file il.h.

1540{ return src_; }

◆ src_slot()

Location * dart::MoveOperands::src_slot ( )
inline

Definition at line 1543 of file il.h.

1543{ return &src_; }

◆ Write()

void dart::MoveOperands::Write ( FlowGraphSerializer s) const

Definition at line 1372 of file il_serializer.cc.

1372 {
1373 dest().Write(s);
1374 src().Write(s);
1375}
void Write(FlowGraphSerializer *s) const
struct MyStruct s

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