summaryrefslogtreecommitdiff
path: root/cpu8/cpu_or/cpu_or.hpp
blob: 75c637dba022c409ceb49d38cd258b0efdbf3111 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#ifndef __SYSC_CPU_OR_HPP
#define __SYSC_CPU_OR_HPP

#include "systemc.h"

SC_MODULE (cpu_or) 
{
	sc_in <bool> in_a;
	sc_in <bool> in_b;
	sc_out <bool> out_c;

	void do_or()
	{
		out_c.write( (in_a.read() || in_b.read()) );
	}

	SC_CTOR(cpu_or)
	{
		SC_METHOD(do_or);
		sensitive << in_a << in_b;
	}

	

};

#endif