00:00:00 --- log: started retro/17.04.23 08:15:17 --- join: __tthomas__ (~drift@2601:581:c000:e6b0:6188:4739:efb6:c7d6) joined #retro 08:15:55 --- part: __tthomas__ left #retro 08:37:59 --- join: FreeFull (~freefull@defocus/sausage-lover) joined #retro 09:53:31 --- join: neceve (~ncv@86.125.247.109) joined #retro 09:53:31 --- quit: neceve (Changing host) 09:53:31 --- join: neceve (~ncv@unaffiliated/neceve) joined #retro 10:05:53 --- quit: neceve (Quit: Konversation terminated!) 10:47:40 --- join: LionKimbro (4c79bf11@gateway/web/freenode/ip.76.121.191.17) joined #retro 10:55:52 @crc -- I've been reading the Naje source code, -- and I've been wondering: Would you be interested in patches and/or ideas? I have a few thoughts about the code. First, there are some simple things like -- it says "-DALLOW_FORWARD_REFERENCES" should be defined, but it seems like it's really "-DALLOW_FORWARD_REFS". Also, for example, MAX_REFS is defined, but nowhere used in the code. (It looks like it's value is intended to be 10:55:57 The refernences/forward-references code seems kind of clunky to me. Would it not be more optimal to do one of the following? 10:56:00 (idea A:) Two-pass it. In the first pass, resolve no references, simply put a 0 in place. This populates the label lookup tables. In the second pass, record no labels, put resolve all references. This way, forward references are handled identical to reverse references. This strikes me as both conceptually simpler, and further, requires no additional RAM (which you seem to be concerned about,) at the cost of having a 2-pass sys 10:56:03 (idea B:) Keep a list of where the references were, side-by-side ref_names. Then rather than zippering through, resolving references one after the other (looks like an N^2 operation to me,) just patch the immediate place where the references are. najeResolveReferences would then be easier to understand (for me at least,) and also spend no time traversing the entirety of memory, each time a reference is intended to be resolved. 11:13:00 LionKimbro: I'd love patches/improvements. 11:13:30 This was my first attempt at a standalone assembler in C. There's lots of room for improvements. 11:18:31 Re RAM use: I was trying to have an option to keep memory use down for use with things like RetroBSD for PIC32 which runs on boards with tiny amounts of memory. 11:18:57 That said, I haven't actually used it without forward references enabled. 12:15:31 @crc: How would you like submissions? I notice that https://github.com/crcx/nga/tree/master/source 's naje is post-unu processing, unlike http://forthworks.com/nga/Naje.md (but that does not appear to be in a git source code repository.) 12:18:44 The Naje.md would be the canonical master source. https://github.com/crcx/nga/blob/master/Naje.md 12:19:39 For the main repo. There's an rx-nga repo on github for the retro project, which includes a copy as well 13:32:37 --- join: moijk (~moijk@ti0090a400-2570.bb.online.no) joined #retro 13:33:29 --- part: moijk left #retro 14:07:31 --- quit: LionKimbro (Ping timeout: 260 seconds) 15:13:10 --- join: LionKimbro (4c79bf11@gateway/web/freenode/ip.76.121.191.17) joined #retro 16:45:42 LionKimbro: I merged the pull request 17:20:17 --- join: neceve (~ncv@86.125.247.109) joined #retro 17:20:17 --- quit: neceve (Changing host) 17:20:17 --- join: neceve (~ncv@unaffiliated/neceve) joined #retro 19:02:49 crc: OK -- next submission might require some consideration; I've tested changes vs. the existing samples/ output, to ensure that nothing breaks. It seems to produce the same output, both in assembler, and in map files. The main tradeoff seems to me to be: size (save 64KB) and simpler code (eliminates forward references system), for execution time (doubles.) 19:07:32 Thank you. I'll do some testing on it. From an initial check the output seems fine on the main retro kernel, but I'll run it against some other tests as well. 19:52:53 --- quit: neceve (Quit: Konversation terminated!) 20:09:48 For everything I've tried this works perfectly. It's now merged, thank you :) 23:00:43 --- quit: FreeFull () 23:59:59 --- log: ended retro/17.04.23