CompuServe Thread

#Enforcer Hits

5 messages in this thread
#98017From: Paul IdolMay 1, 1993 8:15 PM
What exactly are "Enforcer Hits"? People keep referring to them… Paul
#98070From: Robert WilcoxMay 2, 1993 11:20 AM
Enforcer is a debugging tool which runs in the background which detects illegal memory accesses. A common type of illegal memory access involves location zero. This can occur from trying to use a NULL pointer and will cause a 'hit' at which point Enforcer provides a dump of information which can be used to locate the problem. There are even a few utilities which can digest this information to point to a line of source code which generates the problem. You may also be able to single step a program in a debugger and find the line in which the hit occurs. Programs which generate enforcer hits may cause immediate (or deferred) system crashes when run without enforcer.
#98081From: Paul IdolMay 2, 1993 2:51 PM
Thanks – that clears up the mystery. I thought it was some hidden aspect of the OS or something. Paul
#98156From: Dale LarsonMay 3, 1993 5:21 AM
"Enforcer" is a tool which uses an MMU (Memory Management Unit) to watch for illegal accesses to memory. When such an access occurs, Enforcer dumps some information to the serial port (by default). This is known as a "hit." The illegal accesses are always caused by a bug in some program. Sometimes they happen in such a way that on some machines, some times the program could continue without noticable problem. That's why Enforcer was written in the first place — so programmers could immediately see that they'd done something wrong, rather than having to wait for their machine to crash (or to find a machine their program did crash on…). An "Enforcer Hit" then, is just a specific type of bug in a program.
#98176From: Paul IdolMay 3, 1993 11:04 AM
I understand now. Thanks. Paul