wsy2220 / a-dda

Automatically exported from code.google.com/p/a-dda
0 stars 0 forks source link

Further work inline with C99 standard #113

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
The following is a list of ideas to think about:
- How to use 'restrict' keyword with regards to matrices? Is it possible to 
change/replace SwapPointers, so that it would not compromise 'restrict' for the 
affected pointers.
- All large dynamically-allocated arrays, which are actually Nx3 arrays or Nx6 
(e.g. symmetric matrices), may be defined as such (explicitly separating the 
fixed constant dimension. This may be considered as a generalization of the 
current doublecomplex (double[2]) definition. However, this may slightly 
degrade performance in some cases.
- Currently doublecomplex function parameters are passed as is by value, but 
really the pointer to double is passed. It complicates the consistent use of 
'restrict' keyword. Maybe, this calls should be changed to "fully" by 
reference, i.e. passing a pointer to doublecomplex. The latter will also 
facilitate changing complex type definition to a structure, if needed.
- Currently variables are mostly defined in the beginning of a function. 
Defining them only where actually needed may considerably clarify the code, 
especially with regards to using temporary variables.

Original issue reported on code.google.com by yurkin on 6 Sep 2010 at 2:18

GoogleCodeExporter commented 9 years ago
Defining variables inside function already takes place in some cases. Problem 
with doublecomplex will be solved in issue 70. The rest is of low priority.

Original comment by yurkin on 4 Feb 2013 at 5:49

GoogleCodeExporter commented 9 years ago
It seems that no global changes are further required (in the framework of C99 
standard). Some minor changes may happen on the go. So I am considering this 
fixed.

Original comment by yurkin on 14 Feb 2014 at 8:21