summaryrefslogtreecommitdiff
path: root/emulators/simh/files/patch-Ibm1130_ibm1130__cpu.c
diff options
context:
space:
mode:
authorMatthew Seaman <matthew@FreeBSD.org>2017-01-03 14:00:47 +0000
committerMatthew Seaman <matthew@FreeBSD.org>2017-01-03 14:00:47 +0000
commit7c084f620e6dcec68140cd4df90f64870cae813b (patch)
tree0752b4ea3e6f7dda7f1a2ab4235d6bffb9455613 /emulators/simh/files/patch-Ibm1130_ibm1130__cpu.c
parentUpdate to 7.1.0. Changes include: (diff)
Fixes to allow building on 12-CURRENT
- fix build failures in i386 and amd64 due to compiler changes - fix numerous compilation warnings and logical errors that may trap in the future - convert all distribution files from DOS format to ease future changes - convert legacy patch file to new naming convention PR: 214990 Submitted by: bob@eager.cx (maintainer)
Diffstat (limited to 'emulators/simh/files/patch-Ibm1130_ibm1130__cpu.c')
-rw-r--r--emulators/simh/files/patch-Ibm1130_ibm1130__cpu.c33
1 files changed, 33 insertions, 0 deletions
diff --git a/emulators/simh/files/patch-Ibm1130_ibm1130__cpu.c b/emulators/simh/files/patch-Ibm1130_ibm1130__cpu.c
new file mode 100644
index 000000000000..d7df01b85bc1
--- /dev/null
+++ b/emulators/simh/files/patch-Ibm1130_ibm1130__cpu.c
@@ -0,0 +1,33 @@
+--- Ibm1130/ibm1130_cpu.c.orig 2016-12-01 22:43:42 UTC
++++ Ibm1130/ibm1130_cpu.c
+@@ -768,7 +768,7 @@ t_stat sim_instr (void)
+ CCC--;
+ }
+ C = (CCC != 0);
+- WriteIndex(TAG, ReadIndex(TAG) & 0xFF00 | CCC); /* put 6 bits back into low byte of index register */
++ WriteIndex(TAG, (ReadIndex(TAG) & 0xFF00) | CCC); /* put 6 bits back into low byte of index register */
+ break;
+ }
+ /* if TAG == 0, fall through and treat like normal shift SLT */
+@@ -814,8 +814,8 @@ t_stat sim_instr (void)
+ while (CCC > 0) {
+ xbit = (ACC & 0x0001) << 15;
+ abit = (ACC & 0x8000);
+- ACC = (ACC >> 1) & 0x7FFF | abit;
+- EXT = (EXT >> 1) & 0x7FFF | xbit;
++ ACC = ((ACC >> 1) & 0x7FFF) | abit;
++ EXT = ((EXT >> 1) & 0x7FFF) | xbit;
+ CCC--;
+ }
+ break;
+@@ -824,8 +824,8 @@ t_stat sim_instr (void)
+ while (CCC > 0) {
+ abit = (EXT & 0x0001) << 15;
+ xbit = (ACC & 0x0001) << 15;
+- ACC = (ACC >> 1) & 0x7FFF | abit;
+- EXT = (EXT >> 1) & 0x7FFF | xbit;
++ ACC = ((ACC >> 1) & 0x7FFF) | abit;
++ EXT = ((EXT >> 1) & 0x7FFF) | xbit;
+ CCC--;
+ }
+ break;