performance of byte vs. int in .NET

后端 未结 5 646
伪装坚强ぢ
伪装坚强ぢ 2021-01-17 18:49

In pre-.NET world I always assumed that int is faster than byte since this is how processor works.

Now it\'s matter habit of using int even when bytes could work, fo

5条回答
  •  臣服心动
    2021-01-17 19:38

    Same as any other platform. Why would .NET change this? The code still has to run on the same CPU, which has the same performance characteristics as always.

    And that means you should still use int by default.

提交回复
热议问题