URL
https://opencores.org/ocsvn/openrisc/openrisc/trunk
Go to most recent revision |
Only display areas with differences |
Details |
Blame |
View Log
Rev 827 |
Rev 840 |
# This is a (bogus) sample user command built to test the printing
|
# This is a (bogus) sample user command built to test the printing
|
# of commands.
|
# of commands.
|
define test
|
define test
|
set $a = 1
|
set $a = 1
|
set $b = 2
|
set $b = 2
|
if ($a > $b)
|
if ($a > $b)
|
set $a = 1
|
set $a = 1
|
set $b = 2
|
set $b = 2
|
while ($a > $b)
|
while ($a > $b)
|
set $a = 1
|
set $a = 1
|
set $b = 2
|
set $b = 2
|
end
|
end
|
else
|
else
|
set $a = 1
|
set $a = 1
|
set $b = 2
|
set $b = 2
|
end
|
end
|
while ($a < $b)
|
while ($a < $b)
|
set $a = $a + 1
|
set $a = $a + 1
|
set $c = $a
|
set $c = $a
|
if ($a = $b)
|
if ($a = $b)
|
set $c = 5
|
set $c = 5
|
end
|
end
|
set $a = 1
|
set $a = 1
|
set $b = 2
|
set $b = 2
|
end
|
end
|
|
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.