The MEGA-1284P Xplained kit comes with both the Atmel ATmega1284P and the Atmel AT32UC3B1256 pre-programmed.
The pre-programmed firmware in the Atmel ATmega1284P is set up with an example code that allows the user to change between different sleep modes and shows an example on how to use the light sensor to dim the four onboard LEDs. It also includes a bootloader (AVROSP) which allows the user to reprogram the ATmega1284P without using an external programmer. Refer to the application note, AVR370 - MEGA-1284P Xplained Getting Started Guide, for more details regarding the pre-programmed firmware.
The pre-programmed Atmel AT32UC3B1256 firmware offers features such as a bootloader for self-programming of the boardcontroller itself and an USART-to-USB gateway which can be used to communicate with the target controller, ATmega1284P.