On Wed, Aug 10, 2011 at 6:01 AM, Mark Cave-Ayland < mark.cave-ayland@siriusit.co.uk> wrote:
On 09/08/11 22:55, William Hahne wrote:
This is a forth primitive that is required by BootX. It just fills some
specified memory address and length with longs.
Index: kernel/forth.c ==============================**==============================**======= --- kernel/forth.c (revision 1041) +++ kernel/forth.c (working copy) @@ -1610,6 +1616,20 @@ memset(src, value, count); } +/*
- filll ( addr len byte -- )
- */
+static void filll(void) +{
- ucell value = POP();
- ucell count = POP();
- ucell *dest = (ucell *)cell2pointer(POP());
- int i;
- for (i = 0; i <= count / 4; i++) {
- dest[i] = value;
- }
+} /*
- unaligned-w@ ( addr -- w )
@@ -1963,4 +1983,5 @@ do_encode_file, /* $encode-file */ do_debug_xt, /* (debug */ do_debug_off, /* (debug-off) */
- filll /* filll */
}; Index: kernel/bootstrap.c ==============================**==============================**======= --- kernel/bootstrap.c (revision 1041) +++ kernel/bootstrap.c (working copy) @@ -89,7 +89,7 @@ "here", "here!", "dobranch", "do?branch", "unaligned-w@", "unaligned-w!", "unaligned-l@", "unaligned-l!", "ioc@", "iow@", "iol@", "ioc!", "iow!", "iol!", "i", "j", "call", "sys-debug",
- "$include", "$encode-file", "(debug", "(debug-off)"
- "$include", "$encode-file", "(debug", "(debug-off)", "filll"
}; /*
This looks reasonably straightforward - again, can you add a reference to the documentation for this word as part of the commit message?
I wish I could. I had to do reverse engineer it from Apple's OF implementation. I don't believe it is an official OF word.
ATB,
Mark.
-- Mark Cave-Ayland - Senior Technical Architect PostgreSQL - PostGIS Sirius Corporation plc - control through freedom http://www.siriusit.co.uk t: +44 870 608 0063
Sirius Labs: http://www.siriusit.co.uk/labs
-- OpenBIOS http://openbios.org/ Mailinglist: http://lists.openbios.org/**mailman/listinfohttp://lists.openbios.org/mailman/listinfo Free your System - May the Forth be with you
William Hahne