Profile

Cover photo
Michael Aaron Murphy
Lives in Ashburn, Virginia
504 followers|685,696 views
AboutPostsCollections+1'sReviews

Stream

Michael Aaron Murphy

Shared publicly  - 
 
Visual Studio Code is noticeably inferior to Atom, but I've found a few extensions that make using it less of a pain and a bit more like Atom.

- Backspace-plusplus
- Paste and Indent
- TabOut
- TabSanity
- Indenticator

Why VSC continues to ship new versions without these features confuses me.
2
Jesper Lundgren's profile photoMichael Aaron Murphy's profile photo
6 comments
 
+Jesper Lundgren If you use the directional keys or backspace, they will not automatically jump between indent blocks. You have to navigate and delete one space at a time. Two of the extensions above are fixes for that behavior, but that shouldn't require an extension.
Add a comment...

Michael Aaron Murphy

Shared publicly  - 
 
After a few more tweaks and spinning it off into it's own crate, I announce the numtoa crate. I've added a base 10 lookup which sped up the conversion process to match that of itoa, all without a single unsafe function.

https://github.com/mmstick/numtoa

For now the version is marked as 0.0.3. If I'm happy with the state, I'll bump it up to 0.1.0 if no problems are observed.
numtoa - An efficient method of heaplessly converting numbers into their string representations, storing the representation within a reusable byte array.
1
Add a comment...

Michael Aaron Murphy

Shared publicly  - 
 
Since my last update, I have implemented support for the `--tmpdir` / `--tempdir` parameter and a new parameter not supported in the GNU variant: `--joblog-8601`, for displaying the start time with the ISO 8601 standard instead of seconds since the UNIX epoch.
1
Add a comment...

Michael Aaron Murphy

Shared publicly  - 
 
The joblog parameter is now complete. Here's a screenshot of the feature in action.
4
Add a comment...

Michael Aaron Murphy

Shared publicly  - 
 
According to OpenHub, my Parallel implementation is worth about $25,000 if someone were to be paid to write it again from scratch with a yearly salary of $55,000. Just an interesting statistic, because statistics are interesting.

https://www.openhub.net/p/rust-parallel/estimated_cost




(Maybe someday I can get paid to write code)
1
Michael Aaron Murphy's profile photocoder codercommand's profile photoIkey Doherty's profile photo
6 comments
 
+coder codercommand children rarely follow the advice of parents until they have made the same mistakes enough times.
Add a comment...

Michael Aaron Murphy

Shared publicly  - 
 
Here's an interesting project written in Rust that's useful on all platforms, even Windows. It's a new terminal in development that's utilizing OpenGL for rendering. As a result, it's faster than all existing terminals on Linux.

https://github.com/jwilm/alacritty

Take note though that you apparently need to copy the config file in the source root into your home directory in order to use your directional keys.
alacritty - A cross-platform, GPU enhanced terminal emulator
4
John McHugh's profile photoDavid Sullins's profile photo
2 comments
 
Is terminal emulator performance a real concern for people these days? 
Add a comment...

Communities

13 communities

Michael Aaron Murphy

Shared publicly  - 
 
The numtoa crate has been improved further. A few bugs were fixed (namely handling sized integers that are the lowest possible value), and there's now debug assertion checks to ensure that input arrays are the minimum size required by the type that is being converted.

In example, a u8 needs at least three bytes to represent it's largest value (255) and an i8 needs at least four bytes for it's largest value (-128). If you supply an array that is less than three bytes in length for a u8 or four bytes of length for an i8, debug builds of your software will crash with a panic and a message indicating what the minimum required size is.

Because this runtime check is hidden behind the if cfg!(debug_assertions) conditional, release builds will not compile the runtime checks (ensures zero overhead for release builds).

So far I only have these checks for base 10 conversions, so there's a lot more work required for doing the same for base 2, 8, and 16 at least.
1
Add a comment...

Michael Aaron Murphy

Shared publicly  - 
 
Spent the day doing some base 10 integer to byte array optimizations. Instead of converting one digit at a time, base 10 conversions will convert at most four digits at a time. Basically, I just did some loop unrolling with basic integer math tricks. Doubles the performance of the non-unrolled variant.

https://github.com/mmstick/parallel/blob/master/src/misc/numtoa.rs#L32:L67

