IRC log for #elinux on 20140623

00:20.07*** join/#elinux Russ (~russ@172.56.9.55)
00:20.07*** mode/#elinux [+o Russ] by ChanServ
01:46.27*** join/#elinux warthog9 (~warthog9@149.20.54.19)
02:36.26*** join/#elinux m4t (matt@2604:180::34ea:9d4b)
05:22.00*** join/#elinux Russ (foobar@pool-108-0-19-96.lsanca.fios.verizon.net)
05:22.04*** mode/#elinux [+o Russ] by ChanServ
09:31.48*** join/#elinux diego_r (~diego@host65-246-static.10-188-b.business.telecomitalia.it)
09:52.48*** join/#elinux jkridner (~jkridner@c-98-250-189-79.hsd1.mi.comcast.net)
09:52.48*** join/#elinux jkridner (~jkridner@pdpc/supporter/active/jkridner)
12:00.17*** join/#elinux jkridner (~jkridner@pdpc/supporter/active/jkridner)
12:10.54*** join/#elinux arun (~arun@unaffiliated/sindian)
13:44.41*** join/#elinux rcw (~rwoolley@128.224.252.2)
13:59.04*** join/#elinux gustavoz (~gustavoz@host228.190-226-84.telecom.net.ar)
14:33.41*** join/#elinux manjo (~manjo@2602:301:772c:4d30:896e:1c94:c6f9:16b)
14:33.50*** join/#elinux manjo (~manjo@ubuntu/member/manjo)
17:57.05*** join/#elinux ac_slater (~weechat@128.89.69.173)
17:58.23ac_slaterhey guys, I just started doing some ARM linux development. Most of my work will be in C++. How concerned should I be regarding alignment? Being used to x86, I've not put a lot of effort into cache-level optimizations. Is there a book on this subject? Preferably with examples .. not just integer access.
17:58.26ac_slaterthanks!
18:01.30spe{trumjust pay attention to 4 bytes alignment access, that's all
18:07.19ac_slaterspe{trum: I guess I'm mainly concerned with class/instance access. Should instances be aligned against something?
18:08.52ac_slaterie - to what extent should DATA be aligned - heap data and stack data
18:32.40spe{trumjust care of this
18:33.15spe{trumunsigned long mylong = *(unsigned long*)ptr;
18:33.40spe{trumif ptr is not multiple of 4 this fill fail
18:33.44spe{trum*will
18:33.53ac_slater'fail' == cause unaligned access?
18:34.05spe{trumyou read a wrong value yes
18:34.19ac_slaterright. That's pretty obvious, but a good illustration
18:34.34spe{trumin this case, you have to provide some macros to read byte by byte
18:35.13spe{trumexcept of this, i don't have other issues using c++ with arm
18:35.26ac_slaterright. Sadly I get all mixed up since a lot of byte level (and pointer) access is masked behind c++ classes.
18:36.20ac_slaterawesome. I use valgrind/cachegrind for debugging/profiling. Do you recommend anything else? I'd like to see proof where I mess up caching.
18:37.55spe{trumwhats exactly your issue ? compiler manage by himself alignments for members, you have this issues when you read packed structs for example from the network
18:38.50spe{trumwhen possible i  have projects with 2 makefiles, build for i386 (for valgrind tests) and for arm
18:38.55spe{trumare you working from linux ?
18:42.23spe{trumi actually have gdb on the target, valgrind tests on pc side. Also on PC side i do cppunit1 tests
18:42.56ac_slaterspe{trum: yea linux. And I don't have issues really. I just put almost no effort into alignment. Now I'm writing my own allocators and stumbled across std::align and various boost aligned allocators ... they make me think that EVERYTHING should be aligned
18:43.11ac_slaterwe have a similar workflow... I do the same, x86 and arm, valgrind on both, gdb on both
20:09.56ac_slaterspe{trum: I used to do the same, tests/profile in x86 then run on arm... until I started seeing weird ARM specific things happening and no test runs to reflect it. So I started profiling and testing (cppunit) on arm as well.
20:51.42*** join/#elinux akp (~akp@50.133.254.143)
21:04.16*** join/#elinux baozich (~baozich@ec2-54-186-21-246.us-west-2.compute.amazonaws.com)

Generated by irclog2html.pl Modified by Tim Riker to work with infobot.