From 9896f483178486bb1f052b7e345a1369daa08b73 Mon Sep 17 00:00:00 2001 From: pierre Date: Thu, 7 Jan 2010 17:05:11 +0000 Subject: [PATCH] * Fix for RTTI alignment from Paul git-svn-id: trunk@14564 - --- compiler/ncgrtti.pas | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/compiler/ncgrtti.pas b/compiler/ncgrtti.pas index 28ffbe9feb..a332621da5 100644 --- a/compiler/ncgrtti.pas +++ b/compiler/ncgrtti.pas @@ -733,6 +733,9 @@ implementation { write name of result type } write_rtti_name(def.returndef); + if (tf_requires_proper_alignment in target_info.flags) then + current_asmdata.asmlists[al_rtti].concat(Cai_align.Create(sizeof(TConstPtrUint))); + { write result typeinfo } current_asmdata.asmlists[al_rtti].concat(Tai_const.Create_sym(ref_rtti(def.returndef,fullrtti))) end; @@ -740,6 +743,9 @@ implementation { write calling convention } current_asmdata.asmlists[al_rtti].concat(Tai_const.Create_8bit(ProcCallOptionToCallConv[def.proccalloption])); + if (tf_requires_proper_alignment in target_info.flags) then + current_asmdata.asmlists[al_rtti].concat(Cai_align.Create(sizeof(TConstPtrUint))); + { write params typeinfo } for i:=0 to def.paras.count-1 do if not(vo_is_hidden_para in tparavarsym(def.paras[i]).varoptions) then