Performance is slightly slower than the itoa crate, but it's faster than the heap-allocated to_string() method in the standard library. Although unlike the itoa crate, numtoa supports more than just base 10 conversions, and can be used in more places (itoa requires that it's input supports the io::Write trait, so you can't write directly to a stack-allocated array).

std: 1,431,256,318 ns
numtoa: 784,711,632 ns
itoa: 695,028,994 ns

Note: Interestingly, itoa and std largely share the same underlying implementations, but std is notably slower because it has to perform a heap allocation and UTF-8 encoding as it's sent through the Formatter. There's zero similarity between my implementation though as I did a simpler approach.

Double Note: Base 10 conversions will always fit within a `[u8; 20]` for numbers ranging from u8 to u64. u128 is an entirely different story though, and Rust is about to gain support for i128 and u128 soon.
2
Add a comment...

Michael Aaron Murphy

Shared publicly  - 
 
I've released MIT/Rust Parallel 0.10.0 for this week today. All the work I've done over the last week is in the new release. If you have cargo installed, you can just use the install subcommand to install it:

cargo install parallel --force

I'm also offering mentorship to anyone wanting to get started with programming and contributing to open source Rust projects. Most of the work involved in Parallel is stupid simple. I've been continually refactoring the codebase to make it easier to implement more and more features as I go along.

I have a lot of work planned for the next week to implement for Parallel. Tempdir, workdir, % for memfree, % for timeout, human-readable joblog stats, 8061 time spec for joblog, CSV support for joblog, and a ton of unit tests to implement -- which I've been neglecting to do in favor of pushing more and more features without tests.

https://github.com/mmstick/parallel/releases/tag/0.10.0


3
Add a comment...

Michael Aaron Murphy

Shared publicly  - 
 
There's apparently now a fork of emacs that is working to rewrite Emacs in Rust, which is being named `Remacs`.

http://www.wilfred.me.uk/blog/2017/01/11/announcing-remacs-porting-emacs-to-rust/

The goal is to leverage all of Rust's strengths and the Crates ecosystem, and for the continued global effort to rewrite a lot of things in Rust.
programming, language design, and human factors
4
Add a comment...

Michael Aaron Murphy

Shared publicly  - 
 
Currently working on support for the joblog parameter from GNU Parallel. Basically, it logs the activity of each job that is processed. I almost have it working 100% -- just finished aligning columns of the output.

The implementation has zero usage of heap allocations and floating point math. I'm printing values with decimals merely by using the modulus operator to get the remainder and dividing the remainder accordingly to collect up to the Nth decimal place. The integers are converted into a byte array that's the string representation of the number -- the same way you would do it manually in C, although I'm re-using the stack-allocated array for each integer to byte array conversion.
3
Add a comment...

Michael Aaron Murphy

Shared publicly  - 
 
Didn't know that it was possible, but yes, you can determine if an application has it's stdin, stdout, or stderr redirected, and you can find out from where that redirection is directed. At least it is possible to do so on systems that feature a proc filesystem like Linux.

Here's the Rust source code to do just that by detecting if the standard input was redirected, returning Some(path) if the input was redirected, else None.

pub fn input_was_redirected() -> Option<PathBuf> {
if let Ok(link) = fs::read_link("/proc/self/fd/0") {
if !link.to_string_lossy().starts_with("/dev/pts") {
return Some(link)
}
}
None
}

So, I've implemented the ability in Parallel to determine if the standard input was redirected, and if so, acts accordingly. In the event that you have an inputs list, named inputs.list, which has the following contents:

echo one
echo two
echo three
echo four

You may now use it in my parallel implementation like so:

parallel < inputs.list

Which is equivalent to:

parallel :::: inputs.list
parallel ::: < inputs.list

So it doesn't really add anything besides an extra method of doing the same thing. I did fix a bug with my application that wasn't correctly detecting inputs when inputs are commands though, so there's that.

https://github.com/mmstick/parallel/commit/e72344268ba46cc26610d1a548ef14863df38ef3
2
2
Linux Lady05 Winter's profile photo
 
