*** tpb <[email protected]> has joined #litex | 00:00 | |
*** Degi_ <[email protected]> has joined #litex | 00:29 | |
*** Degi <[email protected]> has quit IRC (Ping timeout: 240 seconds) | 00:30 | |
*** Degi_ is now known as Degi | 00:30 | |
*** TMM_ <[email protected]> has quit IRC (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.) | 05:51 | |
*** TMM_ <[email protected]> has joined #litex | 05:52 | |
*** tpb <[email protected]> has joined #litex | 06:00 | |
*** j4cbo <[email protected]> has joined #litex | 06:00 | |
*** shoragan <[email protected]> has joined #litex | 06:01 | |
*** mupuf <[email protected]> has joined #litex | 06:02 | |
*** indy <[email protected]> has quit IRC (Ping timeout: 240 seconds) | 07:27 | |
*** indy <[email protected]> has joined #litex | 07:31 | |
*** pharonix71 <pharonix71!~pharonix7@user/pharonix71> has quit IRC (Remote host closed the connection) | 08:41 | |
*** pharonix71 <pharonix71!~pharonix7@user/pharonix71> has joined #litex | 08:42 | |
*** Foxyloxy <Foxyloxy!~foxyloxy@cpc151593-shef16-2-0-cust343.17-1.cable.virginm.net> has joined #litex | 10:19 | |
*** Foxyloxy_ <Foxyloxy_!~foxyloxy@cpc151593-shef16-2-0-cust343.17-1.cable.virginm.net> has joined #litex | 14:11 | |
*** toshywoshy <toshywoshy!~toshywosh@ptr-377wf33o3bnthuddmycb.18120a2.ip6.access.telenet.be> has quit IRC (Ping timeout: 265 seconds) | 14:14 | |
*** Foxyloxy <Foxyloxy!~foxyloxy@cpc151593-shef16-2-0-cust343.17-1.cable.virginm.net> has quit IRC (Ping timeout: 265 seconds) | 14:14 | |
*** toshywoshy <toshywoshy!~toshywosh@ptr-377wf33o3bnthuddmycb.18120a2.ip6.access.telenet.be> has joined #litex | 14:15 | |
*** gurki_ <gurki_!~gurki@user/gurki> has joined #litex | 15:52 | |
*** gurki_ <gurki_!~gurki@user/gurki> has quit IRC (Client Quit) | 15:52 | |
*** gurki_ <gurki_!~gurki@user/gurki> has joined #litex | 15:52 | |
*** gurki_ <gurki_!~gurki@user/gurki> has quit IRC (Client Quit) | 15:52 | |
*** gurki_ <gurki_!~gurki@user/gurki> has joined #litex | 15:53 | |
*** gurki_ <gurki_!~gurki@user/gurki> has quit IRC (Client Quit) | 15:53 | |
*** gurki_ <gurki_!~gurki@user/gurki> has joined #litex | 15:53 | |
*** gurki_ <gurki_!~gurki@user/gurki> has quit IRC (Client Quit) | 15:53 | |
*** gurki_ <gurki_!~gurki@user/gurki> has joined #litex | 15:54 | |
*** cr1901 <cr1901!~cr1901@2601:8d:8600:911:119f:db:e45a:508c> has quit IRC (Remote host closed the connection) | 15:54 | |
*** cr1901 <cr1901!~cr1901@2601:8d:8600:911:9c7a:baf:1c5b:477e> has joined #litex | 15:55 | |
*** cr1901 <cr1901!~cr1901@2601:8d:8600:911:9c7a:baf:1c5b:477e> has quit IRC (Remote host closed the connection) | 15:55 | |
*** gurki_ <gurki_!~gurki@user/gurki> has quit IRC (Client Quit) | 15:55 | |
*** gurki_ <gurki_!~gurki@user/gurki> has joined #litex | 15:56 | |
*** gurki_ <gurki_!~gurki@user/gurki> has quit IRC (Client Quit) | 15:56 | |
*** gurki <gurki!~gurki@user/gurki> has joined #litex | 15:56 | |
*** cr1901 <cr1901!~cr1901@2601:8d:8600:911:9c7a:baf:1c5b:477e> has joined #litex | 15:56 | |
*** RaYmAn <[email protected]> has joined #litex | 17:09 | |
*** gurki <gurki!~gurki@user/gurki> has quit IRC (Ping timeout: 265 seconds) | 19:00 | |
cr1901 | jevinskie[m]: https://github.com/jevinskie/amd-lm32-smu-exploit >Well it turns out AMD integrated the LM32 so completely that it retained its debug functionality. Oops! | 19:38 |
---|---|---|
cr1901 | Was AMD using LiteX? | 19:38 |
jevinskie[m] | I highly doubt it, they probably just took the lm32 verilog from lattice and connected the data wishbone bus to an arbiter that lets it access the other buses on the AMD SoC | 19:43 |
jevinskie[m] | * I highly doubt it, they probably just took the lm32 verilog from lattice and connected the data wishbone bus to a decoder/arbiter that lets it access the other buses via MMIO on the AMD SoC | 19:44 |
cr1901 | I still like lm32... it's decent Verilog code and doesn't have a proliferation of extensions lol | 19:47 |
jevinskie[m] | they extended lm32 further to am32 for their SAMU (Secure Asset Management Unit) thats half used for DRM and half used for Secure Boot (but not any standard secure boot, ps4 specific). Xbox One has a SMU too but I don't own an Xbox One since their security is harder to break and thus not as much fun. I believe the Xbox One has a SAMU too but it goes unused since at least later models of the APUs they use have a PSP like you'd find in | 19:48 |
jevinskie[m] | Zen-class CPUs | 19:48 |
jevinskie[m] | cr1901: i saw some benchmarks showing lm32's simple design keeping up with some much more complicated cores. maybe this was it? https://antmicro.github.io/embench-tester/ | 19:51 |
tpb | Title: Embench Tester - Dashboard (at antmicro.github.io) | 19:51 |
cr1901 | am32 isn't returning many hits: https://twitter.com/Mathieulh/status/1058138007532945409 | 19:51 |
cr1901 | Main issue is that no LLVM port so no Rust (for now, until the gcc backend takes hold) | 19:51 |
jevinskie[m] | yeah its proprietary extensions added by AMD (including crypto accelerator w/ key slots concept). some poor souls weren't so clean with their OPSEC so we found the gcc/binutils toolchain in an obscure place online. Someone else managed to extract the cgen data from the binaries and make an IDA processor module for it :) https://sourceware.org/cgen/ | 19:57 |
tpb | Title: CGEN (at sourceware.org) | 19:57 |
cr1901 | The thing about LM32 is that it has only a single opcode out of 64 for a custom insn. So they must've done some more major modifications if they added the extensions you mentioned | 19:58 |
cr1901 | (My preferred use for a custom insn would've been to add a CAS, but you technically don't need atomics to run Linux if it's single core only w/ kernel helpers) | 20:00 |
jevinskie[m] | There was this stab at lm32 backend for LLVM but it stalled out 8 years ago =\ I'd love a LLVM with a lm32 backend and it is simple enough an architecture it can't be any more difficult than the other intro/tutorials for making a new LLVM backend. Hmm, only one I really know of was cpu0 and that was still quite a bit of work | 20:01 |
cr1901 | I started an LM32 backend using cpu0 as a basis. Yes, it's too much work to write an LLVM backend :'D. | 20:02 |
cr1901 | Maybe I should try again | 20:08 |
cr1901 | Look, if someone can write a 6502 backend for LLVM that doesn't entirely suck, it's probably a "skill issue" on my end | 20:09 |
jevinskie[m] | I consider myself to be pretty well versed in LLVM (at least up until 2018 era, don't ask me about MLIR!) and I've always wanted to make my own backend for Forth. Then you could obfuscate C/C++/ObjC(++) with different metainterpreter (themselves obfuscated and layered on each other). :P | 20:10 |
cr1901 | Main issue I ran into is that the lm32 calling convention doc is a bit underspecified, so I need to figure out where in the gcc source calling convention is defined | 20:10 |
cr1901 | metainterpreter? | 20:11 |
jevinskie[m] | But the conversion of SSA register for to stack form still has me at a roadblock. | 20:11 |
jevinskie[m] | forth metacompiler* basically a forth interpreter/compiler written in forth but not via typical emulation means but by building a new version of itself https://github.com/howerj/embed | 20:22 |
jevinskie[m] | that + a forth frontend for LLVM (there are a couple) + the LLVM obfuscation passes) might blow away a reverse engineer's mind, or not, I never had the time to do the work :( | 20:23 |
jevinskie[m] | <cr1901> "Look, if someone can write a 650..." <- Exactly. The guy who started or is one of the major devs of that project is married to an ex-girlfriend of mine. Maybe LLVM emits some pheromones? :P | 20:25 |
cr1901 | I hope you and ex-gf and him are on good terms :P | 20:26 |
cr1901 | I'll have to check your link when I'm in more of a mode to do so (stuck in FPGA land rn) | 20:27 |
jevinskie[m] | For am32 I think they added a bunch of CSRs to interface with the crypto engine as a coprocessor, not unlike ARM's MRC/MCR instructions to do terrible FPU in the early versions | 20:29 |
*** TMM_ <[email protected]> has quit IRC (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.) | 20:31 | |
*** TMM_ <[email protected]> has joined #litex | 20:31 | |
cr1901 | Now I'm nerdsniped into trying to grok this comment: https://stackoverflow.com/questions/51340463/converting-ssa-to-stack-machine#comment89719295_51372960 | 21:02 |
tpb | Title: compiler construction - Converting SSA to stack machine - Stack Overflow (at stackoverflow.com) | 21:02 |
cr1901 | (I assume they mean "do register coloring on SSA to figure out what temporaries you need before converting it into something suitable for a stack machine") | 21:02 |
*** Stary <Stary!znc@hacksoc/infrastructure> has quit IRC (Quit: ZNC - http://znc.in) | 21:06 | |
*** Stary <Stary!~Stary@hacksoc/infrastructure> has joined #litex | 21:47 | |
*** dark_star_1 <[email protected]> has quit IRC (Ping timeout: 240 seconds) | 22:01 | |
*** dark_star_1 <[email protected]> has joined #litex | 23:06 |
Generated by irclog2html.py 2.17.2 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!