[parisc-linux] fic problem

FARINATI,LEANDRO (HP-Brazil,ex1) leandro.farinati@hp.com
Fri, 13 Dec 2002 04:27:13 -0800


Hi people,

	I have an error with the use of fic asm instruction(see piece code
below). 
            I'm ask you if you have a tip do help me to solve this problem.

       buf = (char *)malloc(4096);
        if(!buf)
        {
                printf("\n malloc error!");
                return(1);
        }


        /* copy instr stream(s) to new page */
        start = (unsigned int *)&(label of an asm code);
        spot = (unsigned int *)buf;
        end = (unsigned int *)&(label of an asm code);

        while(start <= end)
        {
                *spot = *start;
                __asm__ __volatile__("fdc (%0)" :: "r" (spot) );
                __asm__ __volatile__("sync" ::);
                __asm__ __volatile__("fic (%0)" :: "r" (spot) );
(segmentation fault in this line)
                __asm__ __volatile__("sync" ::);
                spot++;
                start++;
        }

Thanks in advance,

-----------------------------------------------------------------------
              Leandro Marcondes Farinati
                    Software Developer

*   leandro.farinati@hp.com