Hello, In first place I'm not going to do an algorithmic benchmark, just a simple loop + print test and some checks on the generated binaries.
The system is a Debian12 Linux and the architecture is: x86 64bits.
Mojo don't allow .py extension it has to be .mojo so no default nvim highlighting ...
$ mojo build mojo_benchmark.mojo
$ time ./mojo_benchmark
...
real 0m0.342s
user 0m0.080s
sys 0m0.252s
$ rustc rust_benchmark.rs
$ time ./rust_benchmark
...
real 0m0.107s
user 0m0.012s
sys 0m0.049s
I noticed a speed increase using fish shell instead of bash but could be the environment variable stack overload.
So in this specific test rust is much faster. And also the compiler suggests using _ instead i, that mojo compiler doesn't.
The rust binary is bigger, but is because the allocator is embedded:
-rwxr-xr-x 1 sha0 sha0 1063352 Jan 10 08:55 mojo_benchmark
-rwxr-xr-x 1 sha0 sha0 4632872 Jan 10 08:57 rust_benchmark
But Look this, mojo uses libstdc++ and libc and rust only uses libc.
$ ldd -d mojo_benchmark
linux-vdso.so.1 (0x00007ffd94917000)
libtinfo.so.6 => /lib/x86_64-linux-gnu/libtinfo.so.6 (0x00007fe899cb1000)
libstdc++.so.6 => /lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007fe899a00000)
libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007fe899921000)
libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007fe899c91000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007fe899740000)
/lib64/ld-linux-x86-64.so.2 (0x00007fe899d2c000)
$ ldd -d rust_benchmark
linux-vdso.so.1 (0x00007ffde67b7000)
libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007f8b3881b000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f8b3863a000)
/lib64/ld-linux-x86-64.so.2 (0x00007f8b388ae000)
- Pentest Tools Github
- Android Hack Tools Github
- Hack Website Online Tool
- Hacker Tools Free Download
- Hacker Tools Windows
- Hacker Tools Online
- Hack Tools Pc
- Hacker Tools Mac
- Hack App
- Hack Tools 2019
- Tools Used For Hacking
- Pentest Tools Review
- Hacker Security Tools
- Hacking Tools For Windows 7
- Install Pentest Tools Ubuntu
- Wifi Hacker Tools For Windows
- Hacking Tools Hardware
- Hacking Tools For Pc
- Android Hack Tools Github
- Hacker Tools
- Pentest Tools Subdomain
- Hackers Toolbox
- Pentest Tools Website
- Hack Apps
- Pentest Tools
- Pentest Tools Subdomain
- Kik Hack Tools
- Pentest Tools Subdomain
- Pentest Tools Windows
- Hacker Tools 2019
- Hacker Tools Mac
- Pentest Tools Linux
- Hacking Tools Online
- Pentest Tools Android
- Hacker Tools Online
- Pentest Tools Android
- Pentest Tools List
- Hack Tools For Mac
- Best Hacking Tools 2020
- Game Hacking
- Hack Tools For Ubuntu
- Hack Website Online Tool
- Pentest Tools Website
- Pentest Tools Online
- Pentest Tools Url Fuzzer
- Best Hacking Tools 2020
- New Hack Tools
- Hacking Tools Windows 10
- Tools 4 Hack
- Hack Tools Download
- Usb Pentest Tools
- Pentest Tools Tcp Port Scanner
- New Hacker Tools
- Hacker Tool Kit
- Pentest Tools Nmap
- Pentest Tools Subdomain
- Hacker Tools Free Download
- Pentest Tools List
- Hacker Hardware Tools
- Hacker Tools Linux
- Hacker Tools Online
- Hacking Tools For Kali Linux
- Hacker Hardware Tools
- Hacks And Tools
- Pentest Tools Github
- World No 1 Hacker Software
- What Is Hacking Tools
- Blackhat Hacker Tools
- Hacking Tools Usb
- Hack Tools For Games
- Pentest Tools Website
- Hacking Tools Kit
- Pentest Tools Framework
- Hacking Apps
- Best Hacking Tools 2020
- Hacker Tools Windows
- Top Pentest Tools
- Tools Used For Hacking
- Pentest Tools Tcp Port Scanner
- Beginner Hacker Tools
- Hacking Tools For Windows 7
- Tools 4 Hack
- Wifi Hacker Tools For Windows
- Usb Pentest Tools
- Hack Tools Download
- Tools Used For Hacking
- Tools 4 Hack
- Pentest Tools Website
- Pentest Tools Apk
- Game Hacking
- New Hacker Tools
- Computer Hacker
- Tools 4 Hack
- Wifi Hacker Tools For Windows
- Hacking Tools Free Download
- Hacking Tools Name
- New Hacker Tools
- Hacker Tools Hardware
- Hacker Tools Apk Download
- Hacker Tools Online
- Pentest Tools Website Vulnerability
- Hack Tools Github
- Bluetooth Hacking Tools Kali
- Pentest Recon Tools
- Nsa Hack Tools Download
- Tools For Hacker
- Hack Tools For Ubuntu
- Hacking Tools Usb
- Hacking Tools Online
- Hacking Tools
- Hacking Tools Windows
- Pentest Tools Tcp Port Scanner
- Hacker Techniques Tools And Incident Handling
- Hacking Tools For Windows
- Pentest Box Tools Download
- Hacking Tools Windows
- Tools 4 Hack
- Hacker Tools For Mac
- Hacking Apps
- Pentest Tools Download
- Usb Pentest Tools
- Tools Used For Hacking
- Hacking Tools Windows
- Hacker Tools Software
- Hacking Tools For Windows 7
- Hack Tools Mac
- Hack And Tools
- Free Pentest Tools For Windows
- Pentest Tools
- Pentest Tools Nmap
- Hacker Tools Windows
0 comments:
Post a Comment