Skip to content

Commit

Permalink
Extend cbmc ts18661 test
Browse files Browse the repository at this point in the history
This now expects to find _Float128 when gcc-4.3+ (x86-64) for -4.5+ (other targets) is in use.
  • Loading branch information
smowton committed Jun 7, 2018
1 parent 7227bac commit 2fe4c9e
Showing 1 changed file with 15 additions and 3 deletions.
18 changes: 15 additions & 3 deletions regression/cbmc/ts18661_typedefs/main.c
Original file line number Diff line number Diff line change
@@ -1,18 +1,30 @@
#if defined(__clang__)
#elif defined(__GNUC__)
#if defined(__GNUC__) && !defined(__clang__)

#ifdef __x86_64__
#define FLOAT128_MINOR_VERSION 3
#else
#define FLOAT128_MINOR_VERSION 5
#endif

#if __GNUC__ >= 7
#define HAS_FLOATN
#elif __GNUC_PREREQ(4, FLOAT128_MINOR_VERSION)
#define HAs_FLOAT128
#endif

#endif

#ifndef HAS_FLOATN
typedef float _Float32;
typedef double _Float32x;
typedef double _Float64;
typedef long double _Float64x;
typedef long double _Float128;
typedef long double _Float128x;
#endif

#if !defined(HAS_FLOATN) && !defined(HAS_FLOAT128)
typedef long double _Float128;
#endif

int main(int argc, char** argv) {
}

0 comments on commit 2fe4c9e

Please sign in to comment.