I am newbie of IL programming.
IL do support the "dcl_literal" syntax to define the constant values. And the constant buffer is also used to store constant values.
So what is the difference between them? What is the advantage of constant buffer (dcl_cb)?
dcl_cb declares constant kernel parameters. You need to bind these variables with memory declared on host side.
dcl_literal is declaring a constant literal value inside kernel.