On 11/8/20 12:20 PM, Jethro Beekman wrote: >> The vDSO function calling convention uses the standard RDI RSI, RDX, RCX, >> R8 and R9 registers. This makes it possible to declare the vDSO as a C >> prototype, but other than that there is no specific support for SystemV >> ABI. Things like storing XSAVE are the responsibility of the enclave and >> the runtime. > I suppose this may be covered under "no specific support for SystemV > ABI" but with sgx_enclave_run.user_handler=NULL, R12~R15 *will* get > clobbered when __vdso_sgx_enter_enclave returns from an SGX AEX. IMO > this makes the whole "try to be like System V ABI" rather useless, > but I suppose it doesn't matter too much. What? It *says*: "there is no specific support for SystemV ABI." That's the point. It's a tiny *PART* of the ABI, used to "make it possible to declare the vDSO as a C prototype". That's far from useless.