文件名称:Copimtion
介绍说明--下载内容均来自于网络,请自行研究使用
C代码优化方案
目录 __ 2
C代码优化方案__ 4
1、选择合适的算法和数据结构__ 4
2、使用尽量小的数据类型__ 5
3、减少运算的强度__ 5
(1)、查表(游戏程序员必修课)_ 5
(2)、求余运算__ 6
(3)、平方运算__ 6
(4)、用移位实现乘除法运算__ 6
(5)、避免不必要的整数除法__ 8
(6)、使用增量和减量操作符__ 8
(7)、使用复合赋值表达式__ 8
(8)、提取公共的子表达式__ 9 -C code optimization program directory catalog __ 2 C code optimization program __ 41, select the appropriate algorithms and data structures __ 42, the use of data types as small as possible __ 53, __ to reduce the intensity of operations 5 (1 ), look-up table (game programmer required course) _ 5 (2), to request the operator __ 6 (3), square computing __ 6 (4), with a shift to achieve operational __ Multiplication and Division 6 (5) avoid unnecessary integer division __ 8 (6), increment and decrement operators to use __ 8 (7), using compound assignment expressions __ 8 (8), common subexpression extraction __ 9
目录 __ 2
C代码优化方案__ 4
1、选择合适的算法和数据结构__ 4
2、使用尽量小的数据类型__ 5
3、减少运算的强度__ 5
(1)、查表(游戏程序员必修课)_ 5
(2)、求余运算__ 6
(3)、平方运算__ 6
(4)、用移位实现乘除法运算__ 6
(5)、避免不必要的整数除法__ 8
(6)、使用增量和减量操作符__ 8
(7)、使用复合赋值表达式__ 8
(8)、提取公共的子表达式__ 9 -C code optimization program directory catalog __ 2 C code optimization program __ 41, select the appropriate algorithms and data structures __ 42, the use of data types as small as possible __ 53, __ to reduce the intensity of operations 5 (1 ), look-up table (game programmer required course) _ 5 (2), to request the operator __ 6 (3), square computing __ 6 (4), with a shift to achieve operational __ Multiplication and Division 6 (5) avoid unnecessary integer division __ 8 (6), increment and decrement operators to use __ 8 (7), using compound assignment expressions __ 8 (8), common subexpression extraction __ 9
(系统自动生成,下载前可以参看下载内容)
下载文件列表
C代码优化.txt