Add LGNCG_CHECK_OFF_R_DENSE flag.

When LGNCG_CHECK_OFF_R_DENSE is defined, then offset density check will be
performed at run time. Otherwise, offsets are assumed to be dense.