+ ebp->hasFcall = 1;
+ if (currFunc)
+ FUNC_HASFCALL (currFunc->type) = 1;
+
+ if(TARGET_IS_PIC16 || TARGET_IS_PIC) {
+ /* normally these functions aren't marked external, so we can use their
+ * _extern field to marked as already added to symbol table */
+
+ if(!SPEC_EXTR(func->etype)) {
+ memmap *seg = SPEC_OCLS(OP_SYMBOL(IC_LEFT(newic))->etype);
+
+ SPEC_EXTR(func->etype) = 1;
+ seg = SPEC_OCLS( func->etype );
+ addSet(&seg->syms, func);
+ }
+ }
+
+ addiCodeToeBBlock (ebp, newic, ip);
+ newic->filename = filename;
+ newic->lineno = lineno;
+}
+
+/*--------------------------------------------------------------------------*/
+/* cnvFromFixed16x16Cast - converts casts from fixed16x16 to function calls */
+/*--------------------------------------------------------------------------*/
+static void
+cnvFromFixed16x16Cast (iCode * ic, eBBlock * ebp)
+{
+ iCode *ip, *newic;
+ symbol *func = NULL;
+ sym_link *type = operandType (IC_LEFT (ic));
+ char *filename = ic->filename;
+ int lineno = ic->lineno;
+ int bwd, su;
+ int bytesPushed=0;
+
+ ip = ic->next;
+ /* remove it from the iCode */
+ remiCodeFromeBBlock (ebp, ic);
+
+ /* depending on the type */
+ for (bwd = 0; bwd < 3; bwd++)
+ {
+ for (su = 0; su < 2; su++)
+ {
+ if (compareType (type, __multypes[bwd][su]) == 1)
+ {
+ func = __fp16x16conv[1][bwd][su];
+ goto found;
+ }
+ }
+ }
+
+ if (compareType (type, floatType) == 1)
+ {
+ func = __fp16x16conv[1][3][0];
+ goto found;
+ }
+
+ assert (0);
+found:
+
+ /* if float support routines NOT compiled as reentrant */
+ if (!options.float_rent)
+ {
+ /* first one */
+ if (IS_REGPARM (FUNC_ARGS(func->type)->etype)) {
+ newic = newiCode (SEND, IC_RIGHT (ic), NULL);
+ newic->argreg = SPEC_ARGREG(FUNC_ARGS(func->type)->etype);
+ }
+ else
+ {
+ newic = newiCode ('=', NULL, IC_RIGHT (ic));
+ IC_RESULT (newic) = operandFromValue (FUNC_ARGS(func->type));
+ }
+ addiCodeToeBBlock (ebp, newic, ip);
+ newic->filename = filename;
+ newic->lineno = lineno;
+ }
+ else
+ {
+
+ /* push the left */
+ if (IS_REGPARM (FUNC_ARGS(func->type)->etype)) {
+ newic = newiCode (SEND, IC_RIGHT (ic), NULL);
+ newic->argreg = SPEC_ARGREG(FUNC_ARGS(func->type)->etype);
+ }
+ else
+ {
+ newic = newiCode (IPUSH, IC_RIGHT (ic), NULL);
+ newic->parmPush = 1;
+ bytesPushed += getSize(operandType(IC_RIGHT(ic)));
+ }
+ addiCodeToeBBlock (ebp, newic, ip);
+ newic->filename = filename;
+ newic->lineno = lineno;
+ }
+
+ /* make the call */
+ newic = newiCode (CALL, operandFromSymbol (func), NULL);
+ IC_RESULT (newic) = IC_RESULT (ic);
+ newic->parmBytes+=bytesPushed;
+ ebp->hasFcall = 1;
+ if (currFunc)
+ FUNC_HASFCALL (currFunc->type) = 1;
+
+ if(TARGET_IS_PIC16 || TARGET_IS_PIC) {
+ /* normally these functions aren't marked external, so we can use their
+ * _extern field to marked as already added to symbol table */
+
+ if(!SPEC_EXTR(func->etype)) {
+ memmap *seg = SPEC_OCLS(OP_SYMBOL(IC_LEFT(newic))->etype);