NNgen / nngen

NNgen: A Fully-Customizable Hardware Synthesis Compiler for Deep Neural Network
Apache License 2.0
339 stars 46 forks source link

feature add interrupt circit #18

Closed RyusukeYamano closed 4 years ago

RyusukeYamano commented 4 years ago

概要

割込み機能を実装しました. ※ レジスタマップに変更があります

実装のポイント

[Register Map]
    0 (R ): header0 (default: 0)
    4 (R ): header1 (default: 0)
    8 (R ): header2 (default: 0)
   12 (R ): header3 (default: 0)
   16 ( W): Start (set '1' to run)
   20 (R ): Busy (returns '1' when running)
   24 ( W): Reset (set '1' to initialize internal logic)
   28 (R ): Opcode from extern objects to SW (returns '0' when idle)
   32 ( W): Resume extern objects (set '1' to resume)
   36 (R ): Interrupt Status Register
   40 ( W): Interrupt Enable Register
   44 ( W): Interrupt Acknowledge Register
   48 (X): reserved ..
  124 (X): .. reserved
  128 (RW): Global address offset (default: 0)
  132 (RW): Address of temporal storages (size: 97KB)
  136 (RW): Address of output (matmul) 'output_layer' (size: 64B, dtype: int8, shape: (1, 10), alignment: 4 words (4 bytes)), aligned shape: (1, 12)
  140 (RW): Address of placeholder 'input_layer' (size: 4KB, dtype: int8, shape: (1, 32, 32, 3), alignment: 4 words (4 bytes)), aligned shape: (1, 32, 32, 4)
  144 (RW): Address of variables 'w0', 'b0', 's0', 'w1', 'b1', 's1', 'w2', 'b2', 's2', 'w3', 'b3', 's3' (size: 4139KB)