[comp.sys.amiga.tech] Aztec C and Enforcer

peter@sugar.hackercorp.com (Peter da Silva) (11/25/90)

Enforcer tell me that programs compiled under Aztec C do lots of reads from
location 8 with (READ-LONG) or 10 with (READ-WORD). I've looked through the
runtime source and can't see where this is happening. Has anyone any ideas,
or should I wait until I get the latest Aztec?

(and what's the real official name? Manx or Aztec?)
-- 
Peter da Silva.   `-_-'
<peter@sugar.hackercorp.com>.

bj@cbmvax.commodore.com (Brian Jackson) (11/25/90)

In article <7127@sugar.hackercorp.com> peter@sugar.hackercorp.com (Peter da Silva) writes:
>Enforcer tell me that programs compiled under Aztec C do lots of reads from
>location 8 with (READ-LONG) or 10 with (READ-WORD). I've looked through the
>runtime source and can't see where this is happening. Has anyone any ideas,
>or should I wait until I get the latest Aztec?
>
>(and what's the real official name? Manx or Aztec?)

Versions of Aztec ('Aztec C'is the name of the compiler while 'Manx
Software Systems' is the name of the company that brings it to you)
prior to v5.0d had quite a few Enforcer hits in them (both the
compiler and the code they generated). This seems to have been cured
in 5.0d. I use Aztec C quite a lot and the latest one has yet to cause
a hit (that I haven't created myself.)

bj

>Peter da Silva.   `-_-'

 -----------------------------------------------------------------------
 | Brian Jackson  Software Engineer, Commodore-Amiga Inc.  GEnie: B.J. |
 | bj@cbmvax.cbm.commodore.com    or  ...{uunet|rutgers}!cbmvax!bj     |
 | Simpson's Episodes are numbered in hex.                             |
 -----------------------------------------------------------------------

Radagast@cup.portal.com (sullivan - segall) (11/25/90)

>>Enforcer tell me that programs compiled under Aztec C do lots of reads from
>>location 8 with (READ-LONG) or 10 with (READ-WORD). I've looked through the
>>runtime source and can't see where this is happening. Has anyone any ideas,
>>or should I wait until I get the latest Aztec?
>>
>>(and what's the real official name? Manx or Aztec?)
>
>Versions of Aztec ('Aztec C'is the name of the compiler while 'Manx
>Software Systems' is the name of the company that brings it to you)
>prior to v5.0d had quite a few Enforcer hits in them (both the
>compiler and the code they generated). This seems to have been cured
>in 5.0d. I use Aztec C quite a lot and the latest one has yet to cause
>a hit (that I haven't created myself.)
>
>bj
>
Where can I get a copy of Enforcer?  (Sounds quite useful.)

                           -Sullivan_-_Segall (a.k.a. Radagast)
_______________________________________________________________
 
/V\  E-Credibility:  (n -- ME) The unguaranteed likelyhood that
 '   the electronic mail you are reading is genuine rather than
someone's made up crap.
_______________________________________________________________
 
Mail to: ...sun!portal!cup.portal.com!radagast or
         radagast@cup.portal.com
 

bj@cbmvax.commodore.com (Brian Jackson) (11/26/90)

In article <36209@cup.portal.com> Radagast@cup.portal.com (sullivan - segall) writes:

>Where can I get a copy of Enforcer?  (Sounds quite useful.)
>
>                           -Sullivan_-_Segall (a.k.a. Radagast)
> 
It comes with the developer stuff. It was on the 1990 Devcon disks and
we just got through posting it to the commercial services (I posted
it to GEnie, at least; I assume that BIX, CIS, etc. have it.) It's
also on the FAUG BBS in the San Francisco Bay area (415) 5952479.

bj

 -----------------------------------------------------------------------
 | Brian Jackson  Software Engineer, Commodore-Amiga Inc.  GEnie: B.J. |
 | bj@cbmvax.cbm.commodore.com    or  ...{uunet|rutgers}!cbmvax!bj     |
 | "Please Captain, not in front of the Klingons."                     |
 -----------------------------------------------------------------------

thad@cup.portal.com (Thad P Floryan) (11/27/90)

bj@cbmvax.commodore.com (Brian Jackson) in <16055@cbmvax.commodore.com> writes:

	In article <36209@cup.portal.com> Radagast@cup.portal.com (sullivan -
	segall) writes:

	>Where can I get a copy of Enforcer?  (Sounds quite useful.)
	>
	>                           -Sullivan_-_Segall (a.k.a. Radagast)
	> 
	It comes with the developer stuff. It was on the 1990 Devcon disks and
	we just got through posting it to the commercial services (I posted
	it to GEnie, at least; I assume that BIX, CIS, etc. have it.) It's
	also on the FAUG BBS in the San Francisco Bay area (415) 5952479.

Note that it's also at abcfd20.larc.nasa.gov.  Note also that it REQUIRES
an MMU in one's Amiga per its docs (enclosed below).

Thad Floryan [ thad@cup.portal.com (OR) ..!sun!portal!cup.portal.com!thad ]

-------------------- begin enclosed material --------------------

Enclosed is a majik tool for detecting invisible bugs in programs; _The
Enforcer_ uses the MMU to build a shroud of protection over anything that
is not legal memory.  Any "empty holes" in the address space are marked as
illegal by _Enforcer_.	Reads of the system ROMs are allowed, but not
writes.  With the exception of longword reads of location 4, the lowest 1K
of memory is completely off-limits.

When an illegal access is detected, the power LED will flash and a detailed
message will be sent out the serial port (at the default speed).  Illegal
writes are aborted, illegal reads return NULL data.  For example:



Program Counter (approximate)= 783C460         Fault address        =DEADBEEF
User stack pointer	     = 7860ABC	       DOS Proccess address = 7839F98
Data: 00000001 01E0F0FB 00000FA0 0783AE18 00000001 01E0987F 01E0A93D 0783C3EC
Addr: 0783AE18 0785FB28 07810114 0783C3EC 07860AC0 00F8F56A 00F8F55E 078021D0
Status register =$8	       Special status word =$729 (WRITE-WORD)
Data output buffer  =$FFFFADEF (o)
Process/CLI = Background CLI ,"lawbreaker"
Hunk-O-Matic says: PC address is in hunk #0, near offset $70



CLI command "lawbreaker" has written the word value $ADEF to location
$DEADBEEF.  The write was aborted.  With the information given, it is
usually quite easy to figure out what went wrong.




Remote keystrokes:
	    ^S	- pause
	    ^Q	- resume
	    ^X	- disable _Enforcer_ reporting until next ^Q.


Command line options:
	    on
	    fprotect	;Same as on, but write protects $F00000-$F7FFFF
	    off






Notes:

    If you don't have an external terminal, just use a modem & a terminal
    program.  Most modems will echo back characters at any baud rate. Else,
    just set the baud rate to match the modem.


    Illegal hits from CLI commands named "metascope" or "wack" are ignored.


    The Alert() system call writes to locations in the $180-$1C0 area.


    _The Enforcer_ works on any V1.2,V1.3 or V2.0 system, provided the MMU
    is available.

    _The Enfocer_ also works on A3000 SuperKickstart machines, under 2.0
    or under 1.3.

-------------------- end enclosed material --------------------

peter@sugar.hackercorp.com (Peter da Silva) (11/28/90)

Anyone got a version of the enforcer that uses spaces rather than tabs for
formatting? My little old ADM5 tube doesn't know what to do with tabs and
the result is hard to read...
-- 
Peter da Silva.   `-_-'
<peter@sugar.hackercorp.com>.

lphillips@lpami.wimsey.bc.ca (Larry Phillips) (11/29/90)

In <7152@sugar.hackercorp.com>, peter@sugar.hackercorp.com (Peter da Silva) writes:
>Anyone got a version of the enforcer that uses spaces rather than tabs for
>formatting? My little old ADM5 tube doesn't know what to do with tabs and
>the result is hard to read...

Have a look at it with NewZap and change them to spaces.  The tabs are not
plentiful, and are fairly obvious, being right in with the strings.

-larry

--
The only things to survive a nuclear war will be cockroaches and IBM PCs.
+-----------------------------------------------------------------------+ 
|   //   Larry Phillips                                                 |
| \X/    lphillips@lpami.wimsey.bc.ca -or- uunet!van-bc!lpami!lphillips |
|        COMPUSERVE: 76703,4322  -or-  76703.4322@compuserve.com        |
+-----------------------------------------------------------------------+