Better HN
topnewbestaskshowjobs
Log inSign up

sumtechguy

2,602 karma · joined Jul 31, 2020 (6y ago) · 1,754 submissions

Submissions

comment 1y ago · link · parent

You may enjoy this page then. https://graphics.stanford.edu/~seander/bithacks.html

Bunches of bit twiddling things people like to do in different places for either speed/space.

comment 1y ago · link · parent

When I worked at qcom it took 2 devs 3 managers and 2 directors to get another group to let us fix a single race condition in their code. Once I got a copy of the code I started handing off tons of memory overwrites and underruns back for them to fix and another 10 or so race conditions. Their initial stance was 'there is nothing wrong with the code it is your code that is broken'. That was internal in the same vertical. It would be awful to work as an external group with that lib. Other stacks I got to look into were in similar shape. Some groups if you got their code you knew it was going to be solid and you would learn a thing or two. Others groups you were kind of surprised it compiled.

comment 1y ago · link · parent

I just ended up there because I ended up with yet another 'standard' that wraps the wildly different 'APIs' that devices present to the OS.

I set it up so the application layer could just say 'I want to change/get some datapoint'. But the underside of that the 'datapoint' object had to know quite a bit about what to feed into the system to bind up things correctly to do that data transfer. Last time I looked home assistant had something similar to what I was coming up with. I just could not get it to not have a leaky abstraction. The problem was one system might have a set of 16 bit address spaces. While the next one would be 8 bit, the next one would be 78 bit. Then properly decoding those things was also leaky. As many of these systems will do things like bit masking/shifting to pull data out partiular fields. Plus some systems are just simple memory read/writes and others are bind out an RS232 port and fill out this packet just right (dont forget the correct baud rates), oh and there are 6 other things packed into the return packet. The real painful ones were the vendors who got tricky with a DRM handshake before each call and a simple decode system.

comment 1y ago · link · parent

with xslt it probably could be.

comment 1y ago · link · parent

That data transform thing xslt could do was so cool. You could twist it into emitting just about any other format and XML was the top layer. You want it in tab delimited yaml. Feed it the right style sheet and there you go. Other system wants CSV. Sure thing different style sheet and there you go.

For a transport tech XML was OK. Just wasted 20% of your bandwidth on being a text encoding. Plus wrapping your head around those style sheets was a mind twister. Not surprised people despise it. As it has the ability to be wickedly complex for no real reason.

comment 1y ago · link · parent

On a previous project I spent a lot of time trying to figure out a 'generic device driver'. That is actually a decently hard space to crack. As each device has randomly different ways of talking. Some are serial/local bus. Some are memory space. Some have a combination. Some systems broadcast data, some you have to query it, some you have to query then wait for the next broadcast. Some systems mildly follow the spec, some strictly follow it, some strictly follow their own flavor of the spec or an outdated one, some have their totally made up spec that they may or may not give you. Even from the same company you can have two models that on the outside if you use their stuff looks the same but under the hood is sorta different enough that your driver is garbage. I basically ended up here https://xkcd.com/927/

comment 1y ago · link · parent

Add some meat sauce and more spaghetti :)

comment 1y ago · link · parent

The same thing sort of happened in the compression realm. ZIP is the pretty much the defacto winner for that type of file movement. Oh people use others in a lot of cases. But even when pkzip 2.04 came out there were better ones. Yet here we are still 30 years on using zip. Heck the zip alg is even used in many picture formats.

comment 1y ago · link · parent

I would like to see where that 4.5 Trillion per year comes from. Just for the US alone.

comment 1y ago · link · parent

Exactly. However, that would mean the boss thought the same, as he was hired specifically for that team. By the time it had happened the boss had not even noticed. Despite the team basically telling him every day in 50 different nice ways. In this case I did not realize it was controlling and manipulative behavior. But I learned and can spot it off pretty quickly now and will make sure it does not happen again.

comment 1y ago · link · parent

