28 lines
1.2 KiB
Plaintext
28 lines
1.2 KiB
Plaintext
$OpenBSD: patch-lib_Target_X86_X86MachineFunctionInfo_h,v 1.4 2020/08/05 06:49:48 jca Exp $
|
|
|
|
implement -msave-args in clang/llvm, like the sun did for gcc
|
|
|
|
Index: lib/Target/X86/X86MachineFunctionInfo.h
|
|
--- lib/Target/X86/X86MachineFunctionInfo.h.orig
|
|
+++ lib/Target/X86/X86MachineFunctionInfo.h
|
|
@@ -44,6 +44,9 @@ class X86MachineFunctionInfo : public MachineFunctionI
|
|
/// stack frame in bytes.
|
|
unsigned CalleeSavedFrameSize = 0;
|
|
|
|
+ // SaveArgSize - Number of register arguments saved on the stack
|
|
+ unsigned SaveArgSize = 0;
|
|
+
|
|
/// BytesToPopOnReturn - Number of bytes function pops on return (in addition
|
|
/// to the space used by the return address).
|
|
/// Used on windows platform for stdcall & fastcall name decoration
|
|
@@ -130,6 +133,9 @@ class X86MachineFunctionInfo : public MachineFunctionI
|
|
|
|
unsigned getCalleeSavedFrameSize() const { return CalleeSavedFrameSize; }
|
|
void setCalleeSavedFrameSize(unsigned bytes) { CalleeSavedFrameSize = bytes; }
|
|
+
|
|
+ unsigned getSaveArgSize() const { return SaveArgSize; }
|
|
+ void setSaveArgSize(unsigned bytes) { SaveArgSize = bytes; }
|
|
|
|
unsigned getBytesToPopOnReturn() const { return BytesToPopOnReturn; }
|
|
void setBytesToPopOnReturn (unsigned bytes) { BytesToPopOnReturn = bytes;}
|