hi, all.
I found there are some switchs like switch cases (C/C++) in the file "decode.cc"
here's the code below:
------------------------------------------------------------------------------------------
StaticInstPtr
ArmISA::Decoder::decodeInst(ArmISA::ExtMachInst machInst)
{
    using namespace ArmISAInst;
  switch (THUMB) {
    
    case 0x0:
      switch (AARCH64) {
        
        case 0x0:
          switch (COND_CODE) {
            
            case 0xf:  
              //
ArmUnconditional::armUnconditional(([], {}))
              
                  {
...
break;
    default: switch (ENCODING) { 
 case 0x0:
switch (SEVEN_AND_FOUR) {
...
...
...
------------------------------------------------------------------------------------------
I'd like know what's the switch criterion? 
Such as "THUMB" , "AARCH64" , "COND_CODE" , "ENCODING" , "SEVEN_AND_FOUR" ...etc
Are they defined in the file "arch/arm/types.hh" ?
here's the code below:
------------------------------------------------------------------------------------------
    BitUnion64(ExtMachInst)
        // ITSTATE bits
        Bitfield<55, 48> itstate;
        Bitfield<55, 52> itstateCond;
        Bitfield<51, 48> itstateMask;
        // FPSCR fields
        Bitfield<41, 40> fpscrStride;
        Bitfield<39, 37> fpscrLen;
        // Bitfields to select mode.
        Bitfield<36>     thumb; // here it's what
I mentioned 
        Bitfield<35>     bigThumb; // here it's
what I mentioned 
        Bitfield<34>     aarch64; // here it's
what I mentioned 
        // Made up bitfields that make life easier.
        Bitfield<33>     sevenAndFour; // here
it's what I mentioned 
        Bitfield<32>     isMisc; // here it's
what I mentioned 
        uint32_t         instBits;
        // All the different types of opcode fields.
        Bitfield<27, 25> encoding;
...
...
...
------------------------------------------------------------------------------------------
Thanks!
_______________________________________________
gem5-users mailing list
[email protected]
http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users