}
}
- if (bit_count)
+ if (options.useXstack || bit_count)
{
saveRegisters (setFirstItem (sendSet));
+ }
+
+ if (bit_count)
+ {
emitcode ("mov", "bits,b");
}
{
// Aha, it is a pointer, just in disguise.
rname = aopGet (left, 0, FALSE, FALSE);
- if (*rname != '@')
+ if (strcmp (rname, "a") == 0)
+ {
+ // It's in pdata or on xstack
+ rname = AOP (left)->aopu.aop_ptr->name;
+ emitcode ("mov", "%s,a", rname);
+ }
+ else if (*rname != '@')
{
fprintf(stderr, "probable internal error: unexpected rname '%s' @ %s:%d\n",
rname, __FILE__, __LINE__);
{
// Aha, it is a pointer, just in disguise.
rname = aopGet (result, 0, FALSE, FALSE);
- if (*rname != '@')
+ if (strcmp (rname, "a") == 0)
+ {
+ // It's in pdata or on xstack
+ rname = AOP (result)->aopu.aop_ptr->name;
+ emitcode ("mov", "%s,a", rname);
+ }
+ else if (*rname != '@')
{
fprintf(stderr, "probable internal error: unexpected rname @ %s:%d\n",
__FILE__, __LINE__);
release:
freeAsmop (IC_RESULT (ic), NULL, ic, TRUE);
-
}
/*-----------------------------------------------------------------*/
/* if the result is of type pointer */
if (IS_PTR (ctype))
{
-
int p_type;
sym_link *type = operandType (right);
sym_link *etype = getSpec (type);