Mercurial > pygar
diff core/sim/bdir_dut/Trace.bi @ 1:91a1f76ddd62 pygar svn.2
[svn r2] Adding initial lab 5 source
author | punk |
---|---|
date | Tue, 13 Apr 2010 17:34:33 -0400 |
parents | |
children |
line wrap: on
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/core/sim/bdir_dut/Trace.bi Tue Apr 13 17:34:33 2010 -0400 1.3 @@ -0,0 +1,56 @@ 1.4 +signature Trace where { 1.5 +import ¶Counter®¶; 1.6 + 1.7 +import ¶FIFOF_®¶; 1.8 + 1.9 +import ¶FIFOF®¶; 1.10 + 1.11 +import ¶FIFO®¶; 1.12 + 1.13 +import ¶Inout®¶; 1.14 + 1.15 +import ¶List®¶; 1.16 + 1.17 +import ¶Clocks®¶; 1.18 + 1.19 +import ¶ListN®¶; 1.20 + 1.21 +import ¶PrimArray®¶; 1.22 + 1.23 +import ¶Vector®¶; 1.24 + 1.25 +import ¶Connectable®¶; 1.26 + 1.27 +import ¶GetPut®¶; 1.28 + 1.29 +import ¶ClientServer®¶; 1.30 + 1.31 +class (Trace.Traceable :: * -> *) item_t where { 1.32 + Trace.traceTiny :: ¶Prelude®¶.¶String®¶ -> 1.33 + ¶Prelude®¶.¶String®¶ -> item_t -> ¶Prelude®¶.¶Action®¶ {-# arg_names = [loc, traceTag, item] #-}; 1.34 + Trace.traceFull :: ¶Prelude®¶.¶String®¶ -> 1.35 + ¶Prelude®¶.¶String®¶ -> item_t -> ¶Prelude®¶.¶Action®¶ {-# arg_names = [loc, traceTag, item] #-} 1.36 +}; 1.37 + 1.38 +instance Trace Trace.Traceable ¶Prelude®¶.¶String®¶; 1.39 + 1.40 +instance Trace Trace.Traceable (¶Prelude®¶.¶Bit®¶ n); 1.41 + 1.42 +Trace.traceGet :: (Trace.Traceable item_t) => 1.43 + ¶Prelude®¶.¶String®¶ -> ¶Prelude®¶.¶String®¶ -> ¶GetPut®¶.¶Get®¶ item_t -> ¶GetPut®¶.¶Get®¶ item_t; 1.44 + 1.45 +Trace.tracePut :: (Trace.Traceable item_t) => 1.46 + ¶Prelude®¶.¶String®¶ -> ¶Prelude®¶.¶String®¶ -> ¶GetPut®¶.¶Put®¶ item_t -> ¶GetPut®¶.¶Put®¶ item_t; 1.47 + 1.48 +Trace.traceClient :: (Trace.Traceable resp_t, Trace.Traceable req_t) => 1.49 + ¶Prelude®¶.¶String®¶ -> 1.50 + ¶Prelude®¶.¶String®¶ -> 1.51 + ¶Prelude®¶.¶String®¶ -> 1.52 + ¶ClientServer®¶.¶Client®¶ req_t resp_t -> ¶ClientServer®¶.¶Client®¶ req_t resp_t; 1.53 + 1.54 +Trace.traceServer :: (Trace.Traceable resp_t, Trace.Traceable req_t) => 1.55 + ¶Prelude®¶.¶String®¶ -> 1.56 + ¶Prelude®¶.¶String®¶ -> 1.57 + ¶Prelude®¶.¶String®¶ -> 1.58 + ¶ClientServer®¶.¶Server®¶ req_t resp_t -> ¶ClientServer®¶.¶Server®¶ req_t resp_t 1.59 +}