diff options
author | jonas <jonas@3ad0048d-3df7-0310-abae-a5850022a9f2> | 2015-12-26 20:00:33 +0000 |
---|---|---|
committer | jonas <jonas@3ad0048d-3df7-0310-abae-a5850022a9f2> | 2015-12-26 20:00:33 +0000 |
commit | 127bfdc5410e221bbeeac4cc3fef14f06b2ef2ae (patch) | |
tree | 87c00ebf1475a18980e4609ba6bbab0f6ab420e0 /compiler/psystem.pas | |
parent | 3dacf0892ae1aaa3e4316c7feb20ecdf55e4ba4f (diff) | |
download | fpc-127bfdc5410e221bbeeac4cc3fef14f06b2ef2ae.tar.gz |
+ non-functional 128 bit integer types (inaccessible from Pascal), for use
in the LLVM high level code generator to implement overflow checking
git-svn-id: http://svn.freepascal.org/svn/fpc/trunk@32735 3ad0048d-3df7-0310-abae-a5850022a9f2
Diffstat (limited to 'compiler/psystem.pas')
-rw-r--r-- | compiler/psystem.pas | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/compiler/psystem.pas b/compiler/psystem.pas index 897406d145..6d9314bb12 100644 --- a/compiler/psystem.pas +++ b/compiler/psystem.pas @@ -229,6 +229,12 @@ implementation s32inttype:=corddef.create(s32bit,int64(low(longint)),int64(high(longint)),true); u64inttype:=corddef.create(u64bit,low(qword),high(qword),true); s64inttype:=corddef.create(s64bit,low(int64),high(int64),true); + { upper/lower bound not yet properly set for 128 bit types, as we don't + support them yet at the Pascal level (nor for tconstexprint); they're + only used internally by the high level code generator for LLVM to + implement overflow checking } + u128inttype:=corddef.create(u128bit,0,0,true); + s128inttype:=corddef.create(s128bit,0,0,true); pasbool8type:=corddef.create(pasbool8,0,1,true); pasbool16type:=corddef.create(pasbool16,0,1,true); pasbool32type:=corddef.create(pasbool32,0,1,true); @@ -435,6 +441,8 @@ implementation addtype('$longint',s32inttype); addtype('$qword',u64inttype); addtype('$int64',s64inttype); + addtype('$uint128',u128inttype); + addtype('$int128',s128inttype); addtype('$char',cansichartype); addtype('$widechar',cwidechartype); addtype('$shortstring',cshortstringtype); @@ -559,6 +567,8 @@ implementation loadtype('longint',s32inttype); loadtype('qword',u64inttype); loadtype('int64',s64inttype); + loadtype('uint128',u128inttype); + loadtype('int128',s128inttype); loadtype('undefined',cundefinedtype); loadtype('formal',cformaltype); loadtype('typedformal',ctypedformaltype); |