2016-11-20 11:53:44 +00:00
|
|
|
#
|
2016-11-26 10:23:25 +00:00
|
|
|
mes 2, EM_WSIZE, EM_PSIZE
|
2016-11-20 11:53:44 +00:00
|
|
|
|
|
|
|
exp $_m_a_i_n
|
|
|
|
pro $_m_a_i_n, 0
|
|
|
|
|
|
|
|
/* Test non-existent bit */
|
|
|
|
|
|
|
|
.1
|
2016-12-06 20:45:20 +00:00
|
|
|
rom 0I4
|
2016-11-20 11:53:44 +00:00
|
|
|
loe .1
|
|
|
|
loc 1 /* bit number */
|
2016-12-06 20:45:20 +00:00
|
|
|
inn 4
|
2016-11-20 11:53:44 +00:00
|
|
|
zeq *1
|
|
|
|
|
|
|
|
loc __LINE__
|
|
|
|
cal $fail
|
2016-11-26 10:23:25 +00:00
|
|
|
ass EM_WSIZE
|
2016-11-20 11:53:44 +00:00
|
|
|
1
|
|
|
|
|
|
|
|
/* Test existent bit */
|
|
|
|
|
|
|
|
.2
|
2016-12-06 20:45:20 +00:00
|
|
|
rom 16384
|
|
|
|
.21
|
|
|
|
rom 14 /* to defeat constant folding */
|
|
|
|
|
2016-11-20 11:53:44 +00:00
|
|
|
loe .2
|
2016-12-06 20:45:20 +00:00
|
|
|
loe .21 /* bit number */
|
2016-11-26 10:23:25 +00:00
|
|
|
inn EM_WSIZE
|
2016-11-20 11:53:44 +00:00
|
|
|
zne *2
|
|
|
|
|
|
|
|
loc __LINE__
|
|
|
|
cal $fail
|
2016-11-26 10:23:25 +00:00
|
|
|
ass EM_WSIZE
|
2016-11-20 11:53:44 +00:00
|
|
|
2
|
|
|
|
|
|
|
|
/* Test non-existent high bit */
|
|
|
|
|
|
|
|
.3
|
2016-12-06 20:45:20 +00:00
|
|
|
rom 0, 0
|
2016-11-20 11:53:44 +00:00
|
|
|
.31
|
2016-12-06 20:45:20 +00:00
|
|
|
rom 8 /* to defeat constant folding */
|
2016-11-20 11:53:44 +00:00
|
|
|
|
|
|
|
lae .3
|
2016-11-26 10:23:25 +00:00
|
|
|
loi EM_WSIZE*2
|
2016-11-20 11:53:44 +00:00
|
|
|
loe .31 /* bit number */
|
2016-11-26 10:23:25 +00:00
|
|
|
inn EM_WSIZE*2
|
2016-11-20 11:53:44 +00:00
|
|
|
zeq *3
|
|
|
|
|
|
|
|
loc __LINE__
|
|
|
|
cal $fail
|
2016-11-26 10:23:25 +00:00
|
|
|
ass EM_WSIZE
|
2016-11-20 11:53:44 +00:00
|
|
|
3
|
|
|
|
|
|
|
|
/* Test existent high bit */
|
|
|
|
|
|
|
|
.4
|
2016-12-06 20:45:20 +00:00
|
|
|
rom 0, 2
|
2016-11-20 11:53:44 +00:00
|
|
|
.41
|
2016-11-26 10:23:25 +00:00
|
|
|
rom (EM_WSIZE*8)+1 /* to defeat constant folding */
|
2016-11-20 11:53:44 +00:00
|
|
|
|
|
|
|
lae .4
|
2016-11-26 10:23:25 +00:00
|
|
|
loi EM_WSIZE*2
|
2016-11-20 11:53:44 +00:00
|
|
|
loe .41 /* bit number */
|
2016-11-26 10:23:25 +00:00
|
|
|
inn EM_WSIZE*2
|
2016-11-20 11:53:44 +00:00
|
|
|
zne *4
|
|
|
|
|
|
|
|
loc __LINE__
|
|
|
|
cal $fail
|
2016-11-26 10:23:25 +00:00
|
|
|
ass EM_WSIZE
|
2016-11-20 11:53:44 +00:00
|
|
|
4
|
|
|
|
|
|
|
|
cal $finished
|
|
|
|
ret 0
|
|
|
|
|
|
|
|
end
|