Disk Swapper's Elbow 磁盘交换者的肘部

作者: 史蒂夫·卡普斯 日期: 1984年1月 人物: 史蒂夫·卡普斯 主题: 软件设计、技术、错误 概要: 关于苹果第一代Macintosh的开发以及制造它的人的轶事: 最后一刻的错误会导致一些问题 , 磁盘交换者的肘部 Disk Swapper’s Elbow

A long time ago, people who used early Mac computers often got a problem called “Disk Swapper’s Elbow”. This was because of the way they had to copy files from one floppy disk to another. Floppy disks were small and only held 400KB of information. The computers didn’t have much memory, only 128KB. And they only had one floppy drive, which meant they had to take out the old disk, put in a new blank one, make the new disk ready, move the old disk to the new one, and then the computer would copy the files a little at a time. This process was called “disk swapping”. It was a slow and clumsy way to make a backup copy of a disk.

很久以前,使用早期 Mac 电脑的人经常遇到一个叫做“Disk Swapper's Elbow”的问题。
这是因为他们必须将文件从一张软盘复制到另一张软盘。软盘很小,只能保存 400KB 的信息。电脑的内存不多,只有128KB。
而且他们只有一个软盘驱动器,这意味着他们必须取出旧磁盘,放入一张新的空白磁盘,准备好新磁盘,将旧磁盘移动到新磁盘上,然后计算机将文件复制到新磁盘上。一次一点。
这个过程称为“磁盘交换”。这是一种制作磁盘备份副本的缓慢且笨拙的方法。

A normal program on a 128K Mac had about 85K of space left after the computer’s own parts took up the rest. This space was mostly used to show pictures on the screen. To move a 400K disk, it would take around 5 or 6 times switching between the disk and the computer’s memory. Five times swapping back and forth was already annoying, but sometimes it would take much longer, up to 20 times or more.

128K Mac 上的正常程序在计算机本身的部件占用了剩余空间后还剩下大约 85K 的空间。这个空间主要用来在屏幕上显示图片。
要移动一个 400K 的磁盘,大约需要在磁盘和计算机内存之间切换 5 到 6 次。
来回交换五次已经很烦人了,但有时会需要更长的时间,最多可达二十次甚至更多。

You would start copying files from a disk, hoping it would finish after 5 tries. But if the computer didn’t finish after 5 tries, you would be worried and think that maybe you made a mistake with the count. On the 6th try, you would hope the computer would finally finish. But if it didn’t, you would start getting angry and wondering why it took so long. By the 7th try, you would be really frustrated and think about buying a second, separate drive to help with the copying.

您将开始从磁盘复制文件,希望在 5 次尝试后完成。但如果计算机在尝试了 5 次后仍未完成,你就会担心并认为可能是你计数错误。
在第六次尝试时,您会希望计算机最终完成。但如果没有,你会开始生气并想知道为什么花了这么长时间。
到第七次尝试时,您会感到非常沮丧,并考虑购买第二个单独的驱动器来帮助复制。

Even though the Finder, which is made of code, was very small and used a lot of extra memory, there was still not enough room to copy files easily. So, I had to break the code into two parts: the basic part needed for copying and the rest. I then had to carefully get rid of any extra data stored in memory, load the basic copying part, and rearrange the rest of the memory. Usually, this worked and I had enough free memory to copy files without problems. But sometimes, the system would unexpectedly load the whole Finder code, make the free memory messy, and cause problems with copying files again.

尽管由代码组成的Finder非常小并且占用了大量额外内存,但仍然没有足够的空间来轻松复制文件。
因此,我必须将代码分成两部分:复制所需的基本部分和其余部分。然后,我必须小心地删除内存中存储的任何额外数据,加载基本复制部分,并重新排列内存的其余部分。通常,这很有效,并且我有足够的可用内存来毫无问题地复制文件。
但有时,系统会意外加载整个 Finder 代码,使可用内存变得混乱,并导致再次复制文件时出现问题。

It took me a long time to understand what was happening. We had not seen this problem much during testing. There were a few reports of the issue, but they were hard to repeat. The reports said things like: “I copied a disk and it took a long time. The second time it was okay.” The reason we couldn’t repeat the problem was because everyone who tested it was very good at using the computer mouse, and we usually skipped a small mistake that was necessary to make the problem happen.

我花了很长时间才明白发生了什么。我们在测试过程中并没有太多看到这个问题。
关于这个问题有一些报道,但很难重复。
报道说:“我复制了一个磁盘,花了很长时间。第二次就没事了。”
我们无法重复该问题的原因是因为测试它的每个人都非常擅长使用计算机鼠标,并且我们通常会跳过导致问题发生所必需的小错误。

When people first start using a computer mouse, one of the hardest things to do is to drag something. It’s tricky to click down, move the mouse while keeping the button held down, and then let go. New computer users often accidentally let go of the button while dragging. This can cause problems, like accidentally moving an icon to the wrong place. In reality, we rarely thought about this mistake because we would quickly pick up the icon and keep moving it. But it turns out that if we did this with a disk icon during a disk copy, we would get a computer bug.

当人们第一次开始使用电脑鼠标时,最困难的事情之一就是拖动某些东西。按下鼠标,按住按钮的同时移动鼠标,然后松开,这很棘手。
计算机新用户在拖动时经常会不小心松开按钮。
这可能会导致问题,例如意外地将图标移动到错误的位置。
事实上,我们很少考虑这个错误,因为我们会很快拿起图标并继续移动它。
但事实证明,如果我们在磁盘复制期间使用磁盘图标执行此操作,则会出现计算机错误。

The Finder is a program that helps you organize your files and folders on your computer. It remembers where you put icons on your desktop. Even if you only pause for a second, the Finder writes down the icon’s location. This information is stored in a big part of the Finder’s code. When a problem happened, the Finder would try to update the information it had stored. But then it would realize that it had not saved the icon’s location correctly. It would try to fix this mistake, and that’s when the problem occurred…

Finder 是一个帮助您组织计算机上的文件和文件夹的程序。
它会记住您在桌面上放置图标的位置。即使您只暂停一秒钟,Finder 也会记下图标的位置。
此信息存储在 Finder 代码的很大一部分中。
当出现问题时,Finder 会尝试更新其存储的信息。
但随后它会意识到它没有正确保存图标的位置。
它会尝试修复这个错误,而这就是问题发生的时候......

I found a mistake in the code at 2AM, just when we were finishing our final work on the disks. This mistake was caused by a fix for a much bigger mistake, so it was actually better to have this one!

凌晨 2 点,当我们完成磁盘上的最后工作时,我发现了代码中的一个错误。
这个错误是由一个更大的错误的修复引起的,所以实际上最好有这个!
目录