2023-07-22 00:04:54 I ordered one of those. 2023-07-22 00:12:08 Anyone know offhand what the F signifies in Arm Cortex-M4F? 2023-07-22 00:16:16 Something to do with floating point, maybe. 2023-07-22 00:16:38 M4F seems to appear in a lot of search hits that talk about floating point specific things. 2023-07-22 01:13:12 KipIngram, the F means floating point 2023-07-22 01:20:58 TIB. Terminal Input Buffer? 2023-07-22 03:40:26 Ah! I think I understand SmithForth, now. 2023-07-22 03:44:22 It bootstraps a minimal inpterpreter from a dictionary of 27 words. 2023-07-22 03:46:09 The dictionary of which is essentially just directly shoved into the .text section of the ELF. 2023-07-22 03:47:05 Really, it's a compressed form of the dictionary, so it first runs a loop that mostly just copies those bytes into the dictionary's memory arena. 2023-07-22 03:47:53 And uses the byte 99h as a special marker. Either 99h marks the beginning of a new dictionary entry, which requires setting up the real header, updating Latest, etc. 2023-07-22 03:48:37 Or 99 marks a call into the dictionary, either to compile existing code into another definition or execute it as an immediate. 2023-07-22 03:49:35 In particular, the ti (text interpreter) word is the last entry setup, which then gets subsequently executed. 2023-07-22 03:53:56 That part, including the ELF header, is just 953 bytes. Pretty slick! 2023-07-22 03:56:10 Compiling the source is pretty funny, too. You literally just strip comments, use xxd to convert the hex text into bytes, and then concatenate the 100%-Forth-Code dictionary onto the end of the ELF. 2023-07-22 08:17:02 I'm confused about what COMPL is doing :/ 2023-07-22 08:18:39 The first three lines effectively throw FF 14 25 on the dictionary/data area (%rdi), which I believe corresponds to the assembly `call (%rbp, %rsp, 1)` 2023-07-22 08:30:21 It then throws the subroutine address right after that instruction. 2023-07-22 08:30:38 Maybe I'm just missing something obvious with the particular threading model it's using? 2023-07-22 09:59:33 radare has a good disassembler if you need one 2023-07-22 10:00:11 there's also a great one online I can't find in the first few dozen results on Google. it splits out fields on the instruction 2023-07-22 10:13:19 MrMobius: Well, there you go. Radare believes it disassembles to `call qword [0]`, which makes much more sense. 2023-07-22 10:15:13 Now I'm confused about how radare is getting that, though. 2023-07-22 10:16:55 FF 14 25 = 0xFF ModR/M SIB = 0b00_010_100 0b00_100_101 2023-07-22 10:17:54 And Mod.Reg = 0b010 = 2, meaning this corresponds to FF/2, i.e. CALL r/m64. 2023-07-22 10:20:04 that's where a disassembler that breaks down the bits Is useful 2023-07-22 10:20:39 hmm, never thought to check if radare does that since I used the other one 2023-07-22 10:42:53 Got it! The SIB byte has a special interpretation when SIB.Base = 0b101 and Mod = 0b00, causing it to look for a dword displacement. 2023-07-22 10:43:49 The OSDev wiki table (https://wiki.osdev.org/X86-64_Instruction_Encoding#SIB) seems to be missing so info. 2023-07-22 10:44:03 Needed to go to the Intel manuals. 2023-07-22 10:46:38 all 6,000+ pages? 2023-07-22 10:46:53 Anyway, so SmithForth's COMPL simply lays down a call to the named procedure. 2023-07-22 10:47:46 thrig: Lol. What do you mean, it's right there on page 2-7 of volume 2A :P 2023-07-22 10:48:08 probably you'll be using "find" a lot 2023-07-22 10:48:48 Guilty as charged 2023-07-22 11:39:00 travisb_: Thanks. I thought it might, but couldn't find hard confirmation anywhere. 2023-07-22 11:39:15 xelxebar: yes, or text input buffer. 2023-07-22 11:40:26 Yeah, those Intel manuals are almost useless due to sheer size. 2023-07-22 11:48:46 xelxebar: "terminal" input buffer actually seems like a better meaning for the acronym to me, since disk buffers are usually separate and also provide text to the interpreter. TIB normally gets used only for text coming from the terminal, so that makes it seem slightly more descriptive to me. 2023-07-22 11:49:41 Somewhere in there there's likely something along the lines of ... BLK @ ?DUP 0= IF TIB THEN ... 2023-07-22 11:50:16 And then the value of >IN gets added to that, to find the next input character. 2023-07-22 11:53:07 Either way the buffer is null-terminated (usually), and the interpreter will either explicitly check for the null or else there will be an immediate word in the dictionary that has the null string for its name; executing that word will terminate the loop processing whatever buffer is being processed at the time. 2023-07-22 11:53:50 I actually don't null terminate my disk buffers, so I have a size check in that loop as well. 2023-07-22 11:54:01 Just won't let >IN go beyond 4095. 2023-07-22 11:54:37 And if it tries to, the "get next byte" bit of code returns zero. 2023-07-22 12:15:05 Good - the little document I listed last night for that "Feather" board I ordered does a good job of specifying all the chips on it. There seems to be good information out there on all of it. The CPU itself is here: 2023-07-22 12:15:06 https://www.analog.com/media/en/technical-documentation/data-sheets/MAX32655.pdf 2023-07-22 12:15:41 And they have a Linux SDK, so hopefully I'll have everything I need to make a run at that thing. 2023-07-22 12:17:42 This is an interesting sentence in that CPU data sheet: 2023-07-22 12:17:53 "An 8KB user OTP area 2023-07-22 12:17:55 is available, of which 8 bytes are retained, even during 2023-07-22 12:17:57 POWER DOWN mode. y 2023-07-22 12:18:20 I don't get what that 8-byte bit means. If it's OTP, you'd think the whole thing would be non-volatile. 2023-07-22 12:18:58 Eight input, 10-bit ADC. 2023-07-22 13:57:56 That SDK installed, with a little bit of fussing, and there seems to be a large collection of example projects for this particular Maxim micro. 2023-07-22 13:58:28 Eclipse-based. I sort of hate Eclipse - it always just seems so... FAT. 2023-07-22 13:58:45 And usually sluggish, but I guess I shouldn't comment on this incarnation yet. 2023-07-22 13:59:38 The installer complained about a couple of things, but turned out that if I told it to ignore those errors it then proceeded to run all the way through, and everything I've tried to run so far seems to work fine. 2023-07-22 13:59:52 Hopefully I've got a corral full of stuff I can learn from here. 2023-07-22 14:08:11 apparently there are modern IDE without the bigness of Eclipse 2023-07-22 14:16:48 Do point me if you see one. 2023-07-22 14:17:28 I'm happy to learn from their code examples, but all I really want to do in the end is get a Forth onto the thing and then start writing my own code for all those peripherals. 2023-07-22 14:17:59 So eventually I'm going to want to wipe all of the pre-existing stuff off of it. 2023-07-22 14:19:27 This little gadget absolutely looks like it'll do everything I'll ever need, and those headers make it through-hole installable. 2023-07-22 14:19:58 Thirty bucks to cover all that list of functionality? I'm comfortable with that. 2023-07-22 14:28:23 The "Technical Reference Manual" for that CPU is another one of those god-forsaken web-based sprawls. What do people have against PDFs???? 2023-07-22 14:28:37 Just give me a book. 2023-07-22 14:35:15 putting an onion on your belt was the style of the time 2023-07-22 18:39:25 ACTION is in a c(iph|yb)erpunkish mood due to https://catvalente.substack.com/p/stop-talking-to-each-other-and-start 2023-07-22 18:43:57 more on topic regarding forth 2023-07-22 18:45:30 a lot of you have heard me go on and on fcpu16 and its many inspirations such as excamera j1 and the dual stack machines from Koopmans book 2023-07-22 18:49:03 the reason, the main one at least, I have speced fcpu16 is that I wanted to build a trusted third party platform via SecureMultiPartyComputation 2023-07-22 18:50:10 the smpc substrate I have chosen is Ueli Maurers SMPC made simple 2023-07-22 18:51:25 the basic one only provides combinational boolean circuits 2023-07-22 18:52:22 that is, four kind of components: inputs, outputs, and gates, and xor gates 2023-07-22 18:54:22 after staring at Uelis paper for quite a while I realized that I could add the fifth kind of component: a delay based memory cell 2023-07-22 18:55:42 how? well it works like an output that feeds directly into an input 2023-07-22 18:58:23 only it is a bit simpler implementation wise: you take the node local secret shares for the output from last round and feed them directly to whatever the input isconnected to 2023-07-22 18:59:42 so a mem cell is basically a round delayed wire 2023-07-22 19:03:42 building a two input mux out of two and gates, two xor gates, and a constant on(e) input is easy 2023-07-22 19:05:03 using such two in mux with the aforesaid delay mem cell means that we get a D-latch 2023-07-22 19:07:49 What's wrong with the way we make D flops now? 2023-07-22 19:08:01 plonk sixteen of them side by side and have them share the samemux select wire, which wecall write enable, we got an forth cell 2023-07-22 19:08:36 KipIngram: context is smpc virtual boolean circuitry 2023-07-22 19:08:43 Which may actually may not be altogether different from what you're describing, just done at the transistor level rather than a higher level. 2023-07-22 19:12:53 one thing I worked out is that xor can replace or so long one can gurantee that all other inputs to it other than you are intrestedin are all zero 2023-07-22 19:16:11 : 2mux ( a b sel -- x ) rot over and >R not and R> xor ; 2023-07-22 19:17:01 : not ( a -- x ) CONST_1 xor ; 2023-07-22 19:19:25 ACTION continues 2023-07-22 19:20:26 one can build a four in mux out of three two in muxes 2023-07-22 19:22:34 which means that one can pair together a pair of forth cells, and so on building a 256 cell sized page 2023-07-22 19:23:05 same with demuxes btw 2023-07-22 19:25:38 long story short, one can build an very small computer with this 2023-07-22 19:26:53 only this smallcomputer exists betwixt the smpc nodes running the combinational circuit implementation of it 2023-07-22 19:29:15 yet no node understands the state of it as they only have their secret shares of the wire running between components in that circuit 2023-07-22 19:33:10 add stuff to this small computer like an aes accelerator implemented the same way you get a small computer that can swap its memory TPM/SGX/GlobalPlatform/TEE style 2023-07-22 19:34:46 why? because how and gates work in Ueli Mauers protocol causes quite abit of traffic 2023-07-22 19:41:40 but what is all this to avail ya ask? 2023-07-22 19:44:54 well I wanted to find a way to run a 'server' ontop of p2p that could be trusted to keep secrets/be confidential 2023-07-22 22:49:50 I guess it all sounds interesting. It just feels so... "remote" from what I have always done. So far from the metal that it's hard to imagine the performance being anything close to good. My interest is always about trying to remove layers and have the simplest connection possible between the machinery and the produced results. All this layers on layers on layers kind of glazes my eyes over. 2023-07-22 22:50:32 That's why when you mentioned gates earlier I just naturally thought you were talking about hardware, because... how else would one do gates? :-) 2023-07-22 22:57:25 I watched C-beams glitter in the dark near the Tannhäuser Gate