optimize first kernel