I don’t know if this is helpful, but I did a debug of b?branch and b(>resolve):
4010035 : b?branch [ 0x14 ]
: b?branch ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff ) fff46930: fcode-offset (offset) 26 ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff 26 ) fff46934: 0< ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff 0 ) fff46938: do?branch ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff ) fff4695c: setup-tmp-comp ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff ) fff46960: (lit) ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff3d4e4 ) fff46968: , ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff ) fff4696c: here ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff571c4 ) fff46970: 0 ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff571c4 0 ) fff46974: 0 ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff571c4 0 0 ) fff46978: , ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff571c4 0 ) fff4697c: (semis) [ Finished b?branch ] 4010039 : (compile) [ 0x9bd ] 401003a : (compile) b(lit) [ 0x10 ] 401003f : (compile) and [ 0x23 ] 4010041 : (compile) my-space [ 0x103 ] 4010042 : (compile) + [ 0x1e ] 4010044 : (compile) [ 0xa08 ] 4010045 : (compile) b(lit) [ 0x10 ] 401004a : (compile) and [ 0x23 ] 401004b : (compile) b(lit) [ 0x10 ] 4010050 : (compile) = [ 0x3c ] 4010051 : (compile) b?branch [ 0x14 ]
: b?branch ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff571c4 0 ) fff46930: fcode-offset (offset) 9 ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff571c4 0 9 ) fff46934: 0< ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff571c4 0 0 ) fff46938: do?branch ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff571c4 0 ) fff4695c: setup-tmp-comp ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff571c4 0 ) fff46960: (lit) ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff571c4 0 fff3d4e4 ) fff46968: , ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff571c4 0 ) fff4696c: here ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff571c4 0 fff57200 ) fff46970: 0 ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff571c4 0 fff57200 0 ) fff46974: 0 ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff571c4 0 fff57200 0 0 ) fff46978: , ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff571c4 0 fff57200 0 ) fff4697c: (semis) [ Finished b?branch ] 4010054 : (compile) b(') [ 0x11 ] 4010057 : (compile) b(to) [ 0xc3 ] 401005a : (compile) b(>resolve) [ 0xb2 ]
: b(>resolve) ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff571c4 0 fff57200 0 ) fff469bc: resolve-orig ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff571c4 0 ) fff469c0: execute-tmp-comp ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff571c4 0 ) fff469c4: (semis) [ Finished b(>resolve) ] 401005b : (compile) b(>resolve) [ 0xb2 ]
: b(>resolve) ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff fff571c4 0 ) fff469bc: resolve-orig ( ffffffff 1 0 ffffffff 0 0 ffffffff fff41a48 0 0 0 0 0 0 ffffffff ) fff469c0: execute-tmp-comp byte-load: exception caught! ok
On May 8, 2018, at 6:14 PM, Jd Lyons via OpenBIOS openbios@openbios.org wrote:
On May 8, 2018, at 5:56 PM, Segher Boessenkool segher@kernel.crashing.org wrote:
On Tue, May 08, 2018 at 12:41:30PM -0700, Joe van Tunen wrote:
The b?branch command causes the dictionary pointer to change from fff81e54 to fff57240. This behavior is described in fcode.fs where b?branch calls setup-tmp-comp. It's using the tmp-comp-buf which is initialized to a fixed size of 200 in bootstrap.fs. Is 200 enough?
Using a temporary compile buffer for b?branch in interpret mode is incorrect. It should be executed in interpret mode directly, as the 1275 specification specifies. This is different from IF in interpret mode, etc.
Segher
Yes, that sound about right, we got to maybe b?branch wasn’t working correctly, before. I did a hatchet job, basically just a copy and paste from SLOF into Openbios, and a few “fixes” to make it compile, but I think the result was the Fcode caught an exception earlier.
Likely if someone that knew what they were doing takes a swing at it, we could get a little further.
https://mail.coreboot.org/pipermail/openbios/2017-December/010071.html
OpenBIOS http://openbios.org/ Mailinglist: http://lists.openbios.org/mailman/listinfo Free your System - May the Forth be with you