Oh that's very handy, thank you +Michael Aaron Murphy​;)
Add a comment...
Michael Aaron's Collections
Communities
13 communities
Story
Tagline
What do you see when you reverse the chessboard?
Introduction
I speak concisely, or not at all.
Places
Map of the places this user has livedMap of the places this user has livedMap of the places this user has lived
Currently
Ashburn, Virginia
Previously
Saratoga, Arkansas - Nashville, Arkansas - Hope, Arkansas
Contact Information
Home
Email
Collections Michael Aaron is following
Work
Occupation
Information Technology
Skills
Critical Thinking, Logical Problem Solving, Computer Programming: {C, C++, D, Go, Java, Julia, Python, Rust}, Shell Scripting, System Administration, Linux, Windows, Mac OS X, Computer Hardware and Software Repair, Computer Networking, Technical Writing, Scribus Desktop Publishing, GIMP Image Manipulation, Krita Image Manipulation
Basic Information
Gender
Male
Relationship
In a relationship
Michael Aaron Murphy's +1's are the things they like, agree with, or want to recommend.
Glovebox - Side launcher – Android-Apps auf Google Play
market.android.com

Glovebox brings to android the best way of multi-tasking. Swipe without lifting the finger to select an application to open. You don't even

Text Mode
chrome.google.com

Browse the web without distractions via simple text based pages.

GIMP
plus.google.com

Free application for serious image manipulation

Scribus
plus.google.com

Free cross-platform desktop publishing (DTP) solution

Linux
plus.google.com

Linux - doing it right

Apple: They Didn't Build That - Ideas Apple Bought, Borrowed and Stole
www.bestmastersprograms.org

A look at the ideas Apple bought, borrowed and stole to create their most popular products.

I've been trying to find a proper Chinese restaurant ever since I moved from Southwest Arkansas and I have just been having a difficult time because all of the restaurants in the area are in poor quality across the board. You would think that the cities would be able to offer higher quality Chinese restaurants than small rural towns and villages, but that is not the case. How sad it is that when you purchase something as simple as sesame chicken, here and every other Chinese restaurant, that they deliver you a plate full of soggy mystery meat containing large amounts of unhealthy fat, and for obscene prices to boot. I'm used to going to a small, quiet restaurant in Nashville, Arkansas named the Chinese Buffet that would let you eat as much as you want for a low fee of, say $6 per person, that offers higher quality egg drop soup and chicken made with only the best parts of the chicken -- no fat, and no mystery meat, perfectly crispy all the way throughout and not soggy like Chau's Cafe. While it's common for Chinese restaurants throughout Southwest Arkansas and Texas to offer high quality food at low prices, apparently it's the exact opposite here.
• • •
Public - 9 months ago
reviewed 9 months ago
Coming from southwest Arkansas where Mexican restaurants are a dime a dozen, I'm going to have to place Uncle Julio's below the quality of the worst Mexican restaurant I have ever been to. Not only are the prices exhorbitant, such as charging $10 for a small bowl of queso whose actual market value is 50 cents, the menu is greatly lacking in quality Mexican food and the portions are miniature. I'm sorry, but you have nothing on small town restaurants like La Villa from Nashville, Arkansas. At least La Villa can offer a complete full course meal on a large plate for vegetarians at half the price of a bowl of a queso at this establishment, with fresher ingredients to boot.
• • •
Public - 9 months ago
reviewed 9 months ago
3 reviews
Map
Map
Map
This is one of the worst places you can possibly eat in Southwest Arkansas, especially if you are a vegetarian. Their menu is completely void of any vegetarian options besides a meager selection of vegetables offered as side dishes for exorbitant prices, some of which even contain meat. For $7, I ordered mashed potatoes, baked beans and french fries. What I received was nothing more than a handful of Walmart-quality french fries, a small portion of mashed potatoes and a tiny sauce dish of baked beans that literally contained half a cup of sugar mixed in with a few beans and BACON. Why on Earth a vegetable dish of baked beans contains bacon is beyond my comprehension. Even the sweet tea that I was served was nothing more than tea-flavoured syrup. Do people really stomach this amount sugar on a regular basis? As a result, I could not eat the baked beans, quickly finish the mashed potatoes in about four spoonfuls and ate the french fries within twenty seconds, despite waiting 20 minutes for such a small dish. My advice? Either cook a real meal at home for a seventh the cost or just heat up a bowl of noodles. You'll save money, it will taste better and you won't have to leave a restaurant still hungry. P.S. Their menu has bad typesetting which is really annoying to look at. You can tell that they used spaces rather than tabs so their menu items aren't aligned correctly.
• • •
Public - a year ago
reviewed a year ago