Alignment - RE: - 1.6-rc5: Background multitasking

From: null <">
Date: Mon, 05 Nov 2007 13:22:34 +0000

----boundary-LibPST-iamunique-978772825_-_-
Content-type: text/plain

Hi Georgy,

since I did not see any example ...

just a question:

is that low level stuff, i.e. does your code use
system flags as documented in the Platform-Specific
issues?

Copying some of them reads:

System flags for record types
Name Value Description
untagged 1 No type tag and no type descriptor is allocated.
                The garbage collector ignores untagged variables.
                NEW is not allowed on pointers to untagged variables.
                No type-bound procedures are allowed for the record.
                Pointers to untagged record type or extensions of this
                record type inherit the attribute of being untagged.
                The offsets of the fields are aligned to
                MIN(4-byte, size), where size is the size of the field.
                The size of the record and the offsets of the fields are
                aligned to 32-bit boundaries.
noalign 3 Same as untagged but without alignment.
align2 4 Same as untagged but with
                MIN(2-byte, size) alignment.
align8 6 Same as untagged but with
                MIN(8-byte, size) alignment.
union 7 Untagged record with all fields allocated at offset 0.
                The size of the record is equal to the size of the
                largest field.
                Used to emulate C union types.

regards
--
	Bernhard Treutwein, IuK, Ref. III A 3
	Bernhard.Treutwein(at)verwaltung uni-muenchen de
> -----Original Message-----
> From: BlackBox [mailto:BLACKBOX{([at]})nowhere.xy> Georgy Jikia
> Sent: Saturday, November 03, 2007 4:36 PM
> To: BLACKBOX{([at]})nowhere.xy> Subject: Re: - 1.6-rc5: Background multitasking
> 
> 
> Sure, misalignment implies a severe execution time 
> performance penalty.
> 
> The question is, if there exist an (undocumented?) linker 
> option in Blackbox, similar to ALIGNMENT of XDS? If not, are 
> there any plans to improve the code generation for modern CPUs?
> 
> On 9/27/07, igor <igor_d{([at]})nowhere.xy> >
> > GJ> I have another observation, which looks strange to me. 
> If in the 
> > GJ> example given below I uncomment the following line (* one :=
> > GJ> 1.0; *), which just duplicates the previous command, 
> the execution 
> > GJ> time of the whole program drops by a factor of ~3. Is 
> this because 
> > GJ> the BB compiler is a non optimizing one? Or something is broken 
> > GJ> here? I'm using Windows XP on a Pentium M CPU.
> >
> > On some CPUs flooating point performance depends on data alignment.
> >
> >
> >
> 
> 
> ----
> To unsubscribe, send a message with body "SIGNOFF BLACKBOX" 
> to LISTSERV{([at]})nowhere.xy> 
----boundary-LibPST-iamunique-978772825_-_-
Content-type: application/rtf
Content-transfer-encoding: base64
Content-Disposition: attachment; filename="rtf-body.rtf"
e1xydGYxXGFuc2lcYW5zaWNwZzEyNTJcZnJvbXRleHQgXGRlZmYwe1xmb250dGJsDQp7XGYwXGZz
d2lzcyBBcmlhbDt9DQp7XGYxXGZtb2Rlcm4gQ291cmllciBOZXc7fQ0Ke1xmMlxmbmlsXGZjaGFy
c2V0MiBTeW1ib2w7fQ0Ke1xmM1xmbW9kZXJuXGZjaGFyc2V0MCBDb3VyaWVyIE5ldzt9fQ0Ke1xj
b2xvcnRibFxyZWQwXGdyZWVuMFxibHVlMDtccmVkMFxncmVlbjBcYmx1ZTI1NTt9DQpcdWMxXHBh
cmRccGxhaW5cZGVmdGFiMzYwIFxmMFxmczIwIEhpIEdlb3JneSxccGFyDQpccGFyDQpzaW5jZSBJ
IGRpZCBub3Qgc2VlIGFueSBleGFtcGxlIC4uLlxwYXINClxwYXINCmp1c3QgYSBxdWVzdGlvbjpc
cGFyDQpccGFyDQppcyB0aGF0IGxvdyBsZXZlbCBzdHVmZiwgaS5lLiBkb2VzIHlvdXIgY29kZSB1
c2VccGFyDQpzeXN0ZW0gZmxhZ3MgYXMgZG9jdW1lbnRlZCBpbiB0aGUgUGxhdGZvcm0tU3BlY2lm
aWNccGFyDQppc3N1ZXM/XHBhcg0KXHBhcg0KQ29weWluZyBzb21lIG9mIHRoZW0gcmVhZHM6XHBh
cg0KXHBhcg0KU3lzdGVtIGZsYWdzIGZvciByZWNvcmQgdHlwZXNccGFyDQpOYW1lXHRhYiBWYWx1
ZVx0YWIgRGVzY3JpcHRpb25ccGFyDQp1bnRhZ2dlZFx0YWIgMVx0YWIgTm8gdHlwZSB0YWcgYW5k
IG5vIHR5cGUgZGVzY3JpcHRvciBpcyBhbGxvY2F0ZWQuXHBhcg0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vYXRpbmcgcG9p
bnQgcGVyZm9ybWFuY2UgZGVwZW5kcyBvbiBkYXRhIGFsaWdubWVudC5ccGFyDQo+ID5ccGFyDQo+
ID5ccGFyDQo+ID5ccGFyDQo+IFxwYXINCj4gXHBhcg0KPiAtLS0tXHBhcg0KPiBUbyB1bnN1YnNj
cmliZSwgc2VuZCBhIG1lc3NhZ2Ugd2l0aCBib2R5ICJTSUdOT0ZGIEJMQUNLQk9YIiBccGFyDQo+
IHRvIExJU1RTRVJWQExJU1RTLk9CRVJPTi5DSFxwYXINCj4gXHBhcg0KfQ==
----boundary-LibPST-iamunique-978772825_-_---
Received on Mon Nov 05 2007 - 14:22:34 UTC

This archive was generated by hypermail 2.3.0 : Thu Sep 26 2013 - 06:31:13 UTC