gem5 v24.0.0.0
Loading...
Searching...
No Matches
guest_abi.test.cc File Reference
#include <gtest/gtest.h>
#include <type_traits>
#include <utility>
#include "sim/guest_abi.hh"

Go to the source code of this file.

Classes

class  gem5::ThreadContext
 ThreadContext is the external interface to all thread state for anything outside of the CPU. More...
 
struct  TestABI_1D
 
struct  TestABI_Prepare
 
struct  TestABI_2D
 
struct  TestABI_TcInit
 
struct  TestABI_TcInit::State
 
struct  gem5::guest_abi::Argument< TestABI_1D, int >
 
struct  gem5::guest_abi::Argument< TestABI_1D, Arg, typename std::enable_if_t< std::is_floating_point_v< Arg > > >
 
struct  gem5::guest_abi::Result< TestABI_1D, int >
 
struct  gem5::guest_abi::Result< TestABI_1D, Ret, typename std::enable_if_t< std::is_floating_point_v< Ret > > >
 
struct  gem5::guest_abi::Argument< TestABI_Prepare, int >
 
struct  gem5::guest_abi::Result< TestABI_Prepare, Ret >
 
struct  gem5::guest_abi::Argument< TestABI_2D, int >
 
struct  gem5::guest_abi::Argument< TestABI_2D, Arg, typename std::enable_if_t< std::is_floating_point_v< Arg > > >
 
struct  gem5::guest_abi::Result< TestABI_2D, int >
 
struct  gem5::guest_abi::Result< TestABI_2D, Ret, typename std::enable_if_t< std::is_floating_point_v< Ret > > >
 
struct  gem5::guest_abi::Argument< TestABI_TcInit, int >
 

Namespaces

namespace  gem5
 Copyright (c) 2024 - Pranith Kumar Copyright (c) 2020 Inria All rights reserved.
 
namespace  gem5::guest_abi
 

Functions

void testIntVoid (ThreadContext *tc, int a, float b, int c, double d, guest_abi::VarArgs< int, float, double > varargs)
 
void testPrepareVoid (ThreadContext *tc, int a, int b)
 
int testPrepareInt (ThreadContext *tc, int a, int b)
 
void test2DVoid (ThreadContext *tc, int a, float b, int c, double d, guest_abi::VarArgs< int, float, double > varargs)
 
void testTcInit (ThreadContext *tc, int a)
 
int testIntRet (ThreadContext *tc)
 
float testFloatRet (ThreadContext *tc)
 
double testDoubleRet (ThreadContext *tc)
 
 TEST (GuestABITest, ABI_1D_args)
 
 TEST (GuestABITest, ABI_Prepare)
 
 TEST (GuestABITest, ABI_2D_args)
 
 TEST (GuestABITest, ABI_TC_init)
 
 TEST (GuestABITest, ABI_returns)
 
 TEST (GuestABITest, dumpSimcall)
 
 TEST (GuestABITest, isVarArgs)
 

Variables

const int IntRetValue = 50
 
const float FloatRetValue = 3.14
 
const double DoubleRetValue = 12.34
 

Function Documentation

◆ TEST() [1/7]

◆ TEST() [2/7]

◆ TEST() [3/7]

TEST ( GuestABITest ,
ABI_Prepare  )

Definition at line 312 of file guest_abi.test.cc.

References gem5::invokeSimcall(), testPrepareInt(), and testPrepareVoid().

◆ TEST() [4/7]

◆ TEST() [5/7]

TEST ( GuestABITest ,
ABI_TC_init  )

◆ TEST() [6/7]

TEST ( GuestABITest ,
dumpSimcall  )

Definition at line 392 of file guest_abi.test.cc.

References gem5::statistics::dump(), gem5::dumpSimcall(), and testIntVoid().

◆ TEST() [7/7]

TEST ( GuestABITest ,
isVarArgs  )

Definition at line 399 of file guest_abi.test.cc.

References gem5::guest_abi::IsVarArgsV.

◆ test2DVoid()

void test2DVoid ( ThreadContext * tc,
int a,
float b,
int c,
double d,
guest_abi::VarArgs< int, float, double > varargs )

◆ testDoubleRet()

double testDoubleRet ( ThreadContext * tc)

Definition at line 300 of file guest_abi.test.cc.

References DoubleRetValue.

Referenced by TEST().

◆ testFloatRet()

float testFloatRet ( ThreadContext * tc)

Definition at line 299 of file guest_abi.test.cc.

References FloatRetValue.

Referenced by TEST().

◆ testIntRet()

int testIntRet ( ThreadContext * tc)

Definition at line 298 of file guest_abi.test.cc.

References IntRetValue.

Referenced by TEST().

◆ testIntVoid()

void testIntVoid ( ThreadContext * tc,
int a,
float b,
int c,
double d,
guest_abi::VarArgs< int, float, double > varargs )

◆ testPrepareInt()

int testPrepareInt ( ThreadContext * tc,
int a,
int b )

Definition at line 263 of file guest_abi.test.cc.

References gem5::ArmISA::a, gem5::ArmISA::b, and gem5::ThreadContext::ints.

Referenced by TEST().

◆ testPrepareVoid()

void testPrepareVoid ( ThreadContext * tc,
int a,
int b )

Definition at line 256 of file guest_abi.test.cc.

References gem5::ArmISA::a, gem5::ArmISA::b, and gem5::ThreadContext::ints.

Referenced by TEST().

◆ testTcInit()

void testTcInit ( ThreadContext * tc,
int a )

Definition at line 287 of file guest_abi.test.cc.

References gem5::ArmISA::a, gem5::ThreadContext::intOffset, and gem5::ThreadContext::ints.

Referenced by TEST().

Variable Documentation

◆ DoubleRetValue

const double DoubleRetValue = 12.34

Definition at line 296 of file guest_abi.test.cc.

Referenced by TEST(), and testDoubleRet().

◆ FloatRetValue

const float FloatRetValue = 3.14

Definition at line 295 of file guest_abi.test.cc.

Referenced by TEST(), and testFloatRet().

◆ IntRetValue

const int IntRetValue = 50

Definition at line 294 of file guest_abi.test.cc.

Referenced by TEST(), and testIntRet().


Generated on Tue Jun 18 2024 16:24:08 for gem5 by doxygen 1.11.0