Last change
on this file since 112 was
101,
checked in by rosiere, 16 years ago
|
1) Add soc test
2) fix bug (Pc management, Decod and execute, Update prediction ...)
|
-
Property svn:keywords set to
Id
|
File size:
633 bytes
|
Rev | Line | |
---|
[2] | 1 | #include "func_io.h" |
---|
| 2 | #include "thread_info.h" |
---|
| 3 | |
---|
[101] | 4 | void tty (unsigned char data) |
---|
[2] | 5 | { |
---|
[101] | 6 | unsigned int * addr =(unsigned int*)(TTY_BASE + (get_thread_id() << 4) + 0); |
---|
[2] | 7 | |
---|
[101] | 8 | *(addr) = data; |
---|
[2] | 9 | } |
---|
| 10 | |
---|
[101] | 11 | void print (char * data) |
---|
[2] | 12 | { |
---|
[101] | 13 | unsigned int * addr =(unsigned int*)(TTY_BASE + (get_thread_id() << 4) + 0); |
---|
[2] | 14 | |
---|
[101] | 15 | while ((*data) != '\0') |
---|
| 16 | { |
---|
| 17 | *(addr) = (*data); |
---|
| 18 | data++; |
---|
| 19 | } |
---|
[2] | 20 | } |
---|
[101] | 21 | |
---|
| 22 | void show (unsigned int data) |
---|
| 23 | { |
---|
| 24 | unsigned int * addr =(unsigned int*)(TTY_BASE + (get_thread_id() << 4) + 8); |
---|
| 25 | |
---|
| 26 | *(addr) = data; |
---|
| 27 | } |
---|
| 28 | |
---|
| 29 | void quit (unsigned int data) |
---|
| 30 | { |
---|
| 31 | unsigned int * addr = (unsigned int*)(TTY_BASE + (get_thread_id() << 4) + 4); |
---|
| 32 | |
---|
| 33 | *(addr) = data; |
---|
| 34 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.