[Mit-cadr-cvs] r368 - trunk/emulator/usim
ggilley at common-lisp.net
ggilley at common-lisp.net
Wed Nov 28 07:18:19 UTC 2012
Author: ggilley
Date: Tue Nov 27 23:18:19 2012
New Revision: 368
Log:
get compiling on ubuntu
Modified:
trunk/emulator/usim/decode.c
Modified: trunk/emulator/usim/decode.c
==============================================================================
--- trunk/emulator/usim/decode.c Tue Nov 27 23:14:31 2012 (r367)
+++ trunk/emulator/usim/decode.c Tue Nov 27 23:18:19 2012 (r368)
@@ -1164,8 +1164,9 @@
}
else if (reg == 4)
{
- static dispatch_once_t pred;
static unsigned int constants_area;
+#if defined(OSX)
+ static dispatch_once_t pred;
dispatch_once(&pred, ^{
for (int i = 0; i < 1024; i++) {
@@ -1180,6 +1181,27 @@
}
}
});
+#else // !defined(OSX)
+ static int done = 0;
+
+ if (!done)
+ {
+ int i;
+
+ for (i = 0; i < 1024; i++) {
+ char *sym;
+ extern unsigned int a_memory[1024];
+
+ sym = sym_find_by_type_val(1, 4/*A-MEM*/, i);
+ if (sym && strcasecmp(sym, "A-V-CONSTANTS-AREA") == 0) {
+ read_mem(a_memory[i], &constants_area);
+ printf("found %o %-40s %o\n",
+ i, sym, a_memory[i]);
+ }
+ }
+ done = 1;
+ }
+#endif // defined(OSX)
unsigned int value;
More information about the mit-cadr-cvs
mailing list