Re: [PATCH] VAX libstdc++ common runtime - register used but not saved
Jan-Benedict Glaw <[email protected]>
| Newsgroups | gmane.os.netbsd.devel.toolchain |
|---|---|
| Message-ID | <[email protected]> |
On Fri, 2023-07-28 09:51:07 +0200, Edgar Fuß <[email protected]> wrote: > > This 0x0101 seems like two NOPs copy-paste from pre-ELF code: > Is it absolutely clear to VAX insiders what these constants mean or why > aren't there any #defines (or whatever that is in asm) for it? Yes, I think so. It's the "Procedure Entry Mask", 16 bits showing which registers should be automatically pushed onto the stack before starting the actual function code. So it's an ORed value where each bit represents one register. VAX has 16 registers. r0 and r1 are commonly used to return values and are thus not saved for obvious reasone. r12 to r15 have fixed purposes (r12 = argument pointer, r13 = frame pointer, r14 = stack pointer and r15 = program counter.) Bits 14 and 15 are used not actually for registers but to mark for integer/decimal overflow, and bits 12 and 13 may not be set. MfG, JBG --
signature.asc
(application/pgp-signature, 195 B)
-----BEGIN PGP SIGNATURE----- iF0EABECAB0WIQQlDTvPcScNjKREqWEdvV51g5nhuwUCZMN1YAAKCRAdvV51g5nh u2mfAJsH9hzWpe+GLG59KZF8ofNoErNlQACaAlyMUywT2WhdYN894rbRx2JcTtI= =JTOB -----END PGP SIGNATURE-----