Links #1

Those articles/posts got me interested lately.
Most of them are about optimizing C++ code.

Data alignment in terms of performance

https://softwareengineering.stackexchange.com/questions/328775/how-important-is-memory-alignment-does-it-still-matter
https://lemire.me/blog/2012/05/31/data-alignment-for-speed-myth-or-reality/

http://www.catb.org/esr/structure-packing/
The clang compiler has a -Wpadded option that causes it to generate messages about alignment holes and padding. Some versions also have an undocumented -fdump-record-layouts option that yields more information.

Dynamic & Static inheritance in terms of performance:

http://www.imm.dtu.dk/~janba/svsd.pdf

http://www.thinkbottomup.com.au/site/blog/C%20%20_Mixins_-_Reuse_through_inheritance_is_good
Another problem with this approach is the use of virtual functions. We have virtual functions calling virtual functions when we are trying to something relatively simple! It should be noted that the compiler can not generally inline virtual functions and there is some overhead in calling a virtual function compared to calling a non-virtual function. This runtime hit seems unreasonable, but how can we overcome it?


https://en.wikipedia.org/wiki/Mixin
https://en.wikipedia.org/wiki/Virtual_method_table
https://en.wikipedia.org/wiki/Barton%E2%80%93Nackman_trick
https://en.wikipedia.org/wiki/Curiously_recurring_template_pattern
https://stackoverflow.com/questions/20783266/what-is-the-difference-between-dynamic-and-static-polymorphism-in-java

 

Object Oriented Programming pitfalls:

https://www.gamedev.net/blogs/entry/2265481-oop-is-dead-long-live-oop/
http://harmful.cat-v.org/software/OO_programming/_pdf/Pitfalls_of_Object_Oriented_Programming_GCAP_09.pdf
https://en.wikipedia.org/wiki/Entity%E2%80%93component%E2%80%93system

Programming patterns:

http://gameprogrammingpatterns.com/data-locality.html
http://gameprogrammingpatterns.com/bytecode.html
http://gameprogrammingpatterns.com/type-object.html
https://en.wikipedia.org/wiki/Mediator_pattern
https://en.wikipedia.org/wiki/Service_locator_pattern

C++ coding principles:

https://en.wikipedia.org/wiki/SOLID

Other

https://stackoverflow.com/questions/109710/how-does-the-likely-unlikely-macros-in-the-linux-kernel-works-and-what-is-their

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s