Open unicomp21 opened 4 years ago
great!
A tiny please by me: It is so a big wish of some years to the santa: ;) running in jor1k: "gcc -g mytool.c -o mytoolexe ; gdb mytoolexe" but gdb wan't do it at the moment.
May be, it is not soooo much more to invest ... having a look to the at the moment in jor1k not solved problem with gdb? It is not running now. Something difficult with build says @s-macke sometimes ago ..., long long ago ... ;)
May be the prerequisites are now better after some time. ... only there as long as casually without trouble would result. ;)
Awesome project! Good luck!
I will try to compile the latest kernel. You are right, that gdb did not work years ago. But it is worth trying again.
Good luck! and much more than this: KEEP HEALTHY! :)
thanks @s-macke !
By the way, this is an amazing project. It could change the world on a number of fronts. I still can't believe how fast it runs in a web browser.
If I want to create communication between javascript in a web page and jor1k, w/ both running on the same/main web browser thread, what's the best way to do this?
To provide more background on what I plan to do, I'm wanting to compile and run boringtun within jor1k and then communicate from javascript/browser to jor1k using protobuf messages, probably something similar to an event/message bus.
https://github.com/cloudflare/boringtun https://github.com/protobufjs/protobuf.js
ie create a virtual nic (vpn connection) within jor1k by tunneling wireguard/udp packets over javascript/browser/websocket.
How hard would it be to make Ubuntu 18.10 run in jor1k? If it isn't easy, please disregard this query.
Is there any way I can help? Would love to learn how to do this myself.
The kernel is now on version 5.8 with enabled wireguard. In order to cross compile some code you might want to use a pre build toolchain. https://github.com/openrisc/or1k-gcc/releases/tag/or1k-7.2.0-20180317 I haven't tested these, because I use my own toolchain which you can find here. https://jor1k.com/or1k-toolchain.tar.bz2
Ubuntu will not work on this machine. To port Ubuntu on OpenRisc would probably mean a full time job for one year.
jor1k network connection runs on the lowest level you can imagine. On Ethernet Frames. The frames are sent to a websocket host which then use a Linux TAP device. The ethernet frames are handled in the following script: https://github.com/s-macke/jor1k/blob/master/js/master/dev/ethernet.js Dependent on what you want to do exactly this can be very difficult. E. g. build you own TCP/IP Stack implementation.
Thanks @s-macke ! Much appreciated.
In case I need it, is there an example somewhere for creating a pre-build? Or maybe a howto page?
No worries w/ the ethernet frames, I've worked w/ them in the past, building kernel-bypass systems.
Feel like a kid again! git clone's are slow, is there a way to run websocket ethernet proxy locally? Or do I need to make my own? @s-macke
@unicomp21 Yes, you can run the websocket proxy locally in docker, see the websocket proxy project page for a docker command that will set it up locally. You can then change the URL used by the jor1k webpage to point to the correct address (&relayURL=wss://localhost:8080/
or thereabouts.) Note that there is a form of rate limiting applied, but this rate limiting can be disabled with a bit of tweaking in limiter.py
. It won't go a heck of a lot faster, but you should be able to break 10kbyte/s.
@andrakis thinking I could speed up this interface dramatically (possibly MB/s if lucky) using RTCDataChannel(s), w/ the guaranteed delivery disabled, instead of websockets, just need to find some time.
So far no luck with gdb. It has still not been ported to run natively.
What do you mean with pre build? The root filesystem or the emulator itself? For the emulator just look at compile.sh. You just need browserify. You can ignore all the webassembly stuff.
@s-macke Sorry, should have been more clear, I meant the root filesystem (ie building a new kernel)
On the emulator side, would it make sense to "jit" emulated instructions into webassembly? If so, how hard would it be?
So far no luck with gdb. It has still not been ported to run natively.
What do you mean with pre build? The root filesystem or the emulator itself? For the emulator just look at compile.sh. You just need browserify. You can ignore all the webassembly stuff.
Ho I was hoping to have gdb support, should we contact the openrisc community and/or the gdb community for help ?
I'd like to rebuild jor1k w/ the latest linux kernel. My intention is to experiment w/ the wireguard protocol just added to the linux kernel, and run it over jor1k websockets.