V8 Project
v8::internal::CallFunctionStub Class Reference

#include <code-stubs.h>

+ Inheritance diagram for v8::internal::CallFunctionStub:
+ Collaboration diagram for v8::internal::CallFunctionStub:

Classes

class  ArgcBits
 
class  FlagBits
 

Public Member Functions

 CallFunctionStub (Isolate *isolate, int argc, CallFunctionFlags flags)
 
- Public Member Functions inherited from v8::internal::PlatformCodeStub
virtual Handle< CodeGenerateCode () OVERRIDE
 
virtual Code::Kind GetCodeKind () const
 

Static Public Member Functions

static int ExtractArgcFromMinorKey (int minor_key)
 

Private Member Functions

int argc () const
 
int flags () const
 
bool CallAsMethod () const
 
bool NeedsChecks () const
 
virtual void PrintName (OStream &os) const OVERRIDE
 
 STATIC_ASSERT (Code::kArgumentsBits+2<=kStubMinorKeyBits)
 
 DEFINE_CALL_INTERFACE_DESCRIPTOR (CallFunction)
 
 DEFINE_PLATFORM_CODE_STUB (CallFunction, PlatformCodeStub)
 

Additional Inherited Members

- Protected Member Functions inherited from v8::internal::PlatformCodeStub
 PlatformCodeStub (Isolate *isolate)
 
virtual void Generate (MacroAssembler *masm)=0
 
 DEFINE_CODE_STUB_BASE (PlatformCodeStub, CodeStub)
 

Detailed Description

Definition at line 1527 of file code-stubs.h.

Constructor & Destructor Documentation

◆ CallFunctionStub()

v8::internal::CallFunctionStub::CallFunctionStub ( Isolate isolate,
int  argc,
CallFunctionFlags  flags 
)
inline

Definition at line 1529 of file code-stubs.h.

1530  : PlatformCodeStub(isolate) {
1531  DCHECK(argc >= 0 && argc <= Code::kMaxArguments);
1532  minor_key_ = ArgcBits::encode(argc) | FlagBits::encode(flags);
1533  }
static U encode(T value)
Definition: utils.h:217
static const int kMaxArguments
Definition: objects.h:5445
PlatformCodeStub(Isolate *isolate)
Definition: code-stubs.h:341
#define DCHECK(condition)
Definition: logging.h:205

References argc(), DCHECK, v8::internal::BitFieldBase< T, shift, size, U >::encode(), flags(), and v8::internal::Code::kMaxArguments.

+ Here is the call graph for this function:

Member Function Documentation

◆ argc()

int v8::internal::CallFunctionStub::argc ( ) const
inlineprivate

Definition at line 1540 of file code-stubs.h.

1540 { return ArgcBits::decode(minor_key_); }
static T decode(U value)
Definition: utils.h:228

References v8::internal::BitFieldBase< T, shift, size, U >::decode().

Referenced by CallFunctionStub(), and PrintName().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ CallAsMethod()

bool v8::internal::CallFunctionStub::CallAsMethod ( ) const
inlineprivate

Definition at line 1543 of file code-stubs.h.

1543  {
1544  return flags() == CALL_AS_METHOD || flags() == WRAP_AND_CALL;
1545  }
@ WRAP_AND_CALL
Definition: globals.h:473
@ CALL_AS_METHOD
Definition: globals.h:470

References v8::internal::CALL_AS_METHOD, flags(), and v8::internal::WRAP_AND_CALL.

+ Here is the call graph for this function:

◆ DEFINE_CALL_INTERFACE_DESCRIPTOR()

v8::internal::CallFunctionStub::DEFINE_CALL_INTERFACE_DESCRIPTOR ( CallFunction  )
private

◆ DEFINE_PLATFORM_CODE_STUB()

v8::internal::CallFunctionStub::DEFINE_PLATFORM_CODE_STUB ( CallFunction  ,
PlatformCodeStub   
)
private

◆ ExtractArgcFromMinorKey()

static int v8::internal::CallFunctionStub::ExtractArgcFromMinorKey ( int  minor_key)
inlinestatic

Definition at line 1535 of file code-stubs.h.

1535  {
1536  return ArgcBits::decode(minor_key);
1537  }

References v8::internal::BitFieldBase< T, shift, size, U >::decode().

Referenced by v8::internal::Debug::PrepareStep().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ flags()

int v8::internal::CallFunctionStub::flags ( ) const
inlineprivate

Definition at line 1541 of file code-stubs.h.

1541 { return FlagBits::decode(minor_key_); }

References v8::internal::BitFieldBase< T, shift, size, U >::decode().

Referenced by CallAsMethod(), CallFunctionStub(), and NeedsChecks().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ NeedsChecks()

bool v8::internal::CallFunctionStub::NeedsChecks ( ) const
inlineprivate

Definition at line 1547 of file code-stubs.h.

1547 { return flags() != WRAP_AND_CALL; }

References flags(), and v8::internal::WRAP_AND_CALL.

+ Here is the call graph for this function:

◆ PrintName()

void v8::internal::CallFunctionStub::PrintName ( OStream os) const
privatevirtual

Definition at line 795 of file code-stubs.cc.

795  { // NOLINT
796  os << "CallFunctionStub_Args" << argc();
797 }

References argc().

+ Here is the call graph for this function:

◆ STATIC_ASSERT()

v8::internal::CallFunctionStub::STATIC_ASSERT ( Code::kArgumentsBits+2<=  kStubMinorKeyBits)
private

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