icompare

 compares counted string in RAM with counted string in flash

Stackeffects

( addr-ram addr-flash -- f )
R( -- )

Definition

: icompare
   over    @    over    i@ (literal) $ff7f ; mask out immediate bit   and    <>
(?branch) PFA_ICOMPARE1
   drop    drop    0    exit
PFA_ICOMPARE1:
   over    c@    2/    0    (?do)
PFA_ICOMPARE2:
   1+    swap    cell+    over    i@    over    @    <>
(?branch) PFA_ICOMPARE4
   unloop    drop    drop    0    exit
PFA_ICOMPARE4:
   swap
(loop) PFA_ICOMPARE2

PFA_ICOMPARE3:
   drop    drop (literal) -1   exit
;

Used by

find