lots of small things
This commit is contained in:
@@ -5,10 +5,11 @@
|
||||
* (C) Cristina Cifuentes
|
||||
*/
|
||||
#pragma once
|
||||
static const int operandSize=20;
|
||||
#include <cstring>
|
||||
#include <list>
|
||||
#include "Enums.h"
|
||||
#include "icode.h"
|
||||
|
||||
static const int operandSize=20;
|
||||
/* The following definitions and types define the Conditional Expression
|
||||
* attributed syntax tree, as defined by the following EBNF:
|
||||
CondExp ::= CondTerm AND CondTerm | CondTerm
|
||||
@@ -17,7 +18,6 @@ static const int operandSize=20;
|
||||
Identifier ::= globalVar | register | localVar | parameter | constant
|
||||
op ::= <= | < | = | != | > | >=
|
||||
*/
|
||||
|
||||
/* High-level BOOLEAN conditions for iJB..iJNS icodes */
|
||||
static const condOp condOpJCond[12] = {LESS, LESS_EQUAL, GREATER_EQUAL, GREATER,
|
||||
EQUAL, NOT_EQUAL, LESS, GREATER_EQUAL,
|
||||
@@ -28,10 +28,9 @@ struct STKFRAME;
|
||||
struct LOCAL_ID;
|
||||
struct ICODE;
|
||||
struct ID;
|
||||
typedef std::list<ICODE>::iterator iICODE;
|
||||
#include "IdentType.h"
|
||||
//enum opLoc;
|
||||
//enum hlFirst;
|
||||
//enum operDu;
|
||||
|
||||
/* Expression data type */
|
||||
struct COND_EXPR
|
||||
{
|
||||
@@ -47,16 +46,16 @@ struct COND_EXPR
|
||||
IDENTTYPE ident; /* for IDENTIFIER */
|
||||
} expr;
|
||||
public:
|
||||
static COND_EXPR *idGlob(int16 segValue, int16 off);
|
||||
static COND_EXPR *idRegIdx(Int idx, regType reg_type);
|
||||
static COND_EXPR *idKte(dword kte, byte size);
|
||||
static COND_EXPR *idLoc(Int off, LOCAL_ID *localId);
|
||||
static COND_EXPR *idReg(byte regi, flags32 icodeFlg, LOCAL_ID *locsym);
|
||||
static COND_EXPR *idLongIdx(Int idx);
|
||||
static COND_EXPR *idOther(byte seg, byte regi, int16 off);
|
||||
static COND_EXPR *idParam(Int off, const STKFRAME *argSymtab);
|
||||
static COND_EXPR *idGlob(int16_t segValue, int16_t off);
|
||||
static COND_EXPR *idRegIdx(int idx, regType reg_type);
|
||||
static COND_EXPR *idKte(uint32_t kte, uint8_t size);
|
||||
static COND_EXPR *idLoc(int off, LOCAL_ID *localId);
|
||||
static COND_EXPR *idReg(uint8_t regi, uint32_t icodeFlg, LOCAL_ID *locsym);
|
||||
static COND_EXPR *idLongIdx(int idx);
|
||||
static COND_EXPR *idOther(uint8_t seg, uint8_t regi, int16_t off);
|
||||
static COND_EXPR *idParam(int off, const STKFRAME *argSymtab);
|
||||
static COND_EXPR *unary(condNodeType t, COND_EXPR *sub_expr);
|
||||
static COND_EXPR *idLong(LOCAL_ID *localId, opLoc sd, iICODE pIcode, hlFirst f, iICODE ix, operDu du, Int off);
|
||||
static COND_EXPR *idLong(LOCAL_ID *localId, opLoc sd, iICODE pIcode, hlFirst f, iICODE ix, operDu du, int off);
|
||||
static COND_EXPR *idFunc(Function *pproc, STKFRAME *args);
|
||||
static COND_EXPR *idID(const ID *retVal, LOCAL_ID *locsym, iICODE ix_);
|
||||
static COND_EXPR *id(const ICODE &pIcode, opLoc sd, Function *pProc, iICODE ix_, ICODE &duIcode, operDu du);
|
||||
@@ -78,12 +77,4 @@ public:
|
||||
COND_EXPR *inverse(); // return new COND_EXPR that is invarse of this
|
||||
};
|
||||
|
||||
/* Sequence of conditional expression data type */
|
||||
/*** NOTE: not used at present ****/
|
||||
//struct SEQ_COND_EXPR
|
||||
//{
|
||||
// COND_EXPR *expr;
|
||||
// struct _condExpSeq *neccxt;
|
||||
//};
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user