Welcome to MSDN Blogs Sign in | Join | Help

Browse by Tags

All Tags » C++ Design   (RSS)

Tracking C++ variable state changes

Tracking class variables' state changes can be tricky, especially if we are using too many asynchronous constructs. This is especially true for game and graphic application scenarios where hundreds and perhaps even thousands of object fly around changing

How to create and manipulate Terabyte size Arrays with Win32API

If you are looking for a way of creating and accessing very large arrays, arrays that can handle content in the order of Tera Bytes, then probably you might find the File Mapping techniques useful for that purpose. File mapping is the association of a

Multiplication Circuit for Prime Factorization

Deriving a multiplication circuit for the Prime Factorization problem is trivial if you know how to convert the arithmetic and relational expressions into propositional logic. Below I will show few expressions and their corresponding CNF formulation.

How to check if my code is executing inside a Managed App or Native App?

If you check the CRT source code (inside VC\crt\src\crt0.c ) you can find an interesting function check_managed_app() that returns 1 if managed app, 0 if not based on the COM Runtime Descriptor in the Image Data Directory of the PE or PE+ header. You

Well-designed libraries

It is very rare that we come across a well-designed library every day, and even rare that we get a chance to work on them on daily basis. While it is hard to define what makes any given library "well-designed", it is rather easy to identify what is not.

Remove Data-dependencies

Are you planning to remove data-dependencies in your logic? You might find the below useful. Statement Block Constant Time Equivalent x++; if(x >= MAX_SIZE) x = 0; x = ( x + 1 ) % MAX_SIZE; x--; if(x < 0) x = MAX_SIZE - 1; x = (x + MAX_SIZE – 1)

Having hard time marshalling parameters from C++ to .Net?

If you are finding it difficult to send parameters from C++ to .Net, try if you can use the following class: -------------------------------------------------------------------------------------------------------------------------------- #ifndef __PARAMETERS_H_A1B7ECCA_1691_43d0_ACDD_EBE1208005F9
Posted by P.Gopalakrishna | 1 Comments
Attachment(s): Parameters.h
 
Page view tracker