diff options
author | Chris Lattner <sabre@nondot.org> | 2009-09-23 06:06:36 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2009-09-23 06:06:36 +0000 |
commit | 21fb98ee003e992b0c4e204d98a19e0ef544cae3 (patch) | |
tree | fb74b2013454c3630bc397c5a8ba0c8f9b654b42 /include/clang/Basic | |
parent | 6a3bc6df36848188e9d0c1d978170c2b0918c6a3 (diff) |
implement support for __builtin_eh_return_data_regno on x86-32 and x86-64.
This implements PR5034 and rdar://6836445.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@82614 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Basic')
-rw-r--r-- | include/clang/Basic/Builtins.def | 1 | ||||
-rw-r--r-- | include/clang/Basic/TargetInfo.h | 9 |
2 files changed, 9 insertions, 1 deletions
diff --git a/include/clang/Basic/Builtins.def b/include/clang/Basic/Builtins.def index da0906b77b..502bbd24d9 100644 --- a/include/clang/Basic/Builtins.def +++ b/include/clang/Basic/Builtins.def @@ -247,6 +247,7 @@ BUILTIN(__builtin_flt_rounds, "i", "nc") BUILTIN(__builtin_setjmp, "iv**", "") BUILTIN(__builtin_longjmp, "vv**i", "") BUILTIN(__builtin_unwind_init, "v", "") +BUILTIN(__builtin_eh_return_data_regno, "ii", "nc") // GCC Object size checking builtins BUILTIN(__builtin_object_size, "zv*i", "n") diff --git a/include/clang/Basic/TargetInfo.h b/include/clang/Basic/TargetInfo.h index 1f61e3fccc..8ce85cf6bb 100644 --- a/include/clang/Basic/TargetInfo.h +++ b/include/clang/Basic/TargetInfo.h @@ -384,10 +384,17 @@ public: return RegParmMax; } - // isTLSSupported - Whether the target supports thread-local storage + /// isTLSSupported - Whether the target supports thread-local storage. bool isTLSSupported() const { return TLSSupported; } + + /// getEHDataRegisterNumber - Return the register number that + /// __builtin_eh_return_regno would return with the specified argument. + virtual int getEHDataRegisterNumber(unsigned RegNo) const { + return -1; + } + protected: virtual uint64_t getPointerWidthV(unsigned AddrSpace) const { |