News for hackers. Stuff that matters.

crc32

Re:Show HN: Civ 1 period accurate decompilation on Tuesday October 20, 2026 @08:59AM (#50165689)
Exactly yes.

Interestingly; the way that MSC51 and LINK 5 lay out the binary depends on identifier names. There's also length restrictions due to memory limitations. So although the names aren't going to be historically accurate; the possibilities are at least bounded!

Re:Show HN: Civ 1 period accurate decompilation on Tuesday October 20, 2026 @05:41AM (#50163534)
The approach really boils down to just giving the LLM the clear target of 100% binary compatibility with the same toolchain. It makes it easy for it to check its work and iterate towards it.

It's probably a couple of months of intermittently using £15pm subscriptions between OpenAI, Anthropic and Google; nowhere near maxing them out.

MSC 5.1 is a relatively simple compiler; and there's lots of prior art on Civ 1. I've set them off on a slightly more obscure and recent game now; so we'll see how well they manage on that!

Regarding legality - IANAL so perhaps we'll see. I just wanted to see how the sausage was made.

Show HN: Civ 1 period accurate decompilation

https://github.com/sjmelia/civd

I've used LLMs to decompile Civ 1 and put the reconstructed C source on GitHub, along with a technical book and story.The reconstructed source builds with what i'm pretty sure is the original Microsoft C compiler and toolchain. It produces a byte-for-byte match with the original executable, aside from a four-byte correction for what appears to be a patch applied after linking. So it should be...

( Read More... | 6 comments | 7 points | on HN )
Re:Old Laptops as Secondary Monitors on Saturday October 24, 2020 @06:05AM (#24878145)
Can you link the tablet?
Re:Professor suspended for saying 那个 nà ge on Monday September 07, 2020 @06:07PM (#24403350)
If it was a German professor talking about buttermilk do you think he would given a build up?
Re:Professor suspended for saying 那个 nà ge on Monday September 07, 2020 @06:07PM (#24403347)
Of course they would, dropped into a communication course with no prior warning.

If it was a German professor talking about buttermilk do you think he would given a build up?

Re:Professor suspended for saying 那个 nà ge on Monday September 07, 2020 @06:01PM (#24403310)
I disagree with the assertion, prior to your edit, that the complaint was necessarily unwarranted.

But regardless, the reactions in the comments here are verging on hysterical - references to McCarthy, and even Stalin and Mao.

Re:Professor suspended for saying 那个 nà ge on Monday September 07, 2020 @05:48PM (#24403227)
> I don't need to be warned about a sound because a similar sound with a different meaning is used in negative ways.

Perhaps you don’t - that’s fine. But can you see why other people might need such a warning?

If you were teaching a foreign language word with a similar sound to “motherfucker” what reaction would you expect from your class of 18-21 year olds?

Re:Professor suspended for saying 那个 nà ge on Monday September 07, 2020 @05:43PM (#24403191)
No - I can’t remember when i learnt that; possibly because I’m English and due to geographical proximity.

I was surprised by the linked video though, it could have done with a prior warning in my opinion.

Re:Professor suspended for saying 那个 nà ge on Monday September 07, 2020 @04:35PM (#24402605)
I can’t believe the reactionary comments to this.

Of course, we have no idea of the context. But if it was anything like the linked video - and it could have been worse - it’s perfectly understandable why students would be surprised and perhaps upset.

If you disagree, its worth asking yourself, what reaction would you expect if you were a chinese professor enunciating the word “cunt” during a lecture, with no prior warning?

Re:Professor suspended for saying 那个 nà ge on Monday September 07, 2020 @02:13PM (#24401298)
> Not only does this barely resemble the racial slur, it is indistinguishably used in a context where it's implicitly clear and even explicitly stated that it's a term from another language.

In the linked video it sounds exactly like the slur, To a surprising extent.

It was introduced with no warning and I’m not surprised people were shocked if this was the same context as the class - although we don’t know the full details!

I’d be surprised just to hear a word sounding like “fuck” in the middle of a chinese class, although it’s probably not considered as offensive.

It doesnt surprise me at all that some people were upset and it seems very unwise on the part of the professor, who would surely know that this would provoke a reaction. A suspension from teaching his one class for a term will defuse the situation and perhaps he can return to teaching after.

Re:Using 'this' incorrectly in C# on Friday August 14, 2020 @11:15AM (#24158976)
I don't think this is true - sounds like resharper, an extension for Visual Studio. I don't think this is the default out of the box.
Re:Using 'this' incorrectly in C# on Friday August 14, 2020 @11:14AM (#24158959)
StyleCop on the other hand - a freely available linter as opposed to the commercial resharper - mandates the use of `this` by default.
Re:Lego Helicopter Kit Cancelled 10 Days Before Release on Wednesday July 22, 2020 @06:37PM (#23922327)
> fell under pressure

What kind of pressure did they fall under?

Its either a moral pressure (option 1) or a financial pressure (2) isnt it? What other kind of pressure is there?

Regarding your examples, i have no doubt that if Lego felt releasing such kits either violated their ethical standards (1) or threatened their profitability (2) they wouldnt make the kits, and that is where they (not I) presumably draw the line.

Re:Lego Helicopter Kit Cancelled 10 Days Before Release on Wednesday July 22, 2020 @03:14PM (#23920517)
> That is not healthy for anyone that wants a free open society. Consumers will vote with their wallet. Those outraged aren't the target market.

I understand you may be disappointed if you would have enjoyed this kit, but I cannot understand your logic here at all. Either:

1) Lego are adhering to a broader set of principles - acting as in a free or open society

Or

2) Lego are purely seeking to maximise profits - in which case they have determined that releasing the product will, in a broader sense, reduce profitability.

One of these two outlooks is driving the decision right?Which one do you object to?

What's the project?
OP didn't say "work for free", they said "work for peanuts".

I agree that freelancer sites have some problematic aspects, but I don't think there is anything wrong with the idea that you need to start small and build a reputation/profile. This applies to any bootstrapped business, not just when working via freelancer sites.

> Nobody needs kale or skateboards either... Why not tax them to "what the market will bear"?

Because alcohol and tobacco have "negative externalities" to society. These would be mainly health related but I guess the discussion on this post is also around behavioural issues.

By adding a tax to a product, you can make the consumers and manufacturers together share the burden of paying off the externality, (e.g. care for lung cancer patients) and/or the tax will often discourage consumption in the first place. (The second being more applicable in the US where there is limited/no universal healthcare)

The reason you probably wouldn't tax kale, is because it's good for you, and if anything; you could say it has a "positive externality" in that consuming it makes you healthier, and thus benefits society. So it might make sense to actual SUBSIDISE kale production... although this may have very different effects from taxing unhealthy food.

As an example, Scotland has introduced a tax on alcohol called "minimum unit pricing" and there's a study here: https://bmjopen.bmj.com/content/7/5/e013497

The UK as a whole also has a "sugar tax" https://www.lshtm.ac.uk/research/research-action/features/uk...

Re:The dark side of electronic waste recycling on Tuesday December 17, 2019 @05:33AM (#21812330)
This is called a "Pigouvian tax" or "externality tax" and a common example is a tax on fuel:

"In the United States, the federal gas tax was $0.183 per gallon in 2019... The revenue goes into the federal Highway Trust Fund to pay for roadway maintenance."

https://www.thebalance.com/pigouvian-tax-definition-and-exam...

Re:Nebraska farmers vote overwhelmingly for Right to Repair on Tuesday December 17, 2019 @05:18AM (#21812255)
> Now you've shipped your thing that lasts forever. If it's a mechanical object, maybe you can get continuing revenue from spare parts, but those will bring in less than the original purchase.

This might be bad for a tractor manufacturer; but an everlasting tractor would be great for society, right?

The incentive now is to innovate in order to create a better more efficient product. E.g.; a more fuel efficient tractor which increases productivity - then you'll get another sale.

Deliberately hobbling your product so that it needs repair or replacement disincentives innovation and is a form of rent-seeking https://www.investopedia.com/terms/r/rentseeking.asp and as such should be treated as a market failure. (I.e., legislated against)

Re:Nebraska farmers vote overwhelmingly for Right to Repair on Tuesday December 17, 2019 @05:11AM (#21812221)
Great comment - the concept you speak of can be described as an "information asymmetry" or more broadly as "bounded rationality" as opposed to econ 101 theories which often assume "perfect information" or perfect rationality.

https://en.wikipedia.org/wiki/Information_asymmetry https://en.wikipedia.org/wiki/Bounded_rationality

I think really only a rabid free-marketer (as opposed to all economists as you imply in the first sentence) would expect the market to self correct on something like this.

Re:Deep Dive Into C# 9 on Friday December 06, 2019 @06:30AM (#21720862)
Every language has a lifecycle.

I understood from a Microsoft conference I attended (regrettably I forget the speaker) that their decision to incorporate new features so rapidly was a very conscious decision, based on what I thought to be a quite perceptive look at the landscape - to some extent C# has always been a reaction to Java; a language that often comes under fire for its extremely slow and cautious incorporation of features.

Here's a link that summarises the tests.

https://www.hrdefenseblog.com/2018/05/say-goodbye-to-indepen...

This is very similar to the IR35 tests that operate in the UK, although that legislation is primarily used for determining what tax should be applied.

Re:EU says new cars must include built-in speed limiters on Wednesday March 27, 2019 @04:39AM (#19498991)
There is already a speed limit, this is just enforcement isn't it?

Do you agree with speed limits?

Re:Programmer Migration Patterns on Tuesday March 19, 2019 @09:56AM (#19430802)
I can see how OP would come up with this - Angular w/Typescript is probably the "Microsoft Way" choice for front-end JS and has good support in VS.

Once you've been exposed to a bit of that it would be natural to get curious about other parts of the JS ecosystem i.e. node.

Re:Productivity tricks in Visual Studio on Thursday February 28, 2019 @02:13AM (#19269590)
I'd been using Visual Studio for quite a while before I discovered it supported something like Vim's visual block mode - you can use alt-shift to select (and then edit) blocks of text.
Re:Event Sourcing is Hard on Monday February 04, 2019 @04:26AM (#19074986)
> You're publishing an event which is a thin slice or crafted combination of details that ultimately reside in that store

The event stream is the canonical store.

In your original comment you said "If we redistributed the world's wealth equally to all people on the planet the distribution would revert back to what the shape it has now in a matter of years or decades" - so it sounded to me as though you were against this, on the basis that it would not solve the problem.

> Nope but because they're subjected to an environment that only operates in terms of poverty.

So let's say you have now identified a root cause, and assuming we're looking for a solution - how do we fix this without a redistribution of wealth?

I think there are a couple of problems with the "rising tide floats all boats" argument.

> My only metric is is it getting better on average for me and other people

This might be true for you, but may not be for all. Research suggests that on the whole people value relative wealth more than absolute wealth [1] making inequality an important predictor for social stability, a prerequisite for a capitalist system based on property rights.

> I hope capatilism lasts another couple of hundred years and everyone gets to level 3 or 4

As other comments have pointed out, it looks as though an economic system predicated on permanent growth - or even a particular rate of growth - might have some limits. It seems like it's not sustainable with our current level of technology.

[1] http://science.sciencemag.org/content/318/5854/1305.full?ijk...

Research suggests that we value relative wealth more than absolute wealth. [1]

This means that inequality is important for social stability - does social stability matter?

There are possibly other reasons as well - you could argue rich people invest differently, which has implications for the global allocation of resources. [2]

[1] http://science.sciencemag.org/content/318/5854/1305.full?ijk...

[2] https://www.theglobeandmail.com/investing/globe-wealth/artic...

Older »