def _gf2mulxmod(a,m):
    """
    Computes ``a * x mod m``.
    *NOTE*: Does *not* check whether `a` is smaller in degree than `m`.

    Parameters
    ----------
    a, m : integer
        Polynomial coefficient bit vectors.
        Polynomial `a` should be smaller degree than `m`.

    Returns
    -------
    c : integer
        Polynomial coefficient bit vector of ``c = a * x mod m``.    
    """
    c = a << 1
    c2 = c^m
    if c2 < c:
        c = c2
    return c