Live data from Hacker News

Why doesn’t Windows use 64-bit virtual address space below 0x00000000`7ffe0000?

devblogs.microsoft.com

61–65 of 65 posts

Re: Why doesn’t Windows use 64-bit virtual address space below 0x00000000`7ffe0000?

#61
post #55
post #23

> No. The virtual address space starts at the 64KB boundary. You can confirm this by calling GetSystemInfo and checking the lpMinimum­Application­Address. It will be 0x00000000`00010000. Aw, man. I recently found out there is also a similar restriction on Linux. Bummer, because I have a good use for putting code into the lower 64KB of memory (not 4KB, still want to use that for catching NPEs). My use case is a fast i…

> Since every bytecode handler needs an entry in the dispatch table, and I have 7--yes 7!--dispatch tables, I'd like to make their entries 2 bytes. So instead of taking 1KB each, they would take only 512B each. But alas. Hmm. If the upper half of the handler addresses are the same, then why not store just the lower 2-bytes of each handler address in the dispatch table. If you're on x86, there's no add needed if the u…

Interesting idea. I think it means using another register to permanently hold the HANDLER_BASE though? The dispatch sequence is only 4 instructions. I tried it as a delta encoding, requiring another add instruction on every dispatch, but that is an approx. 5% penalty. So I was hoping that putting it at absolute address < 64KB I could do the sequence without another add.

Re: Why doesn’t Windows use 64-bit virtual address space below 0x00000000`7ffe0000?

#62

Has anyone here ever used Windows NT on a DEC Alpha? A company in Ireland I worked for gave a mobile phone GIS demo to the Irish national phone company and Digital lent us a beefy server with two AXP CPUs (it was gonna be the future!) running windows NT. We literally pulled it on cobbled dublin streets on a a handcart to bring it to their offices.

Yes – back in the 90s, my first tech job was doing QA for a COBOL vendor and we had that on our support matrix. The Alpha processors were really fast but did you ever know there was A VERY SERIOUS COMPUTER in that room with the industrial fans and a case like a filing cabinet which probably weighed 50 pounds empty. We even for a time had an Alpha on Linux build for a single customer.

Re: Why doesn’t Windows use 64-bit virtual address space below 0x00000000`7ffe0000?

#63
post #45
post #35

Earlier quoted context omitted.

A friend of mine had an Alpha, and I was getting the Windows betas (I got 98se, 2000, and XP, and then nothing else). My friend was really happy to 'borrow' the win2k for alpha discs. IIRC, release candidates 1 and 2 had alpha discs, and then 3 and beyond didn't; but I might be off by one. I assume it would have shipped as part of the release if only Alpha was cancelled a couple months later.

IIRC every RC disk had alpha binaries, only the RTM and later doesn't - because Alpha getting canned was declared in the short window between last RC and RTM, in a rather abrupt manner to everyone involved on the project.

https://www.theregister.com/2000/12/27/win2k_for_alpha_alive...

Seems to indicate that the Release Candidate 3 builds for Alpha never made it out through official channels. I'm pretty sure beta and RC was one disc per flavor and architecture though: so x86 professional, x86 server, etc, and alpha pro/server/etc. A big bundle of discs would come from Redmond.

I know nt4 had all the archs on the release disc, but I don't think that was the plan for win2k

Re: Why doesn’t Windows use 64-bit virtual address space below 0x00000000`7ffe0000?

#64

Earlier quoted context omitted.

This was only 'enforced' by the linker on x86. You could handcraft a Mach-O executable to get around it. But it is now enforced enforced by OSX on ARM. I don't see any good reason for this. My own half assed explanation is they're enforcing 32b cleanliness. It's not a very good explanation. But it's my explanation for something I don't like.

Can't one just remap the zero page?

No, you cannot. You can't remap it and you can't resize it. This is part of design assumptions baked into a couple of newish Apple technologies, ASLR and Address Signing.

Re: Why doesn’t Windows use 64-bit virtual address space below 0x00000000`7ffe0000?

#65
post #17
post #13

Earlier quoted context omitted.

So sad to see Alpha die off, especially since I haven't noticed any architectures with anything like PALCode spring up since. The Alpha's firmware was essentially a hypervisor that only supported a single guest, and the OS kernel had to upcall to the firmware for any privileged operations. In particular, it would be nice to have userspace programs be able to take advantage of new/larger registers without requiring th…

PAL code didn't do anything like context switches and I'm not sure how it could, given how the OS needs to know the specifics of the thread context in many scenarios.

That's correct. On NT/Alpha context switching was done in ntos\ke\alpha\ctxsw.s, which was regular kernel mode assembler code. A PAL call was made but it simply set the new Teb and Pdr; two or three lines of code. I've never seen the PALcode for VMS or OSF/Tru64 but the NT PAL for swpctx was designed so that alpha assembler code in NT looked as much like the mips code that davec wrote. It made the port easier that way.

Interesting Raymond continues to mention NT/Alpha now and then. If you run into him mention I have a collection of NT/Alpha artifacts and anecdotes he might be interested in.

Post reply on HN