intel: replace large stack buffer with heap allocation