instructions xyc really has optype xyn.

This commit is contained in:
Vítor Santos Costa 2008-08-30 23:00:50 +01:00
parent 2a84e259a2
commit b2d9eb7aac
7 changed files with 134 additions and 134 deletions

176
C/absmi.c
View File

@ -9652,14 +9652,14 @@ Yap_absmi(int inp)
ENDD(d0);
ENDOp();
Op(p_plus_y_vc, yxc);
Op(p_plus_y_vc, yxn);
BEGD(d0);
d0 = XREG(PREG->u.yxc.xi);
d0 = XREG(PREG->u.yxn.xi);
/* first check pt1 */
deref_head(d0, plus_y_vc_unk);
plus_y_vc_nvar:
{
Int d1 = PREG->u.yxc.c;
Int d1 = PREG->u.yxn.c;
if (IsIntTerm(d0)) {
d0 = MkIntegerTerm(IntOfTerm(d0) + d1);
}
@ -9672,8 +9672,8 @@ Yap_absmi(int inp)
}
}
BEGP(pt0);
pt0 = YREG + PREG->u.yxc.y;
PREG = NEXTOP(PREG, yxc);
pt0 = YREG + PREG->u.yxn.y;
PREG = NEXTOP(PREG, yxn);
#if defined(SBA) && defined(FROZEN_STACKS)
Bind_Local(pt0,d0);
#else
@ -9822,14 +9822,14 @@ Yap_absmi(int inp)
ENDD(d0);
ENDOp();
Op(p_minus_y_cv, yxc);
Op(p_minus_y_cv, yxn);
BEGD(d0);
d0 = XREG(PREG->u.yxc.xi);
d0 = XREG(PREG->u.yxn.xi);
/* first check pt1 */
deref_head(d0, minus_y_cv_unk);
minus_y_cv_nvar:
{
Int d1 = PREG->u.yxc.c;
Int d1 = PREG->u.yxn.c;
if (IsIntTerm(d0)) {
d0 = MkIntegerTerm(d1 - IntOfTerm(d0));
}
@ -9842,8 +9842,8 @@ Yap_absmi(int inp)
}
}
BEGP(pt0);
pt0 = YREG + PREG->u.yxc.y;
PREG = NEXTOP(PREG, yxc);
pt0 = YREG + PREG->u.yxn.y;
PREG = NEXTOP(PREG, yxn);
#if defined(SBA) && defined(FROZEN_STACKS)
Bind_Local(pt0,d0);
#else
@ -9992,14 +9992,14 @@ Yap_absmi(int inp)
ENDD(d0);
ENDOp();
Op(p_times_y_vc, yxc);
Op(p_times_y_vc, yxn);
BEGD(d0);
d0 = XREG(PREG->u.yxc.xi);
d0 = XREG(PREG->u.yxn.xi);
/* first check pt1 */
deref_head(d0, times_y_vc_unk);
times_y_vc_nvar:
{
Int d1 = PREG->u.yxc.c;
Int d1 = PREG->u.yxn.c;
if (IsIntTerm(d0)) {
d0 = times_int(IntOfTerm(d0), d1);
}
@ -10012,8 +10012,8 @@ Yap_absmi(int inp)
}
}
BEGP(pt0);
pt0 = YREG + PREG->u.yxc.y;
PREG = NEXTOP(PREG, yxc);
pt0 = YREG + PREG->u.yxn.y;
PREG = NEXTOP(PREG, yxn);
#if defined(SBA) && defined(FROZEN_STACKS)
Bind_Local(pt0,d0);
#else
@ -10215,14 +10215,14 @@ Yap_absmi(int inp)
ENDD(d0);
ENDOp();
Op(p_div_y_vc, yxc);
Op(p_div_y_vc, yxn);
BEGD(d0);
d0 = XREG(PREG->u.yxc.xi);
d0 = XREG(PREG->u.yxn.xi);
/* first check pt1 */
deref_head(d0, div_y_vc_unk);
div_y_vc_nvar:
{
Int d1 = PREG->u.yxc.c;
Int d1 = PREG->u.yxn.c;
if (IsIntTerm(d0)) {
d0 = MkIntTerm(IntOfTerm(d0)/d1);
}
@ -10235,8 +10235,8 @@ Yap_absmi(int inp)
}
}
BEGP(pt0);
pt0 = YREG + PREG->u.yxc.y;
PREG = NEXTOP(PREG, yxc);
pt0 = YREG + PREG->u.yxn.y;
PREG = NEXTOP(PREG, yxn);
#if defined(SBA) && defined(FROZEN_STACKS)
Bind_Local(pt0,d0);
#else
@ -10255,14 +10255,14 @@ Yap_absmi(int inp)
ENDD(d0);
ENDOp();
Op(p_div_y_cv, yxc);
Op(p_div_y_cv, yxn);
BEGD(d0);
d0 = XREG(PREG->u.yxc.xi);
d0 = XREG(PREG->u.yxn.xi);
/* first check pt1 */
deref_head(d0, div_y_cv_unk);
div_y_cv_nvar:
{
Int d1 = PREG->u.yxc.c;
Int d1 = PREG->u.yxn.c;
if (IsIntTerm(d0)) {
Int div = IntOfTerm(d0);
if (div == 0) {
@ -10282,8 +10282,8 @@ Yap_absmi(int inp)
}
}
BEGP(pt0);
pt0 = YREG + PREG->u.yxc.y;
PREG = NEXTOP(PREG, yxc);
pt0 = YREG + PREG->u.yxn.y;
PREG = NEXTOP(PREG, yxn);
#if defined(SBA) && defined(FROZEN_STACKS)
Bind_Local(pt0,d0);
#else
@ -10433,14 +10433,14 @@ Yap_absmi(int inp)
ENDD(d0);
ENDOp();
Op(p_and_y_vc, yxc);
Op(p_and_y_vc, yxn);
BEGD(d0);
d0 = XREG(PREG->u.yxc.xi);
d0 = XREG(PREG->u.yxn.xi);
/* first check pt1 */
deref_head(d0, and_y_vc_unk);
and_y_vc_nvar:
{
Int d1 = PREG->u.yxc.c;
Int d1 = PREG->u.yxn.c;
if (IsIntTerm(d0)) {
d0 = MkIntegerTerm(IntOfTerm(d0) & d1);
}
@ -10453,8 +10453,8 @@ Yap_absmi(int inp)
}
}
BEGP(pt0);
pt0 = YREG + PREG->u.yxc.y;
PREG = NEXTOP(PREG, yxc);
pt0 = YREG + PREG->u.yxn.y;
PREG = NEXTOP(PREG, yxn);
#if defined(SBA) && defined(FROZEN_STACKS)
Bind_Local(pt0,d0);
#else
@ -10603,14 +10603,14 @@ Yap_absmi(int inp)
ENDD(d0);
ENDOp();
Op(p_or_y_vc, yxc);
Op(p_or_y_vc, yxn);
BEGD(d0);
d0 = XREG(PREG->u.yxc.xi);
d0 = XREG(PREG->u.yxn.xi);
/* first check pt1 */
deref_head(d0, or_y_vc_unk);
or_y_vc_nvar:
{
Int d1 = PREG->u.yxc.c;
Int d1 = PREG->u.yxn.c;
if (IsIntTerm(d0)) {
d0 = MkIntegerTerm(IntOfTerm(d0) | d1);
}
@ -10623,8 +10623,8 @@ Yap_absmi(int inp)
}
}
BEGP(pt0);
pt0 = YREG + PREG->u.yxc.y;
PREG = NEXTOP(PREG, yxc);
pt0 = YREG + PREG->u.yxn.y;
PREG = NEXTOP(PREG, yxn);
#if defined(SBA) && defined(FROZEN_STACKS)
Bind_Local(pt0,d0);
#else
@ -10818,14 +10818,14 @@ Yap_absmi(int inp)
ENDD(d0);
ENDOp();
Op(p_sll_y_vc, yxc);
Op(p_sll_y_vc, yxn);
BEGD(d0);
d0 = XREG(PREG->u.yxc.xi);
d0 = XREG(PREG->u.yxn.xi);
/* first check pt1 */
deref_head(d0, sll_y_vc_unk);
sll_y_vc_nvar:
{
Int d1 = PREG->u.yxc.c;
Int d1 = PREG->u.yxn.c;
if (IsIntTerm(d0)) {
d0 = do_sll(IntOfTerm(d0), d1);
}
@ -10838,8 +10838,8 @@ Yap_absmi(int inp)
if (PREG == (yamop *)FAILCODE)
FAIL();
BEGP(pt0);
pt0 = YREG + PREG->u.yxc.y;
PREG = NEXTOP(PREG, yxc);
pt0 = YREG + PREG->u.yxn.y;
PREG = NEXTOP(PREG, yxn);
#if defined(SBA) && defined(FROZEN_STACKS)
Bind_Local(pt0,d0);
#else
@ -10859,14 +10859,14 @@ Yap_absmi(int inp)
ENDOp();
Op(p_sll_y_cv, yxc);
Op(p_sll_y_cv, yxn);
BEGD(d0);
d0 = XREG(PREG->u.yxc.xi);
d0 = XREG(PREG->u.yxn.xi);
/* first check pt1 */
deref_head(d0, sll_y_cv_unk);
sll_y_cv_nvar:
{
Int d1 = PREG->u.yxc.c;
Int d1 = PREG->u.yxn.c;
if (IsIntTerm(d0)) {
Int i2 = IntOfTerm(d0);
if (i2 < 0)
@ -10883,8 +10883,8 @@ Yap_absmi(int inp)
if (PREG == (yamop *)FAILCODE)
FAIL();
BEGP(pt0);
pt0 = YREG + PREG->u.yxc.y;
PREG = NEXTOP(PREG, yxc);
pt0 = YREG + PREG->u.yxn.y;
PREG = NEXTOP(PREG, yxn);
#if defined(SBA) && defined(FROZEN_STACKS)
Bind_Local(pt0,d0);
#else
@ -11078,14 +11078,14 @@ Yap_absmi(int inp)
ENDD(d0);
ENDOp();
Op(p_slr_y_vc, yxc);
Op(p_slr_y_vc, yxn);
BEGD(d0);
d0 = XREG(PREG->u.yxc.xi);
d0 = XREG(PREG->u.yxn.xi);
/* first check pt1 */
deref_head(d0, slr_y_vc_unk);
slr_y_vc_nvar:
{
Int d1 = PREG->u.yxc.c;
Int d1 = PREG->u.yxn.c;
if (IsIntTerm(d0)) {
d0 = MkIntTerm(IntOfTerm(d0) >> d1);
}
@ -11098,8 +11098,8 @@ Yap_absmi(int inp)
}
}
BEGP(pt0);
pt0 = YREG + PREG->u.yxc.y;
PREG = NEXTOP(PREG, yxc);
pt0 = YREG + PREG->u.yxn.y;
PREG = NEXTOP(PREG, yxn);
#if defined(SBA) && defined(FROZEN_STACKS)
Bind_Local(pt0,d0);
#else
@ -11117,14 +11117,14 @@ Yap_absmi(int inp)
ENDD(d0);
ENDOp();
Op(p_slr_y_cv, yxc);
Op(p_slr_y_cv, yxn);
BEGD(d0);
d0 = XREG(PREG->u.yxc.xi);
d0 = XREG(PREG->u.yxn.xi);
/* first check pt1 */
deref_head(d0, slr_y_cv_unk);
slr_y_cv_nvar:
{
Int d1 = PREG->u.yxc.c;
Int d1 = PREG->u.yxn.c;
if (IsIntTerm(d0)) {
Int i2 = IntOfTerm(d0);
if (i2 < 0)
@ -11141,8 +11141,8 @@ Yap_absmi(int inp)
if (PREG == (yamop *)FAILCODE)
FAIL();
BEGP(pt0);
pt0 = YREG + PREG->u.yxc.y;
PREG = NEXTOP(PREG, yxc);
pt0 = YREG + PREG->u.yxn.y;
PREG = NEXTOP(PREG, yxn);
#if defined(SBA) && defined(FROZEN_STACKS)
Bind_Local(pt0,d0);
#else
@ -12031,23 +12031,23 @@ Yap_absmi(int inp)
ENDD(d0);
ENDOp();
Op(p_arg_y_cv, yxc);
Op(p_arg_y_cv, yxn);
#ifdef LOW_LEVEL_TRACER
if (Yap_do_low_level_trace) {
CELL *Ho = H;
Term t = MkIntegerTerm(PREG->u.yxc.c);
Term t = MkIntegerTerm(PREG->u.yxn.c);
H[0] = t;
H[1] = XREG(PREG->u.yxc.xi);
H[1] = XREG(PREG->u.yxn.xi);
RESET_VARIABLE(H+2);
low_level_trace(enter_pred,RepPredProp(Yap_GetPredPropByFunc(Yap_MkFunctor(Yap_LookupAtom("arg"),3),0)),H);
H = Ho;
}
#endif /* LOW_LEVEL_TRACE */
BEGD(d0);
d0 = PREG->u.yxc.c;
d0 = PREG->u.yxn.c;
/* d0 now got the argument we want */
BEGD(d1);
d1 = XREG(PREG->u.yxc.xi);
d1 = XREG(PREG->u.yxn.xi);
deref_head(d1, arg_y_arg2_vc_unk);
arg_y_arg2_vc_nvar:
/* d1 now got the structure we want to fetch the argument
@ -12072,8 +12072,8 @@ Yap_absmi(int inp)
FAIL();
}
BEGP(pt1);
pt1 = YREG + PREG->u.yxc.y;
PREG = NEXTOP(PREG, yxc);
pt1 = YREG + PREG->u.yxn.y;
PREG = NEXTOP(PREG, yxn);
#if defined(SBA) && defined(FROZEN_STACKS)
Bind_Local(pt1,pt0[d0]);
#else
@ -12096,8 +12096,8 @@ Yap_absmi(int inp)
FAIL();
}
BEGP(pt1);
pt1 = YREG + PREG->u.yxc.y;
PREG = NEXTOP(PREG, yxc);
pt1 = YREG + PREG->u.yxn.y;
PREG = NEXTOP(PREG, yxn);
#if defined(SBA) && defined(FROZEN_STACKS)
Bind_Local(pt1,pt0[d0-1]);
#else
@ -12592,23 +12592,23 @@ Yap_absmi(int inp)
ENDD(d0);
ENDOp();
Op(p_func2s_y_cv, yxc);
Op(p_func2s_y_cv, yxn);
/* A1 is a variable */
restart_func2s_y_cv:
#ifdef LOW_LEVEL_TRACER
if (Yap_do_low_level_trace) {
RESET_VARIABLE(H);
H[1] = PREG->u.yxc.c;
H[2] = XREG(PREG->u.yxc.xi);
H[1] = PREG->u.yxn.c;
H[2] = XREG(PREG->u.yxn.xi);
low_level_trace(enter_pred,RepPredProp(Yap_GetPredPropByFunc(Yap_MkFunctor(Yap_LookupAtom("functor"),3),0)),H);
}
#endif /* LOW_LEVEL_TRACE */
/* We have to build the structure */
BEGD(d0);
d0 = PREG->u.yxc.c;
d0 = PREG->u.yxn.c;
/* we do, let's get the third argument */
BEGD(d1);
d1 = XREG(PREG->u.yxc.xi);
d1 = XREG(PREG->u.yxn.xi);
deref_head(d1, func2s_y_unk_cv);
func2s_y_nvar_cv:
/* Uuuff, the second and third argument are bound */
@ -12630,8 +12630,8 @@ Yap_absmi(int inp)
/* else if arity is 0 just pass d0 through */
/* Ding, ding, we made it */
BEGP(pt1);
pt1 = YREG + PREG->u.yxc.y;
PREG = NEXTOP(NEXTOP(NEXTOP(PREG, yxc),sbpp),l);
pt1 = YREG + PREG->u.yxn.y;
PREG = NEXTOP(NEXTOP(NEXTOP(PREG, yxn),sbpp),l);
#if defined(SBA) && defined(FROZEN_STACKS)
Bind_Local(pt1,d0);
#else
@ -12660,7 +12660,7 @@ Yap_absmi(int inp)
if (pt1+d1 > ENV || pt1+d1 > (CELL *)B) {
/* make sure we have something to show for our trouble */
saveregs();
if (!Yap_gcl((1+d1)*sizeof(CELL), 0, YREG, NEXTOP(NEXTOP(PREG,yxc),sbpp))) {
if (!Yap_gcl((1+d1)*sizeof(CELL), 0, YREG, NEXTOP(NEXTOP(PREG,yxn),sbpp))) {
Yap_Error(OUT_OF_STACK_ERROR,TermNil,Yap_ErrorMessage);
setregs();
JMPNext();
@ -12679,8 +12679,8 @@ Yap_absmi(int inp)
/* else if arity is 0 just pass d0 through */
/* Ding, ding, we made it */
BEGP(pt1);
pt1 = YREG + PREG->u.yxc.y;
PREG = NEXTOP(NEXTOP(NEXTOP(PREG, yxc),sbpp),l);
pt1 = YREG + PREG->u.yxn.y;
PREG = NEXTOP(NEXTOP(NEXTOP(PREG, yxn),sbpp),l);
#if defined(SBA) && defined(FROZEN_STACKS)
Bind_Local(pt1,d0);
#else
@ -12690,8 +12690,8 @@ Yap_absmi(int inp)
GONext();
} else if (d1 == 0) {
BEGP(pt1);
pt1 = YREG + PREG->u.yxc.y;
PREG = NEXTOP(NEXTOP(NEXTOP(PREG, yxc),sbpp),l);
pt1 = YREG + PREG->u.yxn.y;
PREG = NEXTOP(NEXTOP(NEXTOP(PREG, yxn),sbpp),l);
#if defined(SBA) && defined(FROZEN_STACKS)
Bind_Local(pt1,d0);
#else
@ -12718,7 +12718,7 @@ Yap_absmi(int inp)
ENDD(d0);
ENDOp();
Op(p_func2s_y_vc, yxc);
Op(p_func2s_y_vc, yxn);
/* A1 is a variable */
restart_func2s_y_vc:
#ifdef LOW_LEVEL_TRACER
@ -12726,9 +12726,9 @@ Yap_absmi(int inp)
Term ti;
CELL *hi = H;
ti = MkIntegerTerm((Int)(PREG->u.yxc.c));
ti = MkIntegerTerm((Int)(PREG->u.yxn.c));
RESET_VARIABLE(H);
H[1] = XREG(PREG->u.yxc.xi);
H[1] = XREG(PREG->u.yxn.xi);
H[2] = ti;
low_level_trace(enter_pred,RepPredProp(Yap_GetPredPropByFunc(Yap_MkFunctor(Yap_LookupAtom("functor"),3),0)),H);
H = hi;
@ -12736,11 +12736,11 @@ Yap_absmi(int inp)
#endif /* LOW_LEVEL_TRACE */
/* We have to build the structure */
BEGD(d0);
d0 = XREG(PREG->u.yxc.xi);
d0 = XREG(PREG->u.yxn.xi);
deref_head(d0, func2s_y_unk_vc);
func2s_y_nvar_vc:
BEGD(d1);
d1 = PREG->u.yxc.c;
d1 = PREG->u.yxn.c;
if (!IsAtomicTerm(d0)) {
saveregs();
Yap_Error(TYPE_ERROR_ATOM,d0,"functor/3");
@ -12757,8 +12757,8 @@ Yap_absmi(int inp)
/* else if arity is 0 just pass d0 through */
/* Ding, ding, we made it */
BEGP(pt1);
pt1 = YREG + PREG->u.yxc.y;
PREG = NEXTOP(NEXTOP(NEXTOP(PREG, yxc),sbpp),l);
pt1 = YREG + PREG->u.yxn.y;
PREG = NEXTOP(NEXTOP(NEXTOP(PREG, yxn),sbpp),l);
#if defined(SBA) && defined(FROZEN_STACKS)
Bind_Local(pt1,d0);
#else
@ -12769,8 +12769,8 @@ Yap_absmi(int inp)
}
if (d1 == 0) {
BEGP(pt1);
pt1 = YREG + PREG->u.yxc.y;
PREG = NEXTOP(NEXTOP(NEXTOP(PREG, yxc),sbpp),l);
pt1 = YREG + PREG->u.yxn.y;
PREG = NEXTOP(NEXTOP(NEXTOP(PREG, yxn),sbpp),l);
#if defined(SBA) && defined(FROZEN_STACKS)
Bind_Local(pt1,d0);
#else
@ -12804,7 +12804,7 @@ Yap_absmi(int inp)
if (pt1+d1 > ENV || pt1+d1 > (CELL *)B) {
/* make sure we have something to show for our trouble */
saveregs();
if (!Yap_gcl((1+d1)*sizeof(CELL), 0, YREG, NEXTOP(NEXTOP(PREG,yxc),sbpp))) {
if (!Yap_gcl((1+d1)*sizeof(CELL), 0, YREG, NEXTOP(NEXTOP(PREG,yxn),sbpp))) {
Yap_Error(OUT_OF_STACK_ERROR,TermNil,Yap_ErrorMessage);
setregs();
JMPNext();
@ -12823,8 +12823,8 @@ Yap_absmi(int inp)
/* else if arity is 0 just pass d0 through */
/* Ding, ding, we made it */
BEGP(pt1);
pt1 = YREG + PREG->u.yxc.y;
PREG = NEXTOP(NEXTOP(NEXTOP(PREG, yxc),sbpp),l);
pt1 = YREG + PREG->u.yxn.y;
PREG = NEXTOP(NEXTOP(NEXTOP(PREG, yxn),sbpp),l);
#if defined(SBA) && defined(FROZEN_STACKS)
Bind_Local(pt1,d0);
#else

View File

@ -2535,11 +2535,11 @@ a_f2(int var, cmp_op_info *cmp_info, yamop *code_p, int pass_no, struct intermed
code_p->opc = emit_op(_p_func2s_y_cv);
break;
}
code_p->u.yxc.y = emit_y(ve);
code_p->u.yxc.c = cmp_info->c_arg;
code_p->u.yxc.xi = cmp_info->x1_arg;
code_p->u.yxn.y = emit_y(ve);
code_p->u.yxn.c = cmp_info->c_arg;
code_p->u.yxn.xi = cmp_info->x1_arg;
}
GONEXT(yxc);
GONEXT(yxn);
break;
case TYPE_XC:
if (pass_no) {
@ -2589,11 +2589,11 @@ a_f2(int var, cmp_op_info *cmp_info, yamop *code_p, int pass_no, struct intermed
code_p->opc = emit_op(_p_func2s_y_vc);
break;
}
code_p->u.yxc.y = emit_y(ve);
code_p->u.yxc.c = cmp_info->c_arg;
code_p->u.yxc.xi = cmp_info->x1_arg;
code_p->u.yxn.y = emit_y(ve);
code_p->u.yxn.c = cmp_info->c_arg;
code_p->u.yxn.xi = cmp_info->x1_arg;
}
GONEXT(yxc);
GONEXT(yxn);
break;
}
} else {

View File

@ -4388,7 +4388,7 @@ ClauseInfoForCode(yamop *codeptr, CODEADDR *startp, CODEADDR *endp) {
clause_code = TRUE;
pc = NEXTOP(pc,yyx);
break;
/* instructions type yxc */
/* instructions type yxn */
case _p_plus_y_vc:
case _p_minus_y_cv:
case _p_times_y_vc:
@ -4400,19 +4400,19 @@ ClauseInfoForCode(yamop *codeptr, CODEADDR *startp, CODEADDR *endp) {
case _p_slr_y_vc:
case _p_func2s_y_vc:
clause_code = TRUE;
pc = NEXTOP(pc,yxc);
pc = NEXTOP(pc,yxn);
break;
/* instructions type yxc */
/* instructions type yxn */
case _p_sll_y_cv:
case _p_slr_y_cv:
case _p_arg_y_cv:
clause_code = TRUE;
pc = NEXTOP(pc,yxc);
pc = NEXTOP(pc,yxn);
break;
/* instructions type yxc */
/* instructions type yxn */
case _p_func2s_y_cv:
clause_code = TRUE;
pc = NEXTOP(pc,yxc);
pc = NEXTOP(pc,yxn);
break;
/* instructions type plxxs */
case _call_bfunc_xx:

View File

@ -1416,7 +1416,7 @@ has_cut(yamop *pc)
case _p_func2f_yy:
pc = NEXTOP(pc,yyx);
break;
/* instructions type yxc */
/* instructions type yxn */
case _p_plus_y_vc:
case _p_minus_y_cv:
case _p_times_y_vc:
@ -1427,17 +1427,17 @@ has_cut(yamop *pc)
case _p_sll_y_vc:
case _p_slr_y_vc:
case _p_func2s_y_vc:
pc = NEXTOP(pc,yxc);
pc = NEXTOP(pc,yxn);
break;
/* instructions type yxc */
/* instructions type yxn */
case _p_sll_y_cv:
case _p_slr_y_cv:
case _p_arg_y_cv:
pc = NEXTOP(pc,yxc);
pc = NEXTOP(pc,yxn);
break;
/* instructions type yxc */
/* instructions type yxn */
case _p_func2s_y_cv:
pc = NEXTOP(pc,yxc);
pc = NEXTOP(pc,yxn);
break;
/* instructions type plxxs */
case _call_bfunc_xx:
@ -2392,27 +2392,27 @@ add_info(ClauseDef *clause, UInt regno)
case _p_sll_y_vc:
case _p_slr_y_vc:
case _p_func2s_y_vc:
if (cl->u.yxc.y == ycopy) {
if (cl->u.yxn.y == ycopy) {
ycopy = 0; /* weird stuff, let's just reset ycopy */
if (nofregs == 0) {
clause->Tag = (CELL)NULL;
return;
}
}
cl = NEXTOP(cl,yxc);
cl = NEXTOP(cl,yxn);
break;
case _p_sll_y_cv:
case _p_slr_y_cv:
case _p_arg_y_cv:
case _p_func2s_y_cv:
if (cl->u.yxc.y == ycopy) {
if (cl->u.yxn.y == ycopy) {
ycopy = 0; /* weird stuff, let's just reset ycopy */
if (nofregs == 0) {
clause->Tag = (CELL)NULL;
return;
}
}
cl = NEXTOP(cl,yxc);
cl = NEXTOP(cl,yxn);
break;
case _lock_lu:
cl = NEXTOP(cl,p);

View File

@ -256,41 +256,41 @@
OPCODE(p_plus_vv ,xxx),
OPCODE(p_plus_vc ,xxn),
OPCODE(p_plus_y_vv ,yxx),
OPCODE(p_plus_y_vc ,yxc),
OPCODE(p_plus_y_vc ,yxn),
OPCODE(p_minus_vv ,xxx),
OPCODE(p_minus_cv ,xxn),
OPCODE(p_minus_y_vv ,yxx),
OPCODE(p_minus_y_cv ,yxc),
OPCODE(p_minus_y_cv ,yxn),
OPCODE(p_times_vv ,xxx),
OPCODE(p_times_vc ,xxn),
OPCODE(p_times_y_vv ,yxx),
OPCODE(p_times_y_vc ,yxc),
OPCODE(p_times_y_vc ,yxn),
OPCODE(p_div_vv ,xxx),
OPCODE(p_div_vc ,xxn),
OPCODE(p_div_cv ,xxn),
OPCODE(p_div_y_vv ,yxx),
OPCODE(p_div_y_vc ,yxc),
OPCODE(p_div_y_cv ,yxc),
OPCODE(p_div_y_vc ,yxn),
OPCODE(p_div_y_cv ,yxn),
OPCODE(p_and_vv ,xxx),
OPCODE(p_and_vc ,xxn),
OPCODE(p_and_y_vv ,yxx),
OPCODE(p_and_y_vc ,yxc),
OPCODE(p_and_y_vc ,yxn),
OPCODE(p_or_vv ,xxx),
OPCODE(p_or_vc ,xxn),
OPCODE(p_or_y_vv ,yxx),
OPCODE(p_or_y_vc ,yxc),
OPCODE(p_or_y_vc ,yxn),
OPCODE(p_sll_vv ,xxx),
OPCODE(p_sll_vc ,xxn),
OPCODE(p_sll_cv ,xxn),
OPCODE(p_sll_y_vv ,yxx),
OPCODE(p_sll_y_vc ,yxc),
OPCODE(p_sll_y_cv ,yxc),
OPCODE(p_sll_y_vc ,yxn),
OPCODE(p_sll_y_cv ,yxn),
OPCODE(p_slr_vv ,xxx),
OPCODE(p_slr_vc ,xxn),
OPCODE(p_slr_cv ,xxn),
OPCODE(p_slr_y_vv ,yxx),
OPCODE(p_slr_y_vc ,yxc),
OPCODE(p_slr_y_cv ,yxc),
OPCODE(p_slr_y_vc ,yxn),
OPCODE(p_slr_y_cv ,yxn),
OPCODE(call_bfunc_xx ,plxxs),
OPCODE(call_bfunc_yx ,plxys),
OPCODE(call_bfunc_xy ,plxys),
@ -301,13 +301,13 @@
OPCODE(p_arg_vv ,xxx),
OPCODE(p_arg_cv ,xxn),
OPCODE(p_arg_y_vv ,yxx),
OPCODE(p_arg_y_cv ,yxc),
OPCODE(p_arg_y_cv ,yxn),
OPCODE(p_func2s_vv ,xxx),
OPCODE(p_func2s_cv ,xxn),
OPCODE(p_func2s_vc ,xxn),
OPCODE(p_func2s_y_vv ,yxx),
OPCODE(p_func2s_y_cv ,yxc),
OPCODE(p_func2s_y_vc ,yxc),
OPCODE(p_func2s_y_cv ,yxn),
OPCODE(p_func2s_y_vc ,yxn),
OPCODE(p_func2f_xx ,xxx),
OPCODE(p_func2f_xy ,xxy),
OPCODE(p_func2f_yx ,yxx),

View File

@ -630,11 +630,11 @@ typedef struct yami {
CELL next;
} yyy;
struct {
wamreg xi;
wamreg xi;
yslot y;
Int c;
Int c;
CELL next;
} yxc;
} yxn;
} u;
} yamop;

View File

@ -670,7 +670,7 @@ restore_opcodes(yamop *pc)
pc->u.yx.x = XAdjust(pc->u.yx.x);
pc = NEXTOP(pc,yx);
break;
/* instructions type yxc */
/* instructions type yxn */
case _p_and_y_vc:
case _p_arg_y_cv:
case _p_div_y_cv:
@ -685,10 +685,10 @@ restore_opcodes(yamop *pc)
case _p_slr_y_cv:
case _p_slr_y_vc:
case _p_times_y_vc:
pc->u.yxc.xi = YAdjust(pc->u.yxc.xi);
pc->u.yxc.y = XAdjust(pc->u.yxc.y);
pc->u.yxc.c = ConstantTermAdjust(pc->u.yxc.c);
pc = NEXTOP(pc,yxc);
pc->u.yxn.xi = YAdjust(pc->u.yxn.xi);
pc->u.yxn.y = XAdjust(pc->u.yxn.y);
pc->u.yxn.c = IntegerAdjust(pc->u.yxn.c);
pc = NEXTOP(pc,yxn);
break;
/* instructions type yxx */
case _p_and_y_vv: