Highly excited 8Be core in the configuration of the 12C and 11B ground states