示例#1
0
def match_type(a,b):
    """Match operand type against operand type rule"""
    b = (b.type, b.sign, b.size, b.source, b.indirection)
    #print a,b
    for aa,bb in zip(a,b):
        if not bb in wraplist(aa):
            return False
    return True
示例#2
0
文件: Assembler.py 项目: wokaka/cedp
def match_type(a, b):
    """Match operand type against operand type rule"""
    b = (b.type, b.sign, b.size, b.source, b.indirection)
    #print a,b
    for aa, bb in zip(a, b):
        if not bb in wraplist(aa):
            return False
    return True
示例#3
0
def f_oreg(width=32):
    return (OP_TYPE_FLOAT, OP_SIGN_NONE, width, [_regw[x] for x in wraplist(width)] + [_regwo[x] for x in wraplist(width)], OP_INDIRECTION_NONE)
示例#4
0
def i_oreg(sign, width=[16,32]):
    return (OP_TYPE_INT, sign, width, [_regw[x] for x in wraplist(width)] + [_regwo[x] for x in wraplist(width)], OP_INDIRECTION_NONE)
示例#5
0
def psize_sign(x):
    return [(BF_PSIZE_SIGN, y, IS_SIGNED) for y in wraplist(x)]
示例#6
0
def psize_width_s(x):
    return [(BF_OPER1_H, y, IS_32BIT) for y in wraplist(x)]
示例#7
0
def psize_width(x):
    return [(BF_PSIZE_WIDTH, y, IS_32BIT) for y in wraplist(x)]
示例#8
0
文件: AsmRules.py 项目: wokaka/cedp
def f_oreg(width=32):
    return (OP_TYPE_FLOAT, OP_SIGN_NONE, width, [_regw[x] for x in wraplist(width)] + [_regwo[x] for x in wraplist(width)], OP_INDIRECTION_NONE)
示例#9
0
文件: AsmRules.py 项目: wokaka/cedp
def i_oreg(sign, width=[16,32]):
    return (OP_TYPE_INT, sign, width, [_regw[x] for x in wraplist(width)] + [_regwo[x] for x in wraplist(width)], OP_INDIRECTION_NONE)
示例#10
0
文件: AsmRules.py 项目: wokaka/cedp
def psize_sign(x):
    return [(BF_PSIZE_SIGN, y, IS_SIGNED) for y in wraplist(x)]
示例#11
0
文件: AsmRules.py 项目: wokaka/cedp
def psize_width_s(x):
    return [(BF_OPER1_H, y, IS_32BIT) for y in wraplist(x)]
示例#12
0
文件: AsmRules.py 项目: wokaka/cedp
def psize_width(x):
    return [(BF_PSIZE_WIDTH, y, IS_32BIT) for y in wraplist(x)]