Method for compiling program running on multi-core processor, task mapping method of multi-core processor and task scheduling method of reconfigurable processor