I have had my share of fun things I added to code/environment. Yet then we add 'the new guy'. They spend a long time arguing why that humor should not be there. One project it was a single line comment about new beginnings on the main procedure. That created a 2 hour rant about how unprofessional it was and months of unwarranted verbal abuse. It was literally the only piece of humor in the entire codebase. Super petty. Turned a fun functioning team into a slog of even wanting to go into work and all the rest of team reassigning themselves to other work. I use it as a litmus test these days of what I want to work with. Kind of tempted to add it to interview questions but have not found a proper way to do it.

comment 1y ago · link · parent

yes probably. but it already is. there is also an assumption that meta would turn it off. not saying they will or will not just that there an assumption here.

comment 1y ago · link · parent

For cover art you can control it from options->options->cover art. There are also a couple of plugins for other sources.

There are a few items in there to control if it scans external or overwrite. Recently went thru this as apparently for some reason I had totally disabled it. Think I was trying to speed up scanning as it would download every artwork for a large group into the temp folder. I usually force it to make an external file. I pick what it suggested 'cover'. Then use something like fileoptimizer to recompress the jpg/png it comes up with. I do that because I like to embed the images. And much of what is out on the net is optimized for fast editing not 'archive'. I use mp3tag to put it back into the tag.

Scan is hit or miss. I have fed it whole albums and it will somehow find 3 other albums with some of the songs from that one. That could be because of how I have options->options->metadata->Prefered Releases set. That slider bar thing for some reason I can not wrap my head around. It is good for when you come across one of those items where someone else tagged it as 'weird al' (everything is weird al if it is funny). I have been slowly getting rid of that stuff but want to find the original album to buy. Musicbrainz can be good for that sort of thing. I have also had decent luck with it if I pre-add the albums then scan. It seems to find things better.

comment 1y ago · link · parent

The integration with sourcesafe and all of the tools was pretty cool back then. Nothing else really had that level of integration at the time. However, VSS was seriously flakey. It would corrupt randomly for no real reason. Daily backups were always being restored in my workplace. Then they picked PVCS. At least it didnt corrupt itself.

I think VSS was fine if you used it on a local machine. If you put it on a network drive things would just flake out. It also got progressively worse as newer versions came out. Nice GUI, very straight forward to teach someone how to use it (checkout file, change, check in like a book), random corruptions about sums up VSS. That checkin/out model seems simpler for people to grasp. The virtual/branch systems most of the other ones use is kind of a mental block for many until they grok it.

comment 1y ago · link · parent

Yeah. The base problem is redump doesnt have parent clone. Some of MAME has it, retool has the currently basically static version. The name inference is ok for some of them because they are just basically the same name but diff regions. Others are in the native language or just totally different names but same game. Then there is TOSEC. That is a monster I have been trying to figure out what to do with and has similar problems as redump. No-intro and MAME are pretty good with its relationship metadata. The other two not so much. Some websites have it for particular systems but kinda not a cool move to scrape them. One of the cool parts I liked out of retool was its compilation part where there could be three games and it is in another 'game' thigs like '5 in 1'. Which is where p/c falls apart.

comment 1y ago · link · parent

Have to dig and see if it handles retool items. Unfortunately retool has been basically abandoned. IGIR looked interesting until I realized it could not do parent/clone for redump like retool.

comment 1y ago · link · parent

Edward Bernays created a method to get people to buy/hate/like things. It is used all the time. Its manipulative and shockingly effective. You will never see it coming. It is used all the time on everyone for any plethora of subjects. Subliminal advertising while mildly effective can not hold a candle to the Edward Barnays method of selling.

comment 1y ago · link · parent

The 'win32' way, layers.

https://learn.microsoft.com/en-us/windows/win32/winmsg/windo...

comment 1y ago · link · parent

Do I give it out? Not so much.

Do I expect it to be private? No.

You can for a small fee on some websites get my number.

Heck if you find a phone book from ~2000 where I use to live then you could just look it up in the phone book. Number portability saw to that.

Considering the number of data breaches and past history of phone numbers. To expect any sort of privacy is 'nice to have' but not going to happen. At this point it is basically security thru obscurity to expect it to be private.

Even when they had 'unlisted' numbers you could buy a book from the phone company that had it in there anyway. They even had reverse phone books you could buy. I even remember CD's from ~1998 that had the whole country. You didn't even need to keep the books.

