sadoon_albader[m | Lol nice | 04:42 |
---|---|---|
lkcl | hurrah - i've turned microwatt's sdram_init into a stand-alone mini-bios | 15:35 |
lkcl | https://twitter.com/lkcl/status/1477663451204005893 | 15:35 |
lkcl | next step is, now that the console has been properly initialised, chain-load to the linux kernel | 15:36 |
lkcl | ha! got the early boot messages now, after switching to joel's microwatt-5.7 kernel | 16:31 |
henriok | lkcl: Are you running Microwatt-Linux on Libre-SOC? | 17:03 |
lkcl | henriok: on microwatt. | 17:39 |
lkcl | that's the first step | 17:39 |
lkcl | there are too many unknowns at the moment | 17:39 |
lkcl | i cannot "flip in" both an unknown-status HDL *and* an unknown-status simulator *and* an unknown-status linux kernel | 17:40 |
lkcl | haha just did the calculations on running the uncompression of a zImage linux kernel, it's somewhere around an hour :) | 18:19 |
lkcl | i fink i will investigate how to do uncompressed linux images :) | 18:20 |
programmerjake | maybe zstd compression instead...iirc it has really fast decompression speeds if you use the right setting | 18:23 |
programmerjake | https://github.com/facebook/zstd#benchmarks | 18:25 |
lkcl | simulated-memory is cheap: i can always increase simulated memory from 512 mb to 1 GB | 18:25 |
lkcl | simulated-processor speed is a HUNDRED thousand times slower | 18:26 |
lkcl | i'm lucky to have 5 characters per second outputted on the serial console | 18:26 |
lkcl | this is operating at 4-5 orders of magnitude slower than real time | 18:26 |
programmerjake | was just thinking that zstd is already used on some distros, so you could copy their work. uncompressed is likely a lot less common | 18:27 |
lkcl | zstd - if it is, say, 5x better, would still be 15 minutes to complete decompression. | 18:27 |
lkcl | 15 minutes of real-time that is | 18:27 |
programmerjake | if you use --fast=4 when compressing, the benchmark shows it as being around 6x faster than gzip | 18:29 |
lkcl | that's still 15 minutes of real time waiting for it to unpack. | 18:30 |
lkcl | that's if i have my calculations right. | 18:30 |
programmerjake | for decompression speeds | 18:30 |
lkcl | i was getting an estimated 1,000 bytes decompressed per second | 18:30 |
lkcl | and there are... | 18:30 |
lkcl | Decompressing (0x0000000000000000 <- 0x0000000000614000:0x0000000000926a9d)... | 18:30 |
programmerjake | maybe disable unneeded drivers too? smaller kernel makes for faster decompression | 18:31 |
lkcl | basically a lot | 18:31 |
programmerjake | idk if that's already done | 18:31 |
lkcl | i'm currently working through how to set HAVE_KERNEL_UNCOMPRESSED | 18:31 |
lkcl | ah, got it. have to add an option to arch/powerpc/Kconfig | 18:33 |
programmerjake | hope that works, cuz apparently it's not well supported on x86, so may not be well supported on powerpc either | 18:35 |
programmerjake | from google search: https://www.reddit.com/r/archlinux/comments/ex3pxb/comment/fg66gjz/ | 18:36 |
lkcl | yep just having to add #ifndef CONFIG_KERNEL_DECOMPRESSED around the call attempting to detect a compression signature | 18:41 |
lkcl | okaaaay that's double the size - a good sign | 18:42 |
lkcl | 6mb instead of 3mb | 18:42 |
lkcl | over 60% of that is the initrd. | 18:42 |
lkcl | frickin hilarious seeing 20 gigabyte gtkwave files... | 18:43 |
lkcl | that's after only running for about 45 seconds (!) | 18:44 |
lkcl | yuk it's currently copying the memory over at 32-bit intervals | 18:44 |
lkcl | bram wr addr 0002d8e4 dout 7c84483000000000 sel f0 ....0H.. | 18:44 |
lkcl | bram wr addr 0002d8e5 dout 7c8407b4 sel f ........ | 18:44 |
lkcl | blech :) | 18:44 |
lkcl | i've got verilator printing out all read/writes to the simulated-memory so i can see what's going on | 18:45 |
lkcl | bram wr addr 000a71e5 dout 4bc00 sel f ........ | 18:47 |
lkcl | bram wr addr 000a71e5 dout 10013ecc00000000 sel f0 ........ | 18:47 |
lkcl | ngggggh come ooooonnn : | 18:47 |
lkcl | :) | 18:47 |
lkcl | oo, oo! | 18:47 |
lkcl | Allocating 0x5fb320 bytes for kernel... | 18:47 |
lkcl | 0x5b0e10 bytes of uncompressed data copied | 18:47 |
programmerjake | printing r/w...maybe a big part of the simulator's slowness...printing can be pretty inefficient compared to just pure calculations | 18:48 |
lkcl | that's in c++ - by the simulator | 18:48 |
lkcl | holy cow! | 18:48 |
lkcl | Linux/PowerPC load: | 18:48 |
programmerjake | int -> str conversions and buffering and write syscalls all contribute to slowness | 18:49 |
lkcl | Finalizing device tree... flat tree at 0xbd4c80 | 18:49 |
lkcl | console messages! | 18:49 |
programmerjake | yay!! | 18:50 |
lkcl | it's doing approx one line of output per 30 seconds, but is actually running | 18:50 |
programmerjake | congrats! | 18:50 |
lkcl | -> early_setup(), dt_ptr: 0xbd4c80 | 18:50 |
lkcl | [ 0.000000] dt-cpu-ftrs: setup for ISA 3000 | 18:50 |
lkcl | [ 0.000000] dt-cpu-ftrs: final cpu/mmu features = 0x00000087800391e1 0x3c006041 | 18:50 |
*** kylel1 is now known as kylel | 18:50 | |
lkcl | frickin awesome | 18:50 |
*** Festive_Dragon is now known as A_Dragon | 18:51 | |
lkcl | this is microwatt, but it's still a big deal | 18:51 |
lkcl | urrrr with TestIssuer it's going to be about 5-10x slower even than this, urrrr | 18:51 |
lkcl | [ 0.000000] radix-mmu: Mapped 0x0000000000600000-0x0000000010000000 with 2.00 MiB pages | 18:55 |
lkcl | <- early_setup() | 18:55 |
lkcl | [ 0.000000] Linux version 5.7.0-00030-gabe0e1dab0a2-dirty (lkcl@fizzy) (gcc version 9.3.0 (Debian 9.3.0-13), GNU ld (GNU Binutils for Debian) 2.35.1) | 18:55 |
lkcl | wha-hey! | 18:55 |
programmerjake | try running test issuer with pypy, it'll likely simulate much faster than cpython | 18:59 |
lkcl | this is not under python at all, it's *actual* verilator c++ | 18:59 |
lkcl | microwatt is compiled from vhdl to verilog | 19:00 |
lkcl | verilog is handed to verilator, which gets compiled to a full c++ program | 19:00 |
lkcl | so there's no python involved here at all | 19:00 |
programmerjake | in my experience with the partitioned multiplier and the divider...pypy does nmigen construction/translation slower but simulates much faster. | 19:00 |
programmerjake | i was thinking you meant the simulator in openpower-isa.git | 19:01 |
lkcl | when we get to running libresoc instead, microwatt.v will be flipped out and libresoc.v put in its place | 19:01 |
lkcl | yehyeh, no this is entirely verilator | 19:01 |
lkcl | stand-alone | 19:01 |
lkcl | https://git.libre-soc.org/?p=microwatt.git;a=commitdiff;h=6431824a5f37a3a3d729d407b43f1443de93ff98 | 19:01 |
lkcl | CLK: 50 MHz | 19:03 |
lkcl | [ 0.000000] Found legacy serial port 0 for /soc@c0000000/serial@2000 | 19:04 |
lkcl | [ 0.000000] mem=c0002000, taddr=c0002000, irq=0, clk=100000000, speed=115200 | 19:04 |
lkcl | spot the deliberate mistake? | 19:04 |
lkcl | BITS error 434 44 | 19:04 |
lkcl | BITS error 434 43 | 19:04 |
lkcl | wark-wark :) | 19:04 |
Generated by irclog2html.py 2.17.1 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!