mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-15 19:19:24 +02:00
* Removed "packed" attribute from TUC_Prop on alignment-sensitive targets (temporary solution, see comment in source), and from TUCA_DataBook on all targets (does not add noticeable bloat because this type is used just a few times. OTOH having unaligned pointers in record hurts performance on all targets).
This change fixes fpwidestring-related tests at least on mips-linux. git-svn-id: trunk@29322 -
This commit is contained in:
parent
38d5be4182
commit
38068acd42
@ -207,7 +207,12 @@ type
|
||||
|
||||
{ TUC_Prop }
|
||||
|
||||
TUC_Prop = packed record
|
||||
{ On alignment-sensitive targets, at least some of them, assembler uses to forcibly align data >1 byte.
|
||||
This breaks intended layout of initialized constants/variables.
|
||||
A proper solution is to patch compiler to emit always unaligned directives for words/dwords/etc,
|
||||
but for now just declare this record as "unpacked". This causes bloat, but it's better than having
|
||||
entire unit not working at all. }
|
||||
TUC_Prop = {$ifndef FPC_REQUIRES_PROPER_ALIGNMENT}packed{$endif} record
|
||||
private
|
||||
function GetCategory : Byte;inline;
|
||||
procedure SetCategory(AValue : Byte);
|
||||
@ -322,7 +327,7 @@ type
|
||||
TCollationName = string[128];
|
||||
|
||||
PUCA_DataBook = ^TUCA_DataBook;
|
||||
TUCA_DataBook = packed record
|
||||
TUCA_DataBook = record
|
||||
public
|
||||
Base : PUCA_DataBook;
|
||||
Version : TCollationName;
|
||||
|
Loading…
Reference in New Issue
Block a user