comment 1y ago · link · parent

> I think we are in the middle of this transformation.

Totally. Had a bit to think on my second point. Lets say I used to do something like 'who was the king of england in 1732'. That would in the past may lead me thru at least 3 websites. All serving ads. Now google can have that above the fold. They will have some ad's on the side like they always did. But I have the thing I want. I am probably not going to drill onto those other sites. Seeing those ad's too. Ads more than likely being served by google. In effect it will be showing me something like 80% less ad's. I am pretty cool with that. But the ecosphere around it is going to collapse or at least be substantially curtailed. This will also subtract on what they can charge for ad's. As they will be serving less of them.

comment 1y ago · link · parent

Basically if you serve information or content. AI or even just some smart coding google can do that too. If you do something with that information Google has not been doing so good at that.

Microsoft in the early 2000s did that very well. They would let you have the data but would gobble up any company that could transform data and make it their own.

But data without applications is useless. Applications without data is also useless.

The applications let us make decisions with our data. Now can AI replace that? Probably in many cases. If it ican then google can just spit out the answer you want.

However, by doing that google may be eating its own lunch. As that ad empire depends on thousands of websites serving up their ad's. If those sites do not exist then what are the ads worth? It was this serving of information/content that drew everyone in. With that scrape of getting ad revenue. Google now can scrape your content and show it above the fold. What reason do you have to make a content farm? But then where does google get the data? They are killing the chicken and the egg at the same time.

comment 1y ago · link · parent

It is also one of the key tools people use for swatting.

Just the style of my writing gives me away. Even if that method just gets you down to 5 people it is way easier to go thru 5 peoples information than thousands.

Even something as simple as which browser you use and what the thing emits can identify you. https://coveryourtracks.eff.org/

comment 1y ago · link · parent

As someone looking for a piano. It seems to be the same there. Prices from 'get this thing away from me' to 'care to take out a small 50k loan?'.

comment 1y ago · link · parent

LP is a shockingly good way to optimize a system. If you can put inputs/outputs into the correct form. Had an econ prof that loved these things for doing supply/demand maxima and minimum finding. He didnt outright say it but I think it was his current line of study when I was taking classes from him the 90s. I thought that, as he managed to bring it up in every class he taught.

comment 1y ago · link · parent

> Did the distributor really have sufficient ownership of the movie to release a minor altered version into the public domain?

Probably yes. The way movies are financed is quite the byzantine joy ride if you want to look into it. With random tax incentives depending on where you make it. To finance groups that get control of entire regions. There are quite a large number of videos from independent filmmakers on what is going on. You hear things like 'Disney lost XYZ on a movie'. More than likely they lost someone else's money making sure they recoup first. Like for example the OG star wars has yet to recoup. Probably for some segments of the corporate structure that was created to make that movie that is probably true. Hollywood accounting is a huge mess. So yeah he probably signed off particular distribution rights to get the money to make/distribute the thing.

Many TV show pilots probably fall into the same issue too. I have not dug into it too much but the original pilot of star trek did not have one until a re-release decades later with an obvious digital watermark.

comment 1y ago · link · parent

Ah you have used spring/spring boot I see. That thing. It has humbled me. I didnt know you could do that much abstraction.

comment 1y ago · link · parent

It has been interesting how that company managed to stay around.

comment 1y ago · link · parent

Sometimes accidents happen for things https://en.wikipedia.org/wiki/2008_Universal_Studios_fire

comment 1y ago · link · parent

That is an interesting idea. But I suspect it really would still create a moderate first mover advantage in small communities. Early first mover advantage I suspect is decent in any up/down point based system ranking. Would have to run simulations on it. I also suspect what is being described is similar to the way YT works. For example I know they random feed me things. If I click on it and watch the whole vid. Suddenly I get a lot more suggestions from that channel or cohorts to it. But I cant prove that as they are terribly inscrutable on describing what it does (for good reason!).

comment 1y ago · link · parent

I could but my wife has an intense hatred anything with vinegar in it. It makes her gag.
1